On Thu, 21 Jan, 2016 at 4:08 PM, Aaron Durbin via coreboot coreboot@coreboot.org wrote:
You can always kexec() into your new kernel. The one sitting in flash can be smart enough to interrogate your boot media and determine what to load. Then just kexec().
This is very interesting. So basically I should build a minimal kernel with kexec support to launch the "normal" kernel living in /boot. But what exactly needs to be compiled in the payload kernel? I guess some hardware has to be initialised at this stage... Can I compile it 64bit? Is there any further documentation on this?
I found something on the wiki https://www.coreboot.org/Board:tyan/s2891#LAB_payload
Thanks
On Thu, Jan 21, 2016 at 11:49 AM, Kitestramuort kitestramuort@autistici.org wrote:
On Thu, 21 Jan, 2016 at 4:08 PM, Aaron Durbin via coreboot coreboot@coreboot.org wrote:
You can always kexec() into your new kernel. The one sitting in flash can be smart enough to interrogate your boot media and determine what to load. Then just kexec().
This is very interesting. So basically I should build a minimal kernel with kexec support to launch the "normal" kernel living in /boot. But what exactly needs to be compiled in the payload kernel? I guess some hardware has to be initialised at this stage... Can I compile it 64bit? Is there any further documentation on this?
You'd need an initramfs along w/ your storage drivers for finding the boot device. You'd want to make your userspace smart enough such that you could potentially recover if you ever landed a bad kernel. In short, you'd need to duplicate what lilo or grub do depending how you want to convey all that boot information (and allow a chance at recovery).
I found something on the wiki https://www.coreboot.org/Board:tyan/s2891#LAB_payload
Thanks
-- coreboot mailing list: coreboot@coreboot.org http://www.coreboot.org/mailman/listinfo/coreboot
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1
On 01/21/2016 11:49 AM, Kitestramuort wrote:
On Thu, 21 Jan, 2016 at 4:08 PM, Aaron Durbin via coreboot coreboot@coreboot.org wrote:
You can always kexec() into your new kernel. The one sitting in flash can be smart enough to interrogate your boot media and determine what to load. Then just kexec().
This is very interesting. So basically I should build a minimal kernel with kexec support to launch the "normal" kernel living in /boot. But what exactly needs to be compiled in the payload kernel? I guess some hardware has to be initialised at this stage... Can I compile it 64bit? Is there any further documentation on this?
I found something on the wiki https://www.coreboot.org/Board:tyan/s2891#LAB_payload
Thanks
If you're going to go the route of a bootstrap kernel, what about baking petitboot into the ROM?
https://www.kernel.org/pub/linux/kernel/people/geoff/petitboot/petitboot.htm...
If your system is 64-bit capable, you can use a 64-bit kernel, no problem.
- -- Timothy Pearson Raptor Engineering +1 (415) 727-8645 (direct line) +1 (512) 690-0200 (switchboard) http://www.raptorengineeringinc.com
2016-01-21 18:49 GMT+01:00 Kitestramuort kitestramuort@autistici.org:
Can I compile it 64bit?
As long as you keep the 32bit entry point around, yes (which I think is the default configuration for x86_64 kernels). In kconfig/menuconfig/..., select a linux payload, and point to the bzImage file. That should work (and this part of coreboot is pretty well testable with our QEmu targets, in case you want to try it out first).
Is there any further documentation on this?
Sadly documentation is not a strength in this project.
I found something on the wiki https://www.coreboot.org/Board:tyan/s2891#LAB_payload
The kexec information there is probably still useful, the buildrom stuff is horribly outdated.
Patrick