boot/simple in ROM?
The boot loader thingie in arch/ppc/boot/simple is nifty. So why isn't there a provision for putting it on ROM? (Or is there and I missed it?) Because boot/simple decompresses to RAM at 0x0, it seems obvious that it might be decompressing from ROM.
What is the right way to do this? (Or, pointers on how to make it ROMable would be appreciated.)
Thanks,
-kb, the Kent who got as far as Linux booting most of the way but not finding initrd because he has it messed up.
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
Quoted 2 lines · Kent Borg
The boot loader thingie in
arch/ppc/boot/simpleis nifty. So why isn't there a provision for putting it on ROM?
Well, you normally place it in ROM along with the kernel that is attached.
The purpose of all of these "bootloaders" is to convert a rom calling sequence into a standard (yes, there is one) Linux start up call. They also perform any hardware specific "fixups" that may be necessary prior to calling Linux. Another feature is it isolates boot rom changes from Linux changes.
The old PPCBoot, and probably the new U-boot, kind of perform some of these functions. The reason I'm not a fan of doing this is if we make a change to the Linux calling sequence (which happens rarely) you also have to update the boot rom to match. Not a good thing, IMHO.
The other really nice thing about these bootloaders, compressed kernels, and attached initrd, is you can boot the identical image from all "devices." For example, during development you can tftp load the image, get everything working, then place the exact same bits into a flash rom. Simply jump to the first location of the image and it will boot from flash.
It's relatively easy to adapt these loaders to any custom product requirements.
-- Dan
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
Quoted 6 lines · Dan Malek
The other really nice thing about these bootloaders, compressed kernels, and attached initrd, is you can boot the identical image from all "devices." For example, during development you can tftp load the image, get everything working, then place the exact same bits into a flash rom. Simply jump to the first location of the image and it will boot from flash.
Yes, but disappointingly the ppc/boot/simple I am using (from 2.4 devel) won't run from ROM. Is there a better boot loader I should be using?
Thanks,
-kb
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
Quoted 12 lines · Kent Borg
Quoted 8 lines · Dan Malek
The other really nice thing about these bootloaders, compressed kernels, and attached initrd, is you can boot the identical image from all "devices." For example, during development you can tftp load the image, get everything working, then place the exact same bits into a flash rom. Simply jump to the first location of the image and it will boot from flash.
Quoted 5 lines
Yes, but disappointingly the ppc/boot/simple I am using (from 2.4 devel) won't run from ROM. Is there a better boot loader I should be using?
You're a little sparse on info here but try lopping off the first 64KB of your zImage (or jump 0x10000 into the zImage that you have).
Mark
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
Quoted 2 lines · Mark A. Greer
You're a little sparse on info here but try lopping off the first 64KB of your zImage (or jump
0x10000into the zImage that you have).
Oh yeah...good point. It's just a reflex for me to check this, so I seldom think of it anymore. I think some board builds automatically chop this in the makefile with a 'dd' command (or, they used to) :-)
-- Dan
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/
Quoted 6 lines · Dan Malek
The old PPCBoot, and probably the new U-boot, kind of perform some of these functions. The reason I'm not a fan of doing this is if we make a change to the Linux calling sequence (which happens rarely) you also have to update the boot rom to match. Not a good thing, IMHO.
That's a very small price to pay for all the luxury of having a smarter boot-monitor.
And, how many times was the linux calling sequence changed in the last two years ?
cheers
** Sent via the linuxppc-embedded mail list. See http://lists.linuxppc.org/