This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

kernel halt

hi everyone i am trying to embedded linux in DM6446. i am using open source code to build the kernel, using cross compiler. when i load the kernel using tftp and run it the kernel gets halted.can anyone help me.here is whaT I AM GETTING.

i have not loaded the file system for the kernel.

bootargs=mem=56M console=ttyS0,115200n8 root=/dev/hda1 rw noinitrd ip=dhcp
bootcmd=setenv setboot setenv bootargs \$(bootargs) video=dm64xxfb:output=\$(videostd);run setboot
baudrate=115200
bootfile="uImage"
ethaddr=00:1c:c0:0a:00:02
ipaddr=172.16.0.91
serverip=172.16.0.97
gatewayip=172.16.0.10
netmask=255.255.240.0
stdin=serial
stdout=serial
stderr=serial
serial#=FAILED
ver=U-Boot 2009.06 (Aug 10 2009 - 18:38:34)
 
Environment size: 418/131068 bytes
U-Boot > bootm

## Booting kernel from Legacy Image at 80700000 ...

   Image Name:   Linux-2.6.31-rc5-davinci1

   Created:      2009-08-16  13:56:56 UTC

   Image Type:   ARM Linux Kernel Image (uncompressed)

   Data Size:    1478408 Bytes =  1.4 MB

   Load Address: 80008000

   Entry Point:  80008000

   Verifying Checksum ... OK

   Loading Kernel Image ... OK

OK

 

Starting kernel ...

 

Uncompressing Linux.............................................................

................................... done, booting the kernel.

  • Looks like is done uncompressing the kernel and it is about to start running it but somehow it gets lost.  May I ask where you got this kernel from and why you are not using the kernel provided by TI with DM6446 DVSDK?  The log in the latest DM6446 DVSDK (2.00.00.22) looks like

    Bytes transferred = 2017360 (1ec850 hex)
    ## Booting image at 80700000 ...
       Image Name:   Linux-2.6.18_pro500-davinci_evm-
       Image Type:   ARM Linux Kernel Image (uncompressed)
       Data Size:    2017296 Bytes =  1.9 MB
       Load Address: 80008000
       Entry Point:  80008000
       Verifying Checksum ... OK
    OK

    Starting kernel ...

    Uncompressing Linux.............................................................
    ........................................................................ done, b
    ooting the kernel.
    Linux version 2.6.18_pro500-davinci_evm-arm_v5t_le (root@cna0270599.am.dhcp.ti.c
    om) (gcc version 4.2.0 (MontaVista 4.2.0-16.0.32.0801914 2008-08-30)) #1 PREEMPT
     Mon Aug 17 15:09:29 CDT 2009
    CPU: ARM926EJ-S [41069265] revision 5 (ARMv5TEJ), cr=00053177
    Machine: DaVinci EVM
    Memory policy: ECC disabled, Data cache writeback

  • Actually i was following the wiki linux tool chain page.I am using ELDK cross compiler for generating the uImage file.The source code for the uImage kernel is downloaded from git.

    Can u help me what is going wrong or what i should do?

  • can you post the URL to the wiki page you are referring to?

  • The URL to the Page is http://wiki.davincidsp.com/index.php/Linux_Toolchain    

     

     

    Can u plz send me your uImage file that i can load in my DM6446 and check.I have read in the forums that problem might be bootarg do u find that in mine.

  • Actually we have made our own custom board and trying to loading the kernel but it halts.Is kernel provided by TI with DM6446 DVSDK is going to work with our board?

  • actually since you mentioned bootargs,

    bootargs=mem=56M console=ttyS0,115200n8 root=/dev/hda1 rw noinitrd ip=dhcp

    your bootargs appear to be suggesting your file-system will be located in a hard disk drive (HDD); do you have an HDD present in your proprietary hardware board?

    The DVSDK provided kernel should work provided

    1) you take out any drivers for peripherals present on our EVM that may not be present in your board

    2) you write new drivers for any peripheral present on your board that may not be present on our EVM

    3) you reconfigure system memory if required (e.g. if you are using different size DDR2 than what is on our EVM)

  • Actually i havn't build any file-system file-system yet .just made uImage file for the kernel. i have changed the bootargs to 

    bootargs=console=ttyS0,115200n8 nointrd rw

     

    but still the kernel gets halt.size of DDR2 in our board is 256MB

  • FYI, without a file-system, you will not see a log-in prompt. 

    The cause of the halt is likely due to one of the three reasons numbered in my previous post.

  • Hi Juan i have enabled the debuging option now i got the following error msgs.It gives wrong machine number error.

    Image Name: Linux-2.6.31-rc5-davinci1
    >
    > Created: 2009-08-16 13:56:56 UTC
    >
    > Image Type: ARM Linux Kernel Image (uncompressed)
    >
    > Data Size: 1478408 Bytes = 1.4 MB
    >
    > Load Address: 80008000
    >
    > Entry Point: 80008000
    >
    > Verifying Checksum ... OK
    >
    > Loading Kernel Image ... OK
    >
    >
    >
    > Starting kernel ...
    >
    >
    >
    > Uncompressing
    > Linux................................................................................................
    > done, booting the kernel.
    >
    >
    >
    >
    > Error: unrecognized/unsupported machine ID (r1 =
    > 0x000004e7).
    >
    >
    >
    > Available machine support:
    >
    >
    >
    > ID (hex) NAME
    >
    > 00000385 DaVinci
    > DM644x EVM
    >
    > 00000679 Lyrtech
    > SFFSDR
    >
    > 00000565 DaVinci
    > DM355 EVM
    >
    > 0000085a DaVinci
    > DM355 leopard
    >
    > 00000564 DaVinci
    > DM646x EVM
    >
    > 00000793 DaVinci
    > DM365 EVM
    >
    >
    >
    > Please check your kernel config and/or bootloader

     

     

    Do you know what is the cause of that?

    We have made our own custom board DM6446.

     

     

     

  • Hi Rohan,

    Both the boot loader and the Kernel should have  the  same  machine ID. Otherwise
    the kernel won't boot.

    If your machine ID does not match, you can try making appropriate changes in the file

    ../arch/arm/tools/mach-types

    and try recompiling.

    Hope this helps.

    Regards,

    Sid

     

  • i am able to boot the kernel and got the following kernel panic msgs.Since dere was not any FILESYSTEM.Does any1

     

    have any idea or reference how to create a file system and instructions to load in the memory?

     

     

    Starting kernel ...


    Uncompressing Linux.............................................................
    ................................... done, booting the kernel.
    Linux version 2.6.31-rc5-davinci1 (root@skw) (gcc version 4.2.2) #1 PREEMPT Thu
    Aug 20 11:17:51 WIT 2009
    CPU: ARM926EJ-S [41069265] revision 5 (ARMv5TEJ), cr=00053177
    CPU: VIVT data cache, VIVT instruction cache
    Machine: DaVinci DM644x EVM
    Memory policy: ECC disabled, Data cache writeback
    DaVinci dm6446a variant 0x1
    Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 65024
    Kernel command line: console=ttyS0,115200n8 noinitrd rw
    PID hash table entries: 1024 (order: 10, 4096 bytes)
    Dentry cache hash table entries: 32768 (order: 5, 131072 bytes)
    Inode-cache hash table entries: 16384 (order: 4, 65536 bytes)
    Memory: 256MB = 256MB total
    Memory: 256540KB available (2708K code, 295K data, 124K init, 0K highmem)
    SLUB: Genslabs=11, HWalign=32, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
    NR_IRQS:229
    Console: colour dummy device 80x30
    Calibrating delay loop... 147.86 BogoMIPS (lpj=739328)
    Mount-cache hash table entries: 512
    CPU: Testing write buffer coherency: ok
    DaVinci: 71 gpio irqs
    NET: Registered protocol family 16
    WARNING: both IDE and Flash are enabled, but they share AEMIF pins.
            Disable IDE for NAND/NOR support.
    MUX: Setting register HPIEN_DISABLE
               PINMUX0 (0x00000000) = 0x80000c1f -> 0x80000c1f
    MUX: initialized ATAEN
    MUX: Setting register ATAEN
               PINMUX0 (0x00000000) = 0x80000c1f -> 0x80020c1f
    MUX: initialized HDIREN
    MUX: Setting register HDIREN
               PINMUX0 (0x00000000) = 0x80020c1f -> 0x80030c1f
    MUX: initialized MCBSP
    MUX: Setting register MCBSP
               PINMUX1 (0x00000004) = 0x00000081 -> 0x00000481
    bio: create slab <bio-0> at 0
    pcf857x: probe of 1-0038 failed with error -121
    pcf857x: probe of 1-0039 failed with error -121
    pcf857x: probe of 1-003a failed with error -121
    NET: Registered protocol family 2
    IP route cache hash table entries: 2048 (order: 1, 8192 bytes)
    TCP established hash table entries: 8192 (order: 4, 65536 bytes)
    TCP bind hash table entries: 8192 (order: 3, 32768 bytes)
    TCP: Hash tables configured (established 8192 bind 8192)
    TCP reno registered
    NET: Registered protocol family 1
    msgmni has been set to 501
    io scheduler noop registered
    io scheduler anticipatory registered (default)
    Setting Up Clocks for DM420 OSD
    Console: switching to colour frame buffer device 90x30
    fb0: dm_osd0_fb frame buffer device
    fb1: dm_vid0_fb frame buffer device
    fb2: dm_osd1_fb frame buffer device
    fb3: dm_vid1_fb frame buffer device
    Serial: 8250/16550 driver, 3 ports, IRQ sharing disabled
    Platform driver 'serial8250' needs updating - please use dev_pm_ops
    serial8250.0: ttyS0 at MMIO 0x1c20000 (irq = 40) is a 16550A
    console [ttyS0] enabled
    serial8250 serial8250.0: unable to register port at index 1 (IO0 MEM1c20400 IRQ4
    1): -22
    serial8250 serial8250.0: unable to register port at index 2 (IO0 MEM1c20800 IRQ4
    2): -22
    brd: module loaded
    at24 1-0050: 32768 byte 24c256 EEPROM (writable)
    davinci_emac_probe: using random MAC addr: 0e:bb:af:11:24:84
    emac-mii: probed
    dm9000 Ethernet Driver, V1.31
    Platform driver 'dm9000' needs updating - please use dev_pm_ops
    console [netcon0] enabled
    netconsole: network logging started
    i2c /dev entries driver
    TCP cubic registered
    NET: Registered protocol family 17
    RPC: Registered udp transport module.
    RPC: Registered tcp transport module.
    Clocks: disable unused uart1
    Clocks: disable unused uart2
    Clocks: disable unused ide
    Clocks: disable unused asp0
    Clocks: disable unused mmcsd
    Clocks: disable unused spi
    Clocks: disable unused usb
    Clocks: disable unused vlynq
    Clocks: disable unused pwm0
    Clocks: disable unused pwm1
    Clocks: disable unused pwm1
    Clocks: disable unused timer1
    Root-NFS: No NFS server available, giving up.
    VFS: Unable to mount root fs via NFS, trying floppy.
    VFS: Cannot open root device "<NULL>" or unknown-block(2,0)
    Please append a correct "root=" boot option; here are the available partitions:
    Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(2,0)
    Backtrace:
    [<c002b6a0>] (dump_backtrace+0x0/0x110) from [<c002b7e4>] (dump_stack+0x18/0x1c)

     r6:c0021850 r5:c02ebd24 r4:cf823f58
    [<c002b7cc>] (dump_stack+0x0/0x1c) from [<c003c438>] (panic+0x54/0x134)
    [<c003c3e4>] (panic+0x0/0x134) from [<c000916c>] (mount_block_root+0x1d4/0x21c)
     r3:00000001 r2:cf822000 r1:cf823f58 r0:c0291d54
    [<c0008f98>] (mount_block_root+0x0/0x21c) from [<c0009278>] (mount_root+0xc4/0xf
    c)
    [<c00091b4>] (mount_root+0x0/0xfc) from [<c000941c>] (prepare_namespace+0x16c/0x
    1d0)
     r5:c00204a4 r4:c02eb804
    [<c00092b0>] (prepare_namespace+0x0/0x1d0) from [<c0008958>] (kernel_init+0xd8/0
    x10c)
     r5:c00204a4 r4:c02eb7f8
    [<c0008880>] (kernel_init+0x0/0x10c) from [<c003f4d0>] (do_exit+0x0/0x62c)
     r5:00000000 r4:00000000

     

     

     

     

     

     

  • There are many ways to load a file-system; one of the most common forms is via NFS and this is discussed in Getting Started Guide (GSG).  You normally have to tell the system where to find the file-system (done via u-boot bootargs).  From your log above, I can tell the current setting is

    console=ttyS0,115200n8 noinitrd rw

    which does not specify any file-system to load.  The GSG should instruct you on how to configure bootargs to load a file-system (such as the one included in our DVSDK software) via NFS

  • I have an error in bootargs what is this  "root=" boot option; here are the available partitions but they are not displayed.Can u tell what does dat stands for?

    Starting kernel ...

    Uncompressing Linux.............................................................
    ................................... done, booting the kernel.
    Linux version 2.6.31-rc5-davinci1 (root@skw) (gcc version 4.2.2) #1 PREEMPT Thu
    Aug 20 11:17:51 WIT 2009
    CPU: ARM926EJ-S [41069265] revision 5 (ARMv5TEJ), cr=00053177
    CPU: VIVT data cache, VIVT instruction cache
    Machine: DaVinci DM644x EVM
    Memory policy: ECC disabled, Data cache writeback
    DaVinci dm6446a variant 0x1
    Built 1 zonelists in Zone order, mobility grouping on.  Total pages: 65024
    Kernel command line: console=ttyS0,115200n8 noinitrd rw root=/dev/nfs nfsro
    ot=172.16.1.102:/home/admin,nolock,tcp davinci_capture.channel0_numbuffers=4
    Unknown boot option `davinci_capture.channel0_numbuffers=4': ignoring
    PID hash table entries: 1024 (order: 10, 4096 bytes)
    Dentry cache hash table entries: 32768 (order: 5, 131072 bytes)
    Inode-cache hash table entries: 16384 (order: 4, 65536 bytes)
    Memory: 256MB = 256MB total
    Memory: 256540KB available (2708K code, 295K data, 124K init, 0K highmem)
    SLUB: Genslabs=11, HWalign=32, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
    NR_IRQS:229
    Console: colour dummy device 80x30
    Calibrating delay loop... 147.86 BogoMIPS (lpj=739328)
    Mount-cache hash table entries: 512
    CPU: Testing write buffer coherency: ok
    DaVinci: 71 gpio irqs
    NET: Registered protocol family 16
    WARNING: both IDE and Flash are enabled, but they share AEMIF pins.
            Disable IDE for NAND/NOR support.
    MUX: Setting register HPIEN_DISABLE
               PINMUX0 (0x00000000) = 0x80000c1f -> 0x80000c1f
    MUX: initialized ATAEN
    MUX: Setting register ATAEN
               PINMUX0 (0x00000000) = 0x80000c1f -> 0x80020c1f
    MUX: initialized HDIREN
    MUX: Setting register HDIREN
               PINMUX0 (0x00000000) = 0x80020c1f -> 0x80030c1f
    MUX: initialized MCBSP
    MUX: Setting register MCBSP
               PINMUX1 (0x00000004) = 0x00000081 -> 0x00000481
    bio: create slab <bio-0> at 0
    pcf857x: probe of 1-0038 failed with error -121
    pcf857x: probe of 1-0039 failed with error -121
    pcf857x: probe of 1-003a failed with error -121
    NET: Registered protocol family 2
    IP route cache hash table entries: 2048 (order: 1, 8192 bytes)
    TCP established hash table entries: 8192 (order: 4, 65536 bytes)
    TCP bind hash table entries: 8192 (order: 3, 32768 bytes)
    TCP: Hash tables configured (established 8192 bind 8192)
    TCP reno registered
    NET: Registered protocol family 1
    msgmni has been set to 501
    io scheduler noop registered
    io scheduler anticipatory registered (default)
    Setting Up Clocks for DM420 OSD
    Console: switching to colour frame buffer device 90x30
    fb0: dm_osd0_fb frame buffer device
    fb1: dm_vid0_fb frame buffer device
    fb2: dm_osd1_fb frame buffer device
    fb3: dm_vid1_fb frame buffer device
    Serial: 8250/16550 driver, 3 ports, IRQ sharing disabled
    Platform driver 'serial8250' needs updating - please use dev_pm_ops
    serial8250.0: ttyS0 at MMIO 0x1c20000 (irq = 40) is a 16550A
    console [ttyS0] enabled
    serial8250 serial8250.0: unable to register port at index 1 (IO0 MEM1c20400 IRQ4
    1): -22
    serial8250 serial8250.0: unable to register port at index 2 (IO0 MEM1c20800 IRQ4
    2): -22
    brd: module loaded
    at24 1-0050: 32768 byte 24c256 EEPROM (writable)
    davinci_emac_probe: using random MAC addr: 92:b6:fd:91:cf:13
    emac-mii: probed
    dm9000 Ethernet Driver, V1.31
    Platform driver 'dm9000' needs updating - please use dev_pm_ops
    console [netcon0] enabled
    netconsole: network logging started
    i2c /dev entries driver
    TCP cubic registered
    NET: Registered protocol family 17
    RPC: Registered udp transport module.
    RPC: Registered tcp transport module.
    Clocks: disable unused uart1
    Clocks: disable unused uart2
    Clocks: disable unused ide
    Clocks: disable unused asp0
    Clocks: disable unused mmcsd
    Clocks: disable unused spi
    Clocks: disable unused usb
    Clocks: disable unused vlynq
    Clocks: disable unused pwm0
    Clocks: disable unused pwm1
    Clocks: disable unused pwm2
    Clocks: disable unused timer1
    Looking up port of RPC 100003/2 on 172.16.1.102
    rpcbind: server 172.16.1.102 not responding, timed out
    Root-NFS: Unable to get nfsd port number from server, using default
    Looking up port of RPC 100005/1 on 172.16.1.102
    rpcbind: server 172.16.1.102 not responding, timed out
    Root-NFS: Unable to get mountd port number from server, using default
    Root-NFS: Server returned error -5 while mounting /home/admin
    VFS: Unable to mount root fs via NFS, trying floppy.
    VFS: Cannot open root device "nfs" or unknown-block(2,0)
    Please append a correct "root=" boot option; here are the available partitions:
    Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(2,0)
    Backtrace:
    [<c002b6a0>] (dump_backtrace+0x0/0x110) from [<c002b7e4>] (dump_stack+0x18/0x1c)

     r6:c0021850 r5:c02ebd24 r4:cf823f58
    [<c002b7cc>] (dump_stack+0x0/0x1c) from [<c003c438>] (panic+0x54/0x134)
    [<c003c3e4>] (panic+0x0/0x134) from [<c000916c>] (mount_block_root+0x1d4/0x21c)
     r3:00000001 r2:cf822000 r1:cf823f58 r0:c0291d54
    [<c0008f98>] (mount_block_root+0x0/0x21c) from [<c0009278>] (mount_root+0xc4/0xf
    c)
    [<c00091b4>] (mount_root+0x0/0xfc) from [<c000941c>] (prepare_namespace+0x16c/0x
    1d0)
     r5:c0021808 r4:c02eb804
    [<c00092b0>] (prepare_namespace+0x0/0x1d0) from [<c0008958>] (kernel_init+0xd8/0
    x10c)
     r5:c00204a4 r4:c02eb7f8
    [<c0008880>] (kernel_init+0x0/0x10c) from [<c003f4d0>] (do_exit+0x0/0x62c)
     r5:00000000 r4:00000000

  • have you seen the Getting Started Guide?  It discusses in step by step format how to set up and NFS file-system, including services that must be enabled in host and u-boot configurations that are needed on target.  This is general Linux stuff that we try to document to help our customers; if you have not read this doc, I would suggest to start there as it may save you a lot of head-aches and time.

  • hey Juan i have seen the getting started guide I have enabled the nfs services on the host i want to mount my filesystem on the host but it gives error:

    Looking up port of RPC 100003/2 on 192.16.1.102

    rpcbind: server 192.16.1.102 not responding, timed out

    Root-NFS: Unable to get nfsd port number from server, using default

    Looking up port of RPC 100005/1 on 192.16.1.102

    rpcbind: server 192.16.1.102 not responding, timed out

    Root-NFS: Unable to get mountd port number from server, using default

    Root-NFS: Server returned error -5 while mounting /home/admin

    VFS: Unable to mount root fs via NFS, trying floppy.

    VFS: Cannot open root device "nfs" or unknown-block(2,0)

    <==========================================================>

    As discussed in my previous post.can you tell what probelm is it dere

  • This problem is a bit difficult to trouble-shoot because you are using open source kernel which you put together (not tested and unknown to be working).  This means the problem could lie in either target software or host software.  Our GSG assumes you are working with our EVM and our DVSDK software (tested and known to be working), hence it describes how to setup the NFS service in the host (e.g. edit /etc/exports with your NFS directory and restart NFS service) and required bootargs (e.g. root=/dev/nfs....) to get this setup working.  We can double check your steps if you post your host's /etc/exports file and your u-boot environment variables, but I suspect that you have already done this.

    As an alternative, you can try using static ips instead of dhcp server assigned dynamic ips (would only help if there is an issue with your router's dhcp server).  Instructions for doing this are described http://focus.ti.com/general/docs/litabsmultiplefilelist.tsp?literatureNumber=spraaq0

     

  • Have seen getting started guide but i have set the nfs server able to download uImage from it but when i load the uImage kernel waits rpcbind and then says kernel time out.unable to get the mounted port number frm the server.

  • I have done this using static ip not dhcp i will soon post the etc/exports  and the u-boot variables....

  • here is my etc/exports file on the host server.

    /home/admin 172.16.0.0/255.255.240.0(rw,insecure,sync,no_subtree_check,fsid=0,no_root_squash)

  • Roh@n T@bish said:

    here is my etc/exports file on the host server.

    /home/admin 172.16.0.0/255.255.240.0(rw,insecure,sync,no_subtree_check,fsid=0,no_root_squash)

    This certainly is different than what is suggested in our Getting Started Guide; can you try what is suggested in the GSG

  • The debuging option tells that the machine for which the u-boot is compiled and for which the Kernel (uImage) is compiled both are different you need to do the source modification in the file

    u-boot/include/config/davinci_dvevm.h

     

    and configure it for NAND(Large or Small Pages) or for NOR will resolve the problem

  • Looking up port of RPC 100003/2 on 192.16.1.102

    rpcbind: server 192.16.1.102 not responding, timed out

    Root-NFS: Unable to get nfsd port number from server, using default

    Looking up port of RPC 100005/1 on 192.16.1.102

    rpcbind: server 192.16.1.102 not responding, timed out

    Root-NFS: Unable to get mountd port number from server, using default

    Root-NFS: Server returned error -5 while mounting /home/admin

    VFS: Unable to mount root fs via NFS, trying floppy.

    VFS: Cannot open root device "nfs" or unknown-block(2,0)

    <==========================================================>

    now the server returned error -5 is I/O error it means that the ethernet device not getting detected.

    Try passing static bootargs will show whether the kernel PHY is detected or not.if you get something like this

    eth0:No Phy Found.

    it means that your PHY is not detected.

     then you need to select the proper PHY that you have attached to your custom board.