Hi there!
Spurred by the tellings of Chris Kilgour on his modifications to gPXE and libpayload, paired with my own inability to find the full answer as to the interface between Coreboot and gPXE, I now plead to those of you with thorough insight:
To what extent does gPXE presently interface "well" with Coreboot? Is the position identical for coreboot-v2 and coreboot-v3?
To be specific for my present intents, my interest is not primarily geared towards the ability to use gPXE and ELF-images, but is more basic:
1. Is there an available and ready interface in Coreboot that allows the detection of an PXE-ROM image inside an PCI ethernet card adapter? Can execution be transferred to a copy of that code segment?
2. Is it known whether a "slimmed down" gPXE can be built and incorporated into a Coreboot image under the lesser demand that the purpose of the gPXE code is only that of getting and running the executable "pxelinux.0", fetched from another server, thus making the system autonomous? There could possibly exist some code segment in PXElinux that depends on either 16-bit mode, or lagacy Bios calls, but I do not a priori know that with any certainty!
The previous discussions and informations that I have found, they were all centered on the ELF format and its concequences for Coreboot in conjunction with gPXE/Etherboot. I would gladly receive pointers and references that prove me wrong or my misconceptions to be grave!
Kind regards
Mats E Andersson
Mats Erik Andersson wrote:
To what extent does gPXE presently interface "well" with Coreboot?
Very little. Without the work as outlined by Chris gPXE does not function as a payload at all. Etherboot works just fine however.
Is the position identical for coreboot-v2 and coreboot-v3?
Yes.
- Is there an available and ready interface in Coreboot that allows the detection of an PXE-ROM image inside an PCI ethernet card adapter?
If by PXE-ROM you mean option ROM then yes, coreboot scans for option ROMs.
Can execution be transferred to a copy of that code segment?
No, if option ROMs are executed they are executed in emulated real mode. Either in VM8086 mode, or using x86emu.
- Is it known whether a "slimmed down" gPXE can be built and incorporated into a Coreboot image under the lesser demand that the purpose of the gPXE code is only that of getting and running the executable "pxelinux.0", fetched from another server, thus making the system autonomous?
This is not possible.
There could possibly exist some code segment in PXElinux that depends on either 16-bit mode, or lagacy Bios calls, but I do not a priori know that with any certainty!
Yes, PXE requires real mode and BIOS interrupt services.
But all network booting is not PXE. PXE is just a standard with a limited subset of what Etherboot and gPXE can do. They can both simply use DHCP+TFTP to boot a system, and that will work just fine with coreboot.
//Peter
There could possibly exist some code segment in PXElinux that depends on either 16-bit mode, or lagacy Bios calls, but I do not a priori know that with any certainty!
Yes, PXE requires real mode and BIOS interrupt services.
For what it's worth, I first was looking at gPXE on coreboot in order to run PXE, because I had been happily using PXE previously on COTS hardware.
But after realizing that PXE requires a standard real-mode BIOS, I gave up on PXE under coreboot, and moved to simply booting a mkelfimage binary transferred over HTTP. That could be done with etherboot, and I think that generally people are happy with rom-o-matic ELFs as a coreboot payload for that purpose. However, since the gPXE project has newer things that etherboot will never have (like support for more, newer ethernet controllers), I felt it was worthwhile to get gPXE building and booting, at least in a pared-down form, under coreboot.
Chris.