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.

AM3359: Kernel panic with no rfs error

Part Number: AM3359
Other Parts Discussed in Thread: AM3352

Hi,

I'm working on a custom board designed with AM3359 which is made to run Linux Kernel with Uboot.

Uboot & MLO booting over UART, then receiving the zImage and dtb to DDR memory. Linux & dtb generated by following the steps from TI SDK links. Using TI TINY FS (due to image size requirements).

Following is the command issued to boot kernel from uboot:

run bootargs; //having console, rw only in text

bootz 0x80000000 - 0x8f000000

0x8000_0000 - contains zImage with rfs

0x8f00_0000 - contains dtb 

Able to see the kernel booting prints and at the end it's observed that Kernel panic with error as no root rfs found.

Please help. Thanks

  • Hi,

    Please attach the full kernel boot log.

  • HI Bin Liu,

    Attached the prints invoking Linux through U-Boot.

    U-Boot# pri nand argsargs
    nandargs=setenv bootargs console=${console} imageType=${imageType}${optargs} root=${nandroot} rootfstype=${nandrootfstype}

    U-Boot# setenv fdtaddr 0x84000000 

    U-Boot# setenv fdt_offset 0x02500000
    U-Boot# setenv loadaddr 0x80000000
    U-Boot# setenv kernel_offset 0x02600000
    U-Boot# setenv kernel_size 0x01000000
    U-Boot# setenv bootargs console=${console} root=${nandroot} rootfstype=${nandrootfstype}
    U-Boot# setenv nandboot echo Booting from nand ...; run nandargs; nand read ${fdtaddr} ${fdt_offset} 0xA000; nand read ${loadaddr} ${kernel_offset} ${kernel_size}; bootz ${loadaddr} - ${fdtaddr}

    NAND read: device 0 offset 0x2500000, size 0xa000
    40960 bytes read: OK

    NAND read: device 0 offset 0x2600000, size 0x1000000
    16777216 bytes read: OK
    Kernel image @ 0x80000000 [ 0x000000 - 0xcba200 ]
    ## Flattened Device Tree blob at 84000000
    Booting using the fdt blob at 0x84000000
    Loading Device Tree to 8f321000, end 8f32c81a ... OK

    Starting kernel ...

    [ 0.000000] Booting Linux on physical CPU 0x0
    [ 0.000000] Linux version 4.19.59-g5f8c1c6121 (root@ubuntu-Vostro-2520) (gcc version 8.3.0 (GNU Toolchain for the A-profile Architecture 8.3-2019.03 (arm-rel-8.36))) #7 PREEMPT Thu Nov 5 14:23:38 IST 2020
    [ 0.000000] CPU: ARMv7 Processor [413fc082] revision 2 (ARMv7), cr=10c5387d
    [ 0.000000] CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing instruction cache
    [ 0.000000] OF: fdt: Machine model: TI AM335x EVM
    [ 0.000000] Memory policy: Data cache writeback
    [ 0.000000] efi: Getting EFI parameters from FDT:
    [ 0.000000] efi: UEFI not found.
    [ 0.000000] cma: Reserved 48 MiB at 0x8c000000
    [ 0.000000] CPU: All CPU(s) started in SVC mode.
    [ 0.000000] AM335X ES2.1 (sgx neon)
    [ 0.000000] random: get_random_bytes called from start_kernel+0xa0/0x420 with crng_init=0
    [ 0.000000] Built 1 zonelists, mobility grouping on. Total pages: 64960
    [ 0.000000] Kernel command line: console=ttyO0,115200n8 imageType=working root=rw rootfstype=
    [ 0.000000] Dentry cache hash table entries: 32768 (order: 5, 131072 bytes)
    [ 0.000000] Inode-cache hash table entries: 16384 (order: 4, 65536 bytes)
    [ 0.000000] Memory: 188136K/262144K available (8192K kernel code, 299K rwdata, 2516K rodata, 10240K init, 249K bss, 24856K reserved, 49152K cma-reserved, 0K highmem)
    [ 0.000000] Virtual kernel memory layout:
    [ 0.000000] vector : 0xffff0000 - 0xffff1000 ( 4 kB)
    [ 0.000000] fixmap : 0xffc00000 - 0xfff00000 (3072 kB)
    [ 0.000000] vmalloc : 0xd0800000 - 0xff800000 ( 752 MB)
    [ 0.000000] lowmem : 0xc0000000 - 0xd0000000 ( 256 MB)
    [ 0.000000] pkmap : 0xbfe00000 - 0xc0000000 ( 2 MB)
    [ 0.000000] modules : 0xbf000000 - 0xbfe00000 ( 14 MB)
    [ 0.000000] .text : 0x(ptrval) - 0x(ptrval) (9184 kB)
    [ 0.000000] .init : 0x(ptrval) - 0x(ptrval) (10240 kB)
    [ 0.000000] .data : 0x(ptrval) - 0x(ptrval) ( 300 kB)
    [ 0.000000] .bss : 0x(ptrval) - 0x(ptrval) ( 250 kB)
    [ 0.000000] SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
    [ 0.000000] rcu: Preemptible hierarchical RCU implementation.
    [ 0.000000] Tasks RCU enabled.
    [ 0.000000] NR_IRQS: 16, nr_irqs: 16, preallocated irqs: 16
    [ 0.000000] IRQ: Found an INTC at 0x(ptrval) (revision 5.0) with 128 interrupts
    [ 0.000000] OMAP clockevent source: timer2 at 25000000 Hz
    [ 0.000014] sched_clock: 32 bits at 25MHz, resolution 40ns, wraps every 85899345900ns
    [ 0.000033] clocksource: timer1: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 76450417870 ns
    [ 0.000044] OMAP clocksource: timer1 at 25000000 Hz
    [ 0.000192] timer_probe: no matching timers found
    [ 0.000371] Console: colour dummy device 80x30
    [ 0.000398] WARNING: Your 'console=ttyO0' has been replaced by 'ttyS0'
    [ 0.000406] This ensures that you still see kernel messages. Please
    [ 0.000411] update your kernel commandline.
    [ 0.000466] Calibrating delay loop... 829.84 BogoMIPS (lpj=4149248)
    [ 0.089232] pid_max: default: 32768 minimum: 301
    [ 0.089429] Mount-cache hash table entries: 1024 (order: 0, 4096 bytes)
    [ 0.089443] Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes)
    [ 0.090247] CPU: Testing write buffer coherency: ok
    [ 0.090314] CPU0: Spectre v2: using BPIALL workaround
    [ 0.091176] Setting up static identity map for 0x80100000 - 0x80100060
    [ 0.091330] rcu: Hierarchical SRCU implementation.
    [ 0.091678] EFI services will not be available.
    [ 0.093097] devtmpfs: initialized
    [ 0.100097] VFP support v0.3: implementor 41 architecture 3 part 30 variant c rev 3
    [ 0.100470] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
    [ 0.100493] futex hash table entries: 256 (order: -1, 3072 bytes)
    [ 0.104133] pinctrl core: initialized pinctrl subsystem
    [ 0.104877] DMI not present or invalid.
    [ 0.105313] NET: Registered protocol family 16
    [ 0.107673] DMA: preallocated 256 KiB pool for atomic coherent allocations
    [ 0.111409] omap_hwmod: rtc: no dt node
    [ 0.111426] ------------[ cut here ]------------
    [ 0.111462] WARNING: CPU: 0 PID: 1 at arch/arm/mach-omap2/omap_hwmod.c:2409 _init.constprop.21+0x1a4/0x4c4
    [ 0.111472] omap_hwmod: rtc: doesn't have mpu register target base
    [ 0.111479] Modules linked in:
    [ 0.111499] CPU: 0 PID: 1 Comm: swapper Not tainted 4.19.59-g5f8c1c6121 #7
    [ 0.111506] Hardware name: Generic AM33XX (Flattened Device Tree)
    [ 0.111545] [<c010e3fc>] (unwind_backtrace) from [<c010b5cc>] (show_stack+0x10/0x14)
    [ 0.111571] [<c010b5cc>] (show_stack) from [<c0128468>] (__warn+0xd8/0xf0)
    [ 0.111587] [<c0128468>] (__warn) from [<c01280c8>] (warn_slowpath_fmt+0x48/0x6c)
    [ 0.111602] [<c01280c8>] (warn_slowpath_fmt) from [<c0c0ae38>] (_init.constprop.21+0x1a4/0x4c4)
    [ 0.111618] [<c0c0ae38>] (_init.constprop.21) from [<c0c0b264>] (__omap_hwmod_setup_all+0x40/0x12c)
    [ 0.111637] [<c0c0b264>] (__omap_hwmod_setup_all) from [<c0102674>] (do_one_initcall+0x7c/0x1a8)
    [ 0.111662] [<c0102674>] (do_one_initcall) from [<c0c00e28>] (kernel_init_freeable+0x12c/0x1c0)
    [ 0.111687] [<c0c00e28>] (kernel_init_freeable) from [<c082fe18>] (kernel_init+0x8/0x114)
    [ 0.111703] [<c082fe18>] (kernel_init) from [<c01010e8>] (ret_from_fork+0x14/0x2c)
    [ 0.111711] Exception stack(0xcb851fb0 to 0xcb851ff8)
    [ 0.111723] 1fa0: 00000000 00000000 00000000 00000000
    [ 0.111736] 1fc0: 00000000 00000000 00000000 00000000 00000000 00000000 00000000 00000000
    [ 0.111748] 1fe0: 00000000 00000000 00000000 00000000 00000013 00000000
    [ 0.111766] ---[ end trace 03a3a14182131630 ]---
    [ 0.126508] l4_wkup_cm:clk:0010:0: failed to disable
    [ 0.180594] cpuidle: using governor ladder
    [ 0.180631] cpuidle: using governor menu
    [ 0.185437] OMAP GPIO hardware version 0.1
    [ 0.193771] No ATAGs?
    [ 0.193787] hw-breakpoint: debug architecture 0x4 unsupported.
    [ 0.206794] edma 49000000.edma: TI EDMA DMA engine driver
    [ 0.209421] SCSI subsystem initialized
    [ 0.209909] media: Linux media interface: v0.10
    [ 0.209970] videodev: Linux video capture interface: v2.00
    [ 0.210068] pps_core: LinuxPPS API ver. 1 registered
    [ 0.210077] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <giometti@linux.it>
    [ 0.210101] PTP clock support registered
    [ 0.210135] EDAC MC: Ver: 3.0.0
    [ 0.211173] omap-mailbox 480c8000.mailbox: omap mailbox rev 0x400
    [ 0.211720] Advanced Linux Sound Architecture Driver Initialized.
    [ 0.212657] clocksource: Switched to clocksource timer1
    [ 0.220855] NET: Registered protocol family 2
    [ 0.221649] tcp_listen_portaddr_hash hash table entries: 512 (order: 0, 4096 bytes)
    [ 0.221681] TCP established hash table entries: 2048 (order: 1, 8192 bytes)
    [ 0.221709] TCP bind hash table entries: 2048 (order: 1, 8192 bytes)
    [ 0.221736] TCP: Hash tables configured (established 2048 bind 2048)
    [ 0.221839] UDP hash table entries: 256 (order: 0, 4096 bytes)
    [ 0.221861] UDP-Lite hash table entries: 256 (order: 0, 4096 bytes)
    [ 0.222004] NET: Registered protocol family 1
    [ 0.222587] RPC: Registered named UNIX socket transport module.
    [ 0.222601] RPC: Registered udp transport module.
    [ 0.222608] RPC: Registered tcp transport module.
    [ 0.222614] RPC: Registered tcp NFSv4.1 backchannel transport module.
    [ 2.552690] random: fast init done
    [ 7.531967] hw perfevents: enabled with armv7_cortex_a8 PMU driver, 5 counters available
    [ 7.533938] Initialise system trusted keyrings
    [ 7.534263] workingset: timestamp_bits=14 max_order=16 bucket_order=2
    [ 7.538684] squashfs: version 4.0 (2009/01/31) Phillip Lougher
    [ 7.539458] NFS: Registering the id_resolver key type
    [ 7.539504] Key type id_resolver registered
    [ 7.539513] Key type id_legacy registered
    [ 7.539556] ntfs: driver 2.1.32 [Flags: R/O].
    [ 7.541729] Key type asymmetric registered
    [ 7.541749] Asymmetric key parser 'x509' registered
    [ 7.541818] Block layer SCSI generic (bsg) driver version 0.4 loaded (major 245)
    [ 7.541830] io scheduler noop registered
    [ 7.541838] io scheduler deadline registered
    [ 7.542059] io scheduler cfq registered (default)
    [ 7.542071] io scheduler mq-deadline registered
    [ 7.542078] io scheduler kyber registered
    [ 7.543916] pinctrl-single 44e10800.pinmux: 142 pins, size 568
    [ 7.591526] Serial: 8250/16550 driver, 10 ports, IRQ sharing enabled
    [ 7.595394] 44e09000.serial: ttyS0 at MMIO 0x44e09000 (irq = 30, base_baud = 3000000) is a 8250
    [ 8.331253] console [ttyS0] enabled
    [ 8.335794] 48022000.serial: ttyS1 at MMIO 0x48022000 (irq = 31, base_baud = 3000000) is a 8250
    [ 8.346300] omap_rng 48310000.rng: Random Number Generator ver. 20
    [ 8.352987] random: crng init done
    [ 8.368821] brd: module loaded
    [ 8.378554] loop: module loaded
    [ 8.385078] m25p80 spi0.0: unrecognized JEDEC id bytes: ff, ff, ff
    [ 8.391813] libphy: Fixed MDIO Bus: probed
    [ 8.462738] davinci_mdio 4a101000.mdio: davinci mdio revision 1.6, bus freq 1000000
    [ 8.470136] davinci_mdio 4a101000.mdio: detected phy mask e000ff00
    [ 8.583934] libphy: 4a101000.mdio: probed
    [ 8.587835] davinci_mdio 4a101000.mdio: phy[0]: device 4a101000.mdio:00, driver unknown
    [ 8.595752] davinci_mdio 4a101000.mdio: phy[1]: device 4a101000.mdio:01, driver unknown
    [ 8.603531] davinci_mdio 4a101000.mdio: phy[2]: device 4a101000.mdio:02, driver unknown
    [ 8.611251] davinci_mdio 4a101000.mdio: phy[3]: device 4a101000.mdio:03, driver unknown
    [ 8.619005] davinci_mdio 4a101000.mdio: phy[4]: device 4a101000.mdio:04, driver unknown
    [ 8.626754] davinci_mdio 4a101000.mdio: phy[5]: device 4a101000.mdio:05, driver unknown
    [ 8.634487] davinci_mdio 4a101000.mdio: phy[6]: device 4a101000.mdio:06, driver unknown
    [ 8.642205] davinci_mdio 4a101000.mdio: phy[7]: device 4a101000.mdio:07, driver unknown
    [ 8.649936] davinci_mdio 4a101000.mdio: phy[16]: device 4a101000.mdio:10, driver unknown
    [ 8.657751] davinci_mdio 4a101000.mdio: phy[17]: device 4a101000.mdio:11, driver unknown
    [ 8.665570] davinci_mdio 4a101000.mdio: phy[18]: device 4a101000.mdio:12, driver unknown
    [ 8.673385] davinci_mdio 4a101000.mdio: phy[19]: device 4a101000.mdio:13, driver unknown
    [ 8.681187] davinci_mdio 4a101000.mdio: phy[20]: device 4a101000.mdio:14, driver unknown
    [ 8.689125] davinci_mdio 4a101000.mdio: phy[21]: device 4a101000.mdio:15, driver unknown
    [ 8.696948] davinci_mdio 4a101000.mdio: phy[22]: device 4a101000.mdio:16, driver unknown
    [ 8.704762] davinci_mdio 4a101000.mdio: phy[23]: device 4a101000.mdio:17, driver unknown
    [ 8.712566] davinci_mdio 4a101000.mdio: phy[24]: device 4a101000.mdio:18, driver unknown
    [ 8.720380] davinci_mdio 4a101000.mdio: phy[25]: device 4a101000.mdio:19, driver unknown
    [ 8.728195] davinci_mdio 4a101000.mdio: phy[26]: device 4a101000.mdio:1a, driver unknown
    [ 8.736007] davinci_mdio 4a101000.mdio: phy[27]: device 4a101000.mdio:1b, driver unknown
    [ 8.749794] cpsw 4a100000.ethernet: Missing dual_emac_res_vlan in DT.
    [ 8.756186] cpsw 4a100000.ethernet: Using 1 as Reserved VLAN for 0 slave
    [ 8.767523] cpsw 4a100000.ethernet: Missing dual_emac_res_vlan in DT.
    [ 8.774025] cpsw 4a100000.ethernet: Using 2 as Reserved VLAN for 1 slave
    [ 8.780495] cpsw 4a100000.ethernet: Detected MACID = e4:15:f6:fd:8f:18
    [ 8.787038] cpsw 4a100000.ethernet: initialized cpsw ale version 1.4
    [ 8.793227] cpsw 4a100000.ethernet: ALE Table size 1024
    [ 8.798301] cpsw 4a100000.ethernet: cpts: overflow check period 500 (jiffies)
    [ 8.806066] cpsw 4a100000.ethernet: cpsw: Detected MACID = e4:15:f6:fd:8f:1a
    [ 8.814232] i2c /dev entries driver
    [ 8.819704] cpufreq: cpufreq_online: CPU0: Running at unlisted freq: 833333 KHz
    [ 8.826889] cpu cpu0: dev_pm_opp_set_rate: failed to find current OPP for freq 833333333 (-34)
    [ 8.835309] cpufreq: cpufreq_online: CPU0: Unlisted initial frequency changed to: 800000 KHz
    [ 8.843659] cpuidle: enable-method property 'ti,am3352' found operations
    [ 8.850555] sdhci: Secure Digital Host Controller Interface driver
    [ 8.856569] sdhci: Copyright(c) Pierre Ossman
    [ 8.861183] sdhci-pltfm: SDHCI platform and OF driver helper
    [ 8.867296] ledtrig-cpu: registered to indicate activity on CPUs
    [ 8.877075] NET: Registered protocol family 10
    [ 8.882948] Segment Routing with IPv6
    [ 8.886578] sit: IPv6, IPv4 and MPLS over IPv4 tunneling driver
    [ 8.893132] NET: Registered protocol family 17
    [ 8.897530] Key type dns_resolver registered
    [ 8.901850] omap_voltage_late_init: Voltage driver support not added
    [ 8.908990] Loading compiled-in X.509 certificates
    [ 8.921857] omap-gpmc 50000000.gpmc: GPMC revision 6.0
    [ 8.928651] nand: second ID read did not match ff,ff against 19,19
    [ 8.934762] nand: No NAND device found
    [ 8.939886] omap_i2c 44e0b000.i2c: bus 0 rev0.11 at 100 kHz
    [ 8.946504] omap_i2c 4802a000.i2c: bus 1 rev0.11 at 100 kHz
    [ 8.952926] omap_i2c 4819c000.i2c: bus 2 rev0.11 at 100 kHz
    [ 8.958671] hctosys: unable to open rtc device (rtc0)
    [ 8.964210] ALSA device list:
    [ 8.967080] No soundcards found.
    [ 8.970440] Warning: unable to open an initial console.
    [ 8.975821] List of all partitions:
    [ 8.979203] 0100 65536 ram0
    [ 8.979208] (driver?)
    [ 8.985237] 0101 65536 ram1
    [ 8.985242] (driver?)
    [ 8.991128] 0102 65536 ram2
    [ 8.991131] (driver?)
    [ 8.997087] 0103 65536 ram3
    [ 8.997091] (driver?)
    [ 9.003038] 0104 65536 ram4
    [ 9.003042] (driver?)
    [ 9.008925] 0105 65536 ram5
    [ 9.008928] (driver?)
    [ 9.014850] 0106 65536 ram6
    [ 9.014854] (driver?)
    [ 9.020738] 0107 65536 ram7
    [ 9.020742] (driver?)
    [ 9.026643] 0108 65536 ram8
    [ 9.026646] (driver?)
    [ 9.032528] 0109 65536 ram9
    [ 9.032532] (driver?)
    [ 9.038448] 010a 65536 ram10
    [ 9.038452] (driver?)
    [ 9.044433] 010b 65536 ram11
    [ 9.044437] (driver?)
    [ 9.050405] 010c 65536 ram12
    [ 9.050408] (driver?)
    [ 9.056405] 010d 65536 ram13
    [ 9.056409] (driver?)
    [ 9.062377] 010e 65536 ram14
    [ 9.062380] (driver?)
    [ 9.068362] 010f 65536 ram15
    [ 9.068365] (driver?)
    [ 9.074365] No filesystem could mount root, tried:
    [ 9.074370]
    [ 9.080507] Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(0,0)
    [ 9.088486] ---[ end Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(0,0) ]---

  • Hi,

    ti_user said:
    [ 0.000000] Kernel command line: console=ttyO0,115200n8 imageType=working root=rw rootfstype=

    The uboot bootargs is not set properly, "root=" and "rootfstype=" are not complete.