[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Using Linux as a boot loader -- status and RFH



On 01/30/2011 04:39 PM, Eric Cooper wrote:
I've been experimenting with using a stripped-down Linux kernel
instead of u-boot.  I'm working with a Seagate DockStar, but the same
approach should work with the Sheevaplug or other variants.  The idea
(which is not original -- you can find several other similar projects
via Google) is to use the power of the Linux networking, filesystem,
and USB stacks to load whatever kernel you want, and then the kexec
system call to warm-boot into it.


Neat idea.  Out of curiosity, why not just run the bootloader kernel?

Unfortunately, I've hit a brick wall: after loading a kernel (via
"kexec -l ...") and executing it ("kexec -e"), the new kernel hangs
during initialization when it tries to access various hardware
registers. These same hardware registers are accessed when the kernel
is booted via u-boot, so there's some bug here I haven't been able to
track down. See this thread for more details:

http://lists.infradead.org/pipermail/linux-arm-kernel/2011-January/039949.html

If anyone can help me solve this, I'd be very grateful, and could move
on to the final step of flashing the minimal kernel and booting it
directly from the hardware. My early tests are promising: the minimal
kernel and initramfs are only 1.5MB, and it boots to a shell in about
5 seconds.


Nice. Have you tried compiling the commandline options into the kernel you're trying to kexec? eg CONFIG_CMDLINE

Do have a write-up somewhere?  I'd like to take a look.

hth,

Jason.


Reply to: