Boot up hangs at initial stage.

2,322 views
Skip to first unread message

sri

unread,
Aug 30, 2010, 12:09:11 AM8/30/10
to Android Linux Kernel Development
Hi,
We are working on froyo porting for zoom3 board using 2.6.32 kernel.
After giving support for zoom3 in the kernel, when we are trying to
boot it,
it stops at

Starting kernel ....


We are new to kenel development. Can anyone suggest how can we debug
further. Are there any tools to debug assembly code.

Unable to know where exactly it is stuck.

Thanks in Advance,
sri.

jack

unread,
Aug 30, 2010, 12:26:08 AM8/30/10
to Android Linux Kernel Development
Pass correct "console=ttyS**" option in the kernel command or u-
boot(is you are using u-boot) command line.

sri

unread,
Aug 30, 2010, 3:58:23 AM8/30/10
to Android Linux Kernel Development
Hi jack,

My bootargs are
setenv bootargs 'androidboot.console=ttyO3 console=ttyO3,115200n8
root=/dev/mmcblk0p2 rw rootdelay=1 mem=512M init=/init
videoout=omap24xxvout omap_vout.video1_numbuffers=6
omap_vout.vid1_static_vrfb_alloc=y omapfb.vram="0:4M"'

How will we get to know whether what console we need to give.
We got above bootargs from the manual.

jack

unread,
Aug 30, 2010, 4:19:13 AM8/30/10
to Android Linux Kernel Development
That will be in your kernel configuration, which UART you have
configure for low-level messages. console should be the same.

sri

unread,
Aug 30, 2010, 4:43:10 AM8/30/10
to Android Linux Kernel Development
Hi Jack,

I trying to boot up through mmc card.
And I have connected to minicom using USB.
So will UART holds any effect here?


Thanks,
Sri.

sri

unread,
Aug 30, 2010, 4:50:20 AM8/30/10
to Android Linux Kernel Development
Hi Jack,

I am trying to boot up through mmc card.

jack

unread,
Aug 30, 2010, 4:51:10 AM8/30/10
to Android Linux Kernel Development
yes it will have,please check your kernel config.

Vikram

unread,
Aug 31, 2010, 9:55:40 AM8/31/10
to Android Linux Kernel Development
What is the source of your kernel for zoom board?

TI keeps the kernel for the same at:
$git clone git://git.omapzoom.org/kernel/omap.git
Head: p-android-omap-2.6.32
Defconfig: android_zoom3_defconfig

white

unread,
Sep 1, 2010, 12:44:58 AM9/1/10
to Android Linux Kernel Development
First of all, your kernel and platform boots complete?

Second, Could you see any message from your uart?
If your kernel is hang up, you can see your bootloader messages.
> > > Sri.- 원본 텍스트 숨기기 -
>
> - 원본 텍스트 보기 -

sri

unread,
Sep 6, 2010, 2:27:31 AM9/6/10
to Android Linux Kernel Development
I can see bootloader messages.
After I give command "boot" , it says Starting kernel... and hangs..
And Can you tell me how to debug if it stucks at boot level( arch\arm
\boot in linux).
I have never worked on assembly language before.


Thanks,
Sri.

simon.ohlmer

unread,
Sep 6, 2010, 3:16:21 AM9/6/10
to android...@googlegroups.com
My tip is to check that you have built the right file system support
and have read/write to the root catalog.

/Simon

Sreekanth W

unread,
Sep 6, 2010, 3:55:26 AM9/6/10
to android...@googlegroups.com
You will have to debug the u-boot code.
the next message should be "Uncompressing Linux...done, booting the kernel."

What are steps you're performing for flashing the kernel?

Also make sure your uart driver is configured properly.
-

> --
> unsubscribe: android-kerne...@googlegroups.com
> website: http://groups.google.com/group/android-kernel

sri

unread,
Sep 9, 2010, 4:39:53 AM9/9/10
to Android Linux Kernel Development
Hi ,

@Sreekanth

I have placed debug msgs in u-boot till the place it jumps to kernel
and it is fine.
And I am not getting "Uncompressing Linux...done, booting the kernel."
This msg is from kernel right.
my uart configuration looks fine. I have used same uart config as that
of working kernel.

Steps I follow is:

Place uImage in sdcard and then connect to board and pc using usb and
try to load uImage using minicom.

@ simon,
my fs also looks fine.

Thanks,
Sri.

Amar Nath

unread,
Sep 10, 2010, 2:05:17 PM9/10/10
to android...@googlegroups.com
Hi Sri,

"Starting kernel..." is indeed the last message that u-boot prints
just before jumping to
the kernel entry point, so my understanding is that the your u-boot is
working just fine.

However, if your uImage is generated with a wrong entry point address
than what the
kernel is compiled for, its very much possible that your kernel
doesn't get executed at all.

I would have first checked if the "Entry Point" address printed by
u-boot just before
printing "Starting kernel..." closely matches to the corresponding
_stext virtual address
in the System.map file, generated in your kernel directory after the build.

As an example, lets say your system has a RAM memory bank mapped at phys. addr
0x80000000 and in your kernel its been mapped to a virtual address of
0xC0000000.

In this case, if the "Entry Point" address printed by u-boot is
0x80008000, you need to
ensure _stext has address 0xC0008000 assigned to it in the System.map
file (Note that
the offset value '8000' matches here).

If there is a mismatch here, u-boot would be jumping to an invalid
address where it could
not find the entry point to your kernel image and hence would fail to boot.

Hope this helps.

BR,
-Amar

sri

unread,
Sep 13, 2010, 7:29:35 AM9/13/10
to Android Linux Kernel Development
Hi Amar,

Thanks for explaining so well about address mapping which would be
very useful for newbies like me :)

My uImage start address and bootloader jumping address are same in my
case.
What I did wrong is that while merging code, I have done with arm part
and didnot touch drivers part.
So, my serial port was not properly configured and hence It is not
booting up.

Thanks to you all :)
Sri.

Ismail

unread,
Dec 13, 2011, 9:33:05 AM12/13/11
to android...@googlegroups.com

> On Thu, Sep 9, 2010 at 10:39 AM, sri <sresindhu <at> gmail.com> wrote:
> >
> > Hi ,
> >
> > @Sreekanth
> >
> > I have placed debug msgs in u-boot till the place it jumps to kernel
> > and it is fine.
> > And I am not getting "Uncompressing Linux...done, booting the kernel."
> > This msg is from kernel right.
> > my uart configuration looks fine. I have used same uart config as that
> > of working kernel.
> >
> > Steps I follow is:
> >
> > Place uImage in sdcard and then connect to board and pc using usb and
> > try to load uImage using minicom.
> >
> > @ simon,
> > my fs also looks fine.
> >
> > Thanks,
> > Sri.
> >
> > --

> > unsubscribe: android-kernel+unsubscribe <at> googlegroups.com
> > website: http://groups.google.com/group/android-kernel
>

Hi Amar,
the _stext address in my System.map shows c0008000
c0004000 A swapper_pg_dir
c0008000 T __init_begin
c0008000 T _sinittext
c0008000 T _stext
c0008000 T stext
c0008034 t __enable_mmu
c0008060 t __turn_mmu_on
c0008078 t __create_page_tables
c0008124 t __switch_data
c000814c t __mmap_switched
c0008194 t __error_p
c00081b0 t str_p1
c00081e7 t str_p2
c00081ec t __error_a

The zoom3 board is powercyling again and agian.The last debug message before
powercycle is :
Uncompressing Linux... done, booting the kernel.
On reset the uboot logs is seen again:
U-Boot 1.1.4-ge891bbac-dirty (Mar 18 2010 - 17:47:41)

OMAP3630-GP rev 1, CPU-OPP2 L3-200MHz
OMAP3630Zoom3 1.0 Version + mDDR (Boot NAND)
DRAM: 1024 MB
NAND:512 MiB


In: serial
Out: serial
Err: serial
Battery levels: main 3951 mV, backup 3078 mV
Hit any key to stop autoboot


Can you figure out what could be the issue.
Thanks,
Ismail


jagan

unread,
Dec 14, 2011, 1:01:44 AM12/14/11
to android...@googlegroups.com
I think use the fresh kernel suited for ZOOM3.
Try to give the proper details about the issue.

Regards,
Jagan.

Ismail

unread,
Dec 14, 2011, 2:22:25 AM12/14/11
to android...@googlegroups.com
I am trying to port gingerbread kernel to zoom3 board.

The kernel was download from omapzoom git server.
Kernel(top of the tree):
# git clone git://git.omapzoom.org/kernel/omap.git android-2.6.35
# cd android-2.6.35
# git checkout -b p-android-omap-2.6.35 --track origin/p-android-omap-2.6.35

defconfig used for building: android_zoom3_defconfig

After loading the kernel(through SD card) , the last cutecom logs shows:


Uncompressing Linux... done, booting the kernel.

After this the board seems to be rebooting again and the same logs are repeated.
The complete logs is as below:

U-Boot 1.1.4-ge891bbac-dirty (Mar 18 2010 - 17:47:41)

OMAP3630-GP rev 1, CPU-OPP2 L3-200MHz
OMAP3630Zoom3 1.0 Version + mDDR (Boot NAND)
DRAM: 1024 MB
NAND:512 MiB


In: serial
Out: serial
Err: serial

Battery levels: main 3957 mV, backup 3038 mV
Hit any key to stop autoboot: 3 \0x08\0x08\0x08 2 \0x08\0x08\0x08 1
\0x08\0x08\0x08 0
MMC1 Initalization OK

Reading data at 0x1d68e -- 1% complete.
Reading data at 0x1d6d3 -- 2% complete.
Reading data at 0x1d717 -- 3% complete.
Reading data at 0x1d75c -- 4% complete.
Reading data at 0x1d7a0 -- 5% complete.
Reading data at 0x1d7e5 -- 6% complete.
Reading data at 0x1d829 -- 7% complete.
Reading data at 0x1d86e -- 8% complete.
Reading data at 0x1d8b3 -- 9% complete.
Reading data at 0x1d8f7 -- 10% complete.
Reading data at 0x1d93c -- 11% complete.
Reading data at 0x1d980 -- 12% complete.
Reading data at 0x1d9c5 -- 13% complete.
Reading data at 0x1da09 -- 14% complete.
Reading data at 0x1da4e -- 15% complete.
Reading data at 0x1da92 -- 16% complete.
Reading data at 0x1dad7 -- 17% complete.
Reading data at 0x1db1c -- 18% complete.
Reading data at 0x1db60 -- 19% complete.
Reading data at 0x1dba5 -- 20% complete.
Reading data at 0x1dbe9 -- 21% complete.
Reading data at 0x1dc2e -- 22% complete.
Reading data at 0x1dc72 -- 23% complete.
Reading data at 0x1dcb7 -- 24% complete.
Reading data at 0x1dcfb -- 25% complete.
Reading data at 0x1dd40 -- 26% complete.
Reading data at 0x1dd85 -- 27% complete.
Reading data at 0x1ddc9 -- 28% complete.
Reading data at 0x1de0e -- 29% complete.
Reading data at 0x1de52 -- 30% complete.
Reading data at 0x1de97 -- 31% complete.
Reading data at 0x1dedb -- 32% complete.
Reading data at 0x1df20 -- 33% complete.
Reading data at 0x1df65 -- 34% complete.
Reading data at 0x1dfa9 -- 35% complete.
Reading data at 0x1dfee -- 36% complete.
Reading data at 0x1e032 -- 37% complete.
Reading data at 0x1e077 -- 38% complete.
Reading data at 0x1e0bb -- 39% complete.
Reading data at 0x1e100 -- 40% complete.
Reading data at 0x1e144 -- 41% complete.
Reading data at 0x1e189 -- 42% complete.
Reading data at 0x1e1ce -- 43% complete.
Reading data at 0x1e212 -- 44% complete.
Reading data at 0x1e257 -- 45% complete.
Reading data at 0x1e29b -- 46% complete.
Reading data at 0x1e2e0 -- 47% complete.
Reading data at 0x1e324 -- 48% complete.
Reading data at 0x1e369 -- 49% complete.
Reading data at 0x1e3ad -- 50% complete.
Reading data at 0x1e3f2 -- 51% complete.
Reading data at 0x1e437 -- 52% complete.
Reading data at 0x1e47b -- 53% complete.
Reading data at 0x1e4c0 -- 54% complete.
Reading data at 0x1e504 -- 55% complete.
Reading data at 0x1e549 -- 56% complete.
Reading data at 0x1e58d -- 57% complete.
Reading data at 0x1e5d2 -- 58% complete.
Reading data at 0x1e617 -- 59% complete.
Reading data at 0x1e65b -- 60% complete.
Reading data at 0x1e6a0 -- 61% complete.
Reading data at 0x1e6e4 -- 62% complete.
Reading data at 0x1e729 -- 63% complete.
Reading data at 0x1e76d -- 64% complete.
Reading data at 0x1e7b2 -- 65% complete.
Reading data at 0x1e7f6 -- 66% complete.
Reading data at 0x1e83b -- 67% complete.
Reading data at 0x1e880 -- 68% complete.
Reading data at 0x1e8c4 -- 69% complete.
Reading data at 0x1e909 -- 70% complete.
Reading data at 0x1e94d -- 71% complete.
Reading data at 0x1e992 -- 72% complete.
Reading data at 0x1e9d6 -- 73% complete.
Reading data at 0x1ea1b -- 74% complete.
Reading data at 0x1ea5f -- 75% complete.
Reading data at 0x1eaa4 -- 76% complete.
Reading data at 0x1eae9 -- 77% complete.
Reading data at 0x1eb2d -- 78% complete.
Reading data at 0x1eb72 -- 79% complete.
Reading data at 0x1ebb6 -- 80% complete.
Reading data at 0x1ebfb -- 81% complete.
Reading data at 0x1ec3f -- 82% complete.
Reading data at 0x1ec84 -- 83% complete.
Reading data at 0x1ecc9 -- 84% complete.
Reading data at 0x1ed0d -- 85% complete.
Reading data at 0x1ed52 -- 86% complete.
Reading data at 0x1ed96 -- 87% complete.
Reading data at 0x1eddb -- 88% complete.
Reading data at 0x1ee1f -- 89% complete.
Reading data at 0x1ee64 -- 90% complete.
Reading data at 0x1eea8 -- 91% complete.
Reading data at 0x1eeed -- 92% complete.
Reading data at 0x1ef32 -- 93% complete.
Reading data at 0x1ef76 -- 94% complete.
Reading data at 0x1efbb -- 95% complete.
Reading data at 0x1efff -- 96% complete.
Reading data at 0x1f044 -- 97% complete.
Reading data at 0x1f088 -- 98% complete.
Reading data at 0x1f0cd -- 99% complete.
Reading data at 0x1f111 -- 100% complete.
3510572 bytes read
## Booting image at 81c00000 ...
Image Name: Linux-2.6.35.7-00710-g51dde1f-di
Image Type: ARM Linux Kernel Image (uncompressed)
Data Size: 3510508 Bytes = 3.3 MB
Load Address: 80008000
Entry Point: 80008000
Verifying Checksum ... OK
OK

Starting kernel ...

Uncompressing Linux... done, booting the kernel.

U-Boot 1.1.4-ge891bbac-dirty (Mar 18 2010 - 17:47:41)

OMAP3630-GP rev 1, CPU-OPP2 L3-200MHz
OMAP3630Zoom3 1.0 Version + mDDR (Boot NAND)
DRAM: 1024 MB
NAND:512 MiB


In: serial
Out: serial
Err: serial

Battery levels: main 3957 mV, backup 3020 mV
Hit any key to stop autoboot: 3 \0x08\0x08\0x08 2 \0x08\0x08\0x08 1
\0x08\0x08\0x08 0
MMC1 Initalization OK

Reading data at 0x1d68e -- 1% complete.
Reading data at 0x1d6d3 -- 2% complete.
Reading data at 0x1d717 -- 3% complete.
Reading data at 0x1d7


Boot parameters are as below:
OMAP36XX ZOOM3 # printenv bootargs

bootargs=console=ttyS3,115200n8 root=/dev/mmcblk0p2 rw rootdelay=1 init=/init
videoout=omap24xxvout omap_vout.video1_numbuffers=6
omap_vout.vid1_static_vrfb_alloc=y omapfb.vram=?0:4M?


the "Entry Point" address printed by u-boot is

0x80008000, the _stext address in my System.map shows c0008000

Can anybody figure out what could be the possible issue?
Can anybody suggest how to debug this further.


Thanks,
Ismail.


sandesh D

unread,
Dec 14, 2011, 2:25:55 AM12/14/11
to android...@googlegroups.com
Can you enable the early printk from kernel and check machine id of bootloader and kernel are matching...? 

Ismail.




subhash neogi

unread,
Feb 20, 2012, 3:56:50 AM2/20/12
to android...@googlegroups.com
Hi I am trying to bring up Zoom3 board with android-2.6.35 kernel.

1. android-2.6.35 kernel is downloaded from omapzoom git server.

Kernel(top of the tree):
# git clone git://git.omapzoom.org/kernel/omap.git android-2.6.35
# cd android-2.6.35
# git checkout -b p-android-omap-2.6.35 --track origin/p-android-omap-2.6.35

     
2. We have used ‘android_zoom3_defconfig’ to build the kernel.


3. The following bootargs used for booting:

setenv bootargs 'console=ttyS3,115200n8 root=/dev/mmcblk0p2 rw rootdelay=1 init=/init omap_vout_mod.vid1_static_vrfb_alloc=y omap_vout_mod.video1_numbuffers=6
omapfb.vram=0:4M'
setenv 'mmcinit 0;fatload mmc 0 0x81c00000 uImage;bootm 0x81c00000’


4. We stuck at the ‘Uncompressing Linux... done, booting the kernel.’ while booting. Please find the below log for reference.


## Booting image at 81c00000 ...
   Image Name:   Linux-2.6.35.7-00711-g52de3da-di

   Image Type:   ARM Linux Kernel Image (uncompressed)
   Data Size:    3455848 Bytes =  3.3 MB

   Load Address: 80008000
   Entry Point:  80008000
   Verifying Checksum ... OK
OK

Starting kernel ...

Uncompressing Linux... done, booting the kernel.


5. We made the following changes to enable early debugging in ‘android_zoom3_defconfig’.
a.  CONFIG_DEBUG_LL=Y
b. CONFIG_EARLY_PRINTK=Y
c. CONFIG_CMDLINE="root=/dev/nfs nfsroot=192.168.0.1:/home/user/buildroot ip=192.168.0.2:192.168.0.1:192.168.0.1:255.255.255.0:tgt:eth0:off rw console=ttyS3,115200n8 debug earlyprintk".


6. As we put some logs it is clear that it stuck inside of rest init.
Inside rest_init, it creates new kernel thread “kernel_init”.
Code flow, do_basic_setup-->driver_init-->cpu_dev_init. It is consistently failing at cpu_dev_init.
Parallels it is also going through scheduler and keeps looping the task khelper.
Please find the below log:

EPK drivers/base/init.c 25 devtmpfs_init()
EPK drivers/base/init.c 27 devices_init()
EPK drivers/base/init.c 29 buses_init()
EPK drivers/base/init.c 31 classes_init()
EPK drivers/base/init.c 33 firmware_init()
EPK drivers/base/init.c 35 hypervisior_init()
EPK kernel/kmod.c 408  INSIDE CALL_USERMODEHELPER_EXEC
EPK kernel/kmod.c 423 wait = 0 , kmod_thread= 0 task = swapper
EPK kernel/kmod.c 439 WAITING FOR COMPLETION
CPU ID = 0
The Prev task is: swapper [1]
The current task_last is: khelper [6]
after need_resched_nonpreemptible..
after need_resched..
CPU ID = 0
The Prev task is: khelper [6]
The current task_last is: khelper [6]
after need_resched_nonpreemptible..
after need_resched..
CPU ID = 0
The Prev task is: khelper [6]
The current task_last is: khelper [7]
EPK:  kmod_thread of  khelper
CPU ID = 0
The Prev task is: khelper [7]
The current task_last is: khelper [6]
after need_resched_nonpreemptible..
after need_resched..
CPU ID = 0
The Prev task is: khelper [6]
The current task_last is: swapper [1]
after need_resched_nonpreemptible..
after need_resched..
EPK kernel/kmod.c 441  WAIT COMPLETION DONE
EPK drivers/base/init.c 41 platform_bus_init()
EPK drivers/base/init.c 45 system_init()
EPK drivers/base/cpu.c 253 Entering cpu_dev_init()
EPK kernel/kmod.c 408  INSIDE CALL_USERMODEHELPER_EXEC
EPK kernel/kmod.c 423 wait = 0 , kmod_thread= 0 task = swapper
EPK kernel/kmod.c 439 WAITING FOR COMPLETION
CPU ID = 0
The Prev task is: swapper [1]
The current task_last is: khelper [6]
after need_resched_nonpreemptible..
after need_resched..
CPU ID = 0
The Prev task is: khelper [6]
The current task_last is: khelper [7]
after need_resched_nonpreemptible..

Can anybody suggest how to solve the problem?

Thanks

Subhash

ajeeshc...@gmail.com

unread,
Feb 22, 2012, 11:53:31 PM2/22/12
to sandesh D, android...@googlegroups.com

Hi I am trying to bring up Zoom3 board with android-2.6.35 kernel.

1. android-2.6.35 kernel is downloaded from omapzoom git server.

Kernel(top of the tree):
# git clone git://git.omapzoom.org/kernel/omap.git android-2.6.35
# cd android-2.6.35
# git checkout -b p-android-omap-2.6.35 --track origin/p-android-
omap-2.6.35

2. We have used ‘android_zoom3_defconfig’ to build the kernel.


3. The following bootargs used for booting:

setenv bootargs 'console=ttyS3,115200n8 root=/dev/mmcblk0p2 rw
rootdelay=1 init=/init omap_vout_mod.vid1_static_vrfb_alloc=y
omap_vout_mod.video1_numbuffers=6
omapfb.vram=0:4M'
setenv 'mmcinit 0;fatload mmc 0 0x81c00000 uImage;bootm 0x81c00000’


4. We stuck at the ‘Uncompressing Linux... done, booting the kernel.’


while booting. Please find the below log for reference.

## Booting image at 81c00000 ...
Image Name: Linux-2.6.35.7-00711-g52de3da-di


Image Type: ARM Linux Kernel Image (uncompressed)

Data Size: 3455848 Bytes = 3.3 MB


Load Address: 80008000
Entry Point: 80008000
Verifying Checksum ... OK
OK

Starting kernel ...

Uncompressing Linux... done, booting the kernel.

Can anybody suggest how to solve the problem?

Thanks
Ajeesh


On Dec 14 2011, 12:25 pm, sandesh D <sandeshdgo...@gmail.com> wrote:
> Can you enable the early printk from kernel and check machine id of
> bootloader and kernel are matching...?
>

Reply all
Reply to author
Forward
0 new messages