zImage.elf loads but does not start

Mirek23 miroslaw.dach at psi.ch
Fri May 18 23:28:57 EST 2007


Hi Joe,

I have done this what you have suggested:

I have built statically busybox. During compilation of the busy box I have
go a warning that static build is buggy
but I have built the statically linked binary anyhow.

After that I have created the file:

dir /dev 755 0 0
nod /dev/console 644 0 0 c 5 1
nod /dev/ttyUL0    644 0 0 c 208  187
dir /proc 755 0 0
dir /sys 755 0 0
file /init /myrootfs/busybox 755 0 0

Next I have run the program 

usr/gen_init_cpio myList > myList.cpio

I have set in the .config CONFIG_INITRAMFS_SOURCE="myInit.cpio"
I have modified the CONFIG_CMDLINE="console=ttyUL0,9600"

I have built successfully the kernel and loaded it to my board. 
When I have tried to boot the kernel I got as following:

---------------------------------------------------------------------------------------------------------
loaded at:     00400000 0052C138                                                                                                                                                     
board data at: 0052A120 0052A138                                                                                                                                                     
relocated to:  00404040 00404058                                                                                                                                                     
zimage at:     00404DCD 00529D69                                                                                                                                                     
avail ram:     0052D000 04000000                                                                                                                                                     
                                                                                                                                                                                     
Linux/PPC load: console=ttyUL0,9600                                                                                                                                                  
Uncompressing Linux...done.                                                                                                                                                          
Now booting the kernel    

---------------------------------------------------------------------------
And the kernel did not start.

I have also tried various options:
console=ttyUL0,9600 root=/dev/initrd rw rdinit=/init
or 
console=ttyUL0,9600 root=/dev/ram0 rw rdinit=/init

Nothing helped.

I have also done the experiment:

I have set in the .config CONFIG_INITRAMFS_SOURCE=""
I have modified the CONFIG_CMDLINE="console=ttyUL0,9600"

When I have rebuilt the kernel it started to boot up to the point to mount
nfs and it failed.

Any idea why it did not boot with initramfs build in?

The kernel size with simple initramfs is 1.4 MB and without initramfs 1.1
MB.


Best Regards

Mirek






Mead, Joseph wrote:
> 
> Hi Mirek,
> 
> If you think the networking might be the source of the problem maybe try
> to make a very simple root file system using initramfs to see if you can
> get the init program (or busybox) working.   
> 
> Just create a file in that looks something like:
> 
> dir /dev 755 0 0
> nod /dev/console 644 0 0 c 5 1
> nod /dev/ttyS0   644 0 0 c 4 64
> dir /proc 755 0 0
> dir /sys 755 0 0
> file /init usr/busybox 755 0 0
> 
> and then tell the kernel about it General_Setup-> Initramfs source
> file(s)
> 
> It will build the file system into the kernel image.
> 
> Also, thanks for the files. 
> 
> Joe
>  
> 
> -----Original Message-----
> From: linuxppc-embedded-bounces+mead=bnl.gov at ozlabs.org
> [mailto:linuxppc-embedded-bounces+mead=bnl.gov at ozlabs.org] On Behalf Of
> Mirek23
> Sent: Tuesday, May 15, 2007 8:09 AM
> To: linuxppc-embedded at ozlabs.org
> Subject: RE: zImage.elf loads but does not start
> 
> 
>>It seems to be that the console works fine and the root file system is
> mounted properly via NFS.
>>I do not however understand why eldk4.1 init does not work.
> 
> I have done some more investigations. My observation is as following:
> 
> The eldk4.1/ppc_4xx root file system has the init which is not
> statically built. When I removed the lib directory on the NFS
> server:/opt/eldk4.1/ppc_4xx/lib the kernel has booted up to the point:
> 
> [    9.302101] VFS: Mounted root (nfs filesystem).
> [    9.357642] Freeing unused kernel memory: 96k init
> [    9.481509] Kernel panic - not syncing: No init found.  Try passing
> init=
> option to kernel.
> 
> 
> When the lib directory was present the last printed message was:
> [    9.357642] Freeing unused kernel memory: 96k init
> 
> I have observed the same behaviour with busybox accessed via NFS.
> I have compiled busybox with crosstool-0.43 (gcc-4.0.2 glibc-2.3.2)
> because
> eldk4.1 crosscompilers failed to compile busybox. When using busybox
> mounted via NFS I copied the lib directory from crosstool.
> Unfortunately also this time the system hanged at init.
> 
> My own version of init which uses printf just to print the string to the
> screen runs however fine.
> 
> Would somebody have some suggestion what might cause the problem to
> properly launch the init command.
> 
> Best Regards
> 
> Mirek
> --
> View this message in context:
> http://www.nabble.com/zImage.elf-loads-but-not-starts-tf3607582.html#a10
> 621564
> Sent from the linuxppc-embedded mailing list archive at Nabble.com.
> 
> _______________________________________________
> Linuxppc-embedded mailing list
> Linuxppc-embedded at ozlabs.org
> https://ozlabs.org/mailman/listinfo/linuxppc-embedded
> _______________________________________________
> Linuxppc-embedded mailing list
> Linuxppc-embedded at ozlabs.org
> https://ozlabs.org/mailman/listinfo/linuxppc-embedded
> 
> 

-- 
View this message in context: http://www.nabble.com/zImage.elf-loads-but-not-starts-tf3607582.html#a10682140
Sent from the linuxppc-embedded mailing list archive at Nabble.com.




More information about the Linuxppc-embedded mailing list