Kernel stuck at starting kernel

cancel
Showing results for 
Search instead for 
Did you mean: 

Kernel stuck at starting kernel

483 Views
mohamed-ali_fod
Contributor I

Hello,

The 4.19 kernel doesn't boot on imx6, there is a hang at Starting kernel as mentioned below in case of initramfs, I attached the u-boot 2019.04 environment and kernel config, we use "setenv bootargs console=${console},${baudrate} root=/dev/ram0 rootfstype=ramfs", any idea please?

SF: Detected w25q256 with page size 256 Bytes, erase size 4 KiB, total 32 MiB
device 0 offset 0x760000, size 0x20000
SF: 131072 bytes @ 0x760000 Read: OK
device 0 offset 0x780000, size 0x500000
SF: 5242880 bytes @ 0x780000 Read: OK
device 0 offset 0xc80000, size 0x1380000
SF: 20447232 bytes @ 0xc80000 Read: OK
## Booting kernel from Legacy Image at 12000000 ...
Image Name: Linux-4.19.35-imx-4.19.35-1.1.0
Image Type: ARM Linux Kernel Image (uncompressed)
Data Size: 3707096 Bytes = 3.5 MiB
Load Address: 10008000
Entry Point: 10008000
Verifying Checksum ... OK
## Loading init Ramdisk from Legacy Image at 19000000 ...
Image Name: tgur-access-image-update-tgur-ac
Image Type: ARM Linux RAMDisk Image (uncompressed)
Data Size: 5418159 Bytes = 5.2 MiB
Load Address: 00000000
Entry Point: 00000000
Verifying Checksum ... OK
## Flattened Device Tree blob at 18000000
Booting using the fdt blob at 0x18000000
Loading Kernel Image ... OK
Using Device Tree in place at 18000000, end 18013cc4

Starting kernel ...

0 Kudos
8 Replies

454 Views
jimmychan
NXP TechSupport
NXP TechSupport

Are you using the Yocto BSP to build the image?

 

0 Kudos

450 Views
mohamed-ali_fod
Contributor I

Yes I am using Yocto warrior.

0 Kudos

442 Views
jimmychan
NXP TechSupport
NXP TechSupport

Which processor are you using? Are you building the proper image for the processor?

Which board are you using? The original SDRAM settings is for the EVK board. If your board is using different SDRAM, the SDRAM setting is needed to modify.

In the u-boot, the debug console is set in the bootargs. e.g. ttymxc0. If you are using different UART for debug console, please change the bootargs in u-boot accordingly.

 

0 Kudos

435 Views
mohamed-ali_fod
Contributor I

I am using a specific board designed around IMX6. The SDRAM settings are ok as we are using the same setting as for u-boot 2014 that works already with kernel 3.10. Please note that kernel 4.19 can boot with u-boot 2014 and kernel 3.10 boot also with u-boot 2019 but kernel 4.19 cannot boot with u-boot 2019.

0 Kudos

430 Views
jimmychan
NXP TechSupport
NXP TechSupport

The old u-boot is using <board>.c file for the configuration. The new version of u-boot is using device tree. Do you modify the device tree file in the new version of u-boot accordingly?

 

0 Kudos

404 Views
mohamed-ali_fod
Contributor I

Yes I modified the device tree the u-boot is working fine it detects usb, network, spi flash and so on....

Tags (1)
0 Kudos

401 Views
jimmychan
NXP TechSupport
NXP TechSupport

There are newer version of BSP that support i.MX6 processors.

https://www.nxp.com/design/software/embedded-software/i-mx-software/embedded-linux-for-i-mx-applicat...

 

You may try the new version of BSP.

0 Kudos

469 Views
mohamed-ali_fod
Contributor I

Kernel 3.10 is working fine with the same u-boot 2019.04

------START UPDATE DISTRIBUTION ------
SF: Detected w25q256 with page size 256 Bytes, erase size 4 KiB, total 32 MiB
device 0 offset 0x760000, size 0x20000
SF: 131072 bytes @ 0x760000 Read: OK
device 0 offset 0x780000, size 0x500000
SF: 5242880 bytes @ 0x780000 Read: OK
device 0 offset 0xc80000, size 0x1380000
SF: 20447232 bytes @ 0xc80000 Read: OK
## Booting kernel from Legacy Image at 12000000 ...
Image Name: Linux-3.10.17-rt12+pamela-dual-l
Image Type: ARM Linux Kernel Image (uncompressed)
Data Size: 3355992 Bytes = 3.2 MiB
Load Address: 10008000
Entry Point: 10008000
Verifying Checksum ... OK
## Loading init Ramdisk from Legacy Image at 19000000 ...
Image Name: tgur-access-image-update-tgur-ac
Image Type: ARM Linux RAMDisk Image (uncompressed)
Data Size: 5418159 Bytes = 5.2 MiB
Load Address: 00000000
Entry Point: 00000000
Verifying Checksum ... OK
## Flattened Device Tree blob at 18000000
Booting using the fdt blob at 0x18000000
Loading Kernel Image ... OK
Using Device Tree in place at 18000000, end 1800dbfa

Starting kernel ...

Booting Linux on physical CPU 0x0
Initializing cgroup subsys cpuset
Initializing cgroup subsys cpu
Initializing cgroup subsys cpuacct
Linux version 3.10.17-rt12+pamela-dual-lite-04.09.15+gc88bcca (actia-es@bbc65510a8cd) (gcc version 4.8.4 (GCC) ) #1 PREEMPT RT Sun Apr 25 13:54:14 UTC 2021
CPU: ARMv7 Processor [412fc09a] revision 10 (ARMv7), cr=10c5387d
CPU: PIPT / VIPT nonaliasing data cache, VIPT aliasing instruction cache
Machine: Freescale i.MX6 Quad/DualLite (Device Tree), model: Pamela TGUR Access i.MX6 Solo Board
cma: CMA: reserved 32 MiB at 4e000000
Memory policy: ECC disabled, Data cache writeback
------------[ cut here ]------------
WARNING: at arch/arm/kernel/devtree.c:147 arm_dt_init_cpu_maps+0x11c/0x1a4()
DT /cpu 2 nodes greater than max cores 1, capping them
Modules linked in:
CPU: 0 PID: 0 Comm: swapper Not tainted 3.10.17-rt12+pamela-dual-lite-04.09.15+gc88bcca #1
[<8001378c>] (unwind_backtrace+0x0/0x134) from [<80011d0c>] (show_stack+0x10/0x14)
[<80011d0c>] (show_stack+0x10/0x14) from [<800268c0>] (warn_slowpath_common+0x54/0x68)
[<800268c0>] (warn_slowpath_common+0x54/0x68) from [<80026904>] (warn_slowpath_fmt+0x30/0x40)
[<80026904>] (warn_slowpath_fmt+0x30/0x40) from [<805ea47c>] (arm_dt_init_cpu_maps+0x11c/0x1a4)
[<805ea47c>] (arm_dt_init_cpu_maps+0x11c/0x1a4) from [<805e9e44>] (setup_arch+0x644/0x69c)
[<805e9e44>] (setup_arch+0x644/0x69c) from [<805e6798>] (start_kernel+0x7c/0x334)
[<805e6798>] (start_kernel+0x7c/0x334) from [<10008070>] (0x10008070)
---[ end trace 0000000000000001 ]---
CPU: All CPU(s) started in SVC mode.
Built 1 zonelists in Zone order, mobility grouping on. Total pages: 260096
Kernel command line: console=ttymxc0,115200 root=/dev/ram0 rootfstype=ramfs
PID hash table entries: 4096 (order: 2, 16384 bytes)
Dentry cache hash table entries: 131072 (order: 7, 524288 bytes)
Inode-cache hash table entries: 65536 (order: 6, 262144 bytes)
Memory: 1024MB = 1024MB total
Memory: 994348k/994348k available, 54228k reserved, 0K highmem
Virtual kernel memory layout:
vector : 0xffff0000 - 0xffff1000 ( 4 kB)
fixmap : 0xfff00000 - 0xfffe0000 ( 896 kB)
vmalloc : 0xc0800000 - 0xff000000 (1000 MB)
lowmem : 0x80000000 - 0xc0000000 (1024 MB)
modules : 0x7f000000 - 0x80000000 ( 16 MB)
.text : 0x80008000 - 0x805e56a4 (6006 kB)
.init : 0x805e6000 - 0x8061641c ( 194 kB)
.data : 0x80618000 - 0x8065e008 ( 281 kB)
.bss : 0x8065e008 - 0x806c3260 ( 405 kB)
SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=1, Nodes=1
NR_IRQS:16 nr_irqs:16 16

0 Kudos