hailo-ai / meta-hailo-soc

2 stars 1 forks source link

Kernel Panic with EVB #6

Closed moqmar closed 10 months ago

moqmar commented 11 months ago

With the hailo15-evb-security-camera-machine.yml kas project file, I built an image, flashed the .wic onto an SD card (with GNOME Disks) and put it into a Hailo 15 EVB. On boot, I get the following UART output that unfortunately ends with a kernel panic, after which obviously nothing happens anymore.

I have tried this with the kirkstone and v1.1.2 branches, and also tried it with branch kirkstone-v3.26.2of meta-hailo. Did I do anything wrong maybe (picked the wrong image, .wic file, etc.)? The board itself works fine with the image that's already on the SD card that came with the Camera Development Kit.

UART output ``` U-Boot 2022.01 (Jun 05 2023 - 13:40:31 +0000) DRAM: 4 GiB hailo15 pinctrl registered MMC: sdio0@78000000: 0, sdio1@78001000: 1 Loading Environment from SPIFlash... SF: Detected n25q00a with page size 256 Bytes, erase size 4 KiB, total 128 MiB OK In: uart@00109000 Out: uart@00109000 Err: uart@00109000 Net: Warning: ethernet@1b5000 (eth0) using random MAC address - 0e:3b:44:5a:f6:9e eth0: ethernet@1b5000 *** U-Boot Boot Menu *** Autodetect Boot from SD Card Boot from eMMC Update SD (wic) from TFTP Update eMMC (wic) from TFTP Update SD (partitions) from TFTP Update eMMC (partitions) from TFTP Boot from NFS U-Boot console Press UP/DOWN to move, ENTER to select, ESC/CTRL+C to quit Trying Boot from SD switch to partitions #0, OK mmc0 is current device Device: sdio0@78000000 Manufacturer ID: 3 OEM: 5344 Name: SN32G Bus Speed: 50000000 Mode: SD High Speed (50MHz) Rd Block Len: 512 SD version 3.0 High Capacity: Yes Capacity: 29.7 GiB Bus Width: 1-bit Erase Group Size: 512 Bytes 6945026 bytes read in 1158 ms (5.7 MiB/s) ## Loading kernel from FIT Image at 85000000 ... Using 'conf-hailo_hailo15-evb-security-camera.dtb' configuration Trying 'kernel-1' kernel subimage Description: Linux kernel Type: Kernel Image Compression: gzip compressed Data Start: 0x85000110 Data Size: 6918352 Bytes = 6.6 MiB Architecture: AArch64 OS: Linux Load Address: 0x80200000 Entry Point: 0x80200000 Hash algo: sha256 Hash value: 0cd3a13cc642bc377e9a5aaee497810c12d08e8265ab3083608b4d6e2e58a2d0 Verifying Hash Integrity ... sha256+ OK ## Loading fdt from FIT Image at 85000000 ... Using 'conf-hailo_hailo15-evb-security-camera.dtb' configuration Trying 'fdt-hailo_hailo15-evb-security-camera.dtb' fdt subimage Description: Flattened Device Tree blob Type: Flat Device Tree Compression: uncompressed Data Start: 0x85699308 Data Size: 22326 Bytes = 21.8 KiB Architecture: AArch64 Hash algo: sha256 Hash value: 3e8ae6fd605e89ab1b2b54773633a95f3bc7864aa98f2db8a58ea93a036c421b Verifying Hash Integrity ... sha256+ OK Booting using the fdt blob at 0x85699308 Uncompressing Kernel Image Loading Device Tree to 000000017f74d000, end 000000017f755735 ... OK Starting kernel ... [ 0.000000] Booting Linux on physical CPU 0x0000000000 [0x410fd034] [ 0.000000] Linux version 5.15.32-yocto-standard (oe-user@oe-host) (aarch64-poky-linux-gcc (GCC) 11.4.0, GNU ld (GNU Binutils) 2.38.20220708) #1 SMP PREEMPT Wed Nov 29 17:45:55 UTC 2023 [ 0.000000] Machine model: Hailo - Hailo15 [ 0.000000] earlycon: uart0 at MMIO 0x0000000000109000 (options '') [ 0.000000] printk: bootconsole [uart0] enabled [ 0.000000] Reserved memory: created CMA memory pool at 0x0000000082000000, size 992 MiB [ 0.000000] OF: reserved mem: initialized node linux,cma, compatible id shared-dma-pool [ 0.000000] software IO TLB: Reserved memory: created restricted DMA pool at 0x00000000ebf00000, size 64 MiB [ 0.000000] OF: reserved mem: initialized node buffer@0, compatible id restricted-dma-pool [ 0.000000] Zone ranges: [ 0.000000] DMA [mem 0x0000000080000000-0x00000000ffffffff] [ 0.000000] DMA32 empty [ 0.000000] Normal [mem 0x0000000100000000-0x000000017fffffff] [ 0.000000] Movable zone start for each node [ 0.000000] Early memory node ranges [ 0.000000] node 0: [mem 0x0000000080000000-0x00000000f7ffffff] [ 0.000000] node 0: [mem 0x00000000f8000000-0x00000000ffffffff] [ 0.000000] node 0: [mem 0x0000000100000000-0x000000017fffffff] [ 0.000000] Initmem setup node 0 [mem 0x0000000080000000-0x000000017fffffff] [ 0.000000] psci: probing for conduit method from DT. [ 0.000000] ------------[ cut here ]------------ [ 0.000000] kernel BUG at arch/arm64/kernel/traps.c:498! [ 0.000000] Internal error: Oops - BUG: 0 [#1] PREEMPT SMP [ 0.000000] Modules linked in: [ 0.000000] CPU: 0 PID: 0 Comm: swapper Not tainted 5.15.32-yocto-standard #1 [ 0.000000] Hardware name: Hailo - Hailo15 (DT) [ 0.000000] pstate: 000000c5 (nzcv daIF -PAN -UAO -TCO -DIT -SSBS BTYPE=--) [ 0.000000] pc : do_undefinstr+0x2c4/0x2e0 [ 0.000000] lr : do_undefinstr+0x2d0/0x2e0 [ 0.000000] sp : ffff800008ea3aa0 [ 0.000000] x29: ffff800008ea3ac0 x28: ffff800008eb22c0 x27: 0000000081000200 [ 0.000000] x26: ffff800008be6808 x25: ffff800008c08860 x24: 00000000000000c0 [ 0.000000] x23: 00000000600000c5 x22: ffff80000802538c x21: ffff800008ea3c70 [ 0.000000] x20: 00000000d4000003 x19: ffff800008ea3b20 x18: ffffffffffffffff [ 0.000000] x17: 000000000000002c x16: 000000017ffd4df8 x15: ffff800088ea3977 [ 0.000000] x14: ffffffffffffffff x13: 0000000000000018 x12: 0101010101010101 [ 0.000000] x11: 0000000000000018 x10: 0101010101010101 x9 : ffffffffffffffff [ 0.000000] x8 : 7f7f7f7f7f7f7f7f x7 : 0000000000000000 x6 : 0000000000000000 [ 0.000000] x5 : ffff800008eb4610 x4 : 0000000000000000 x3 : ffff800008f97110 [ 0.000000] x2 : 0000000000000000 x1 : ffff800008eb22c0 x0 : 00000000600000c5 [ 0.000000] Call trace: [ 0.000000] do_undefinstr+0x2c4/0x2e0 [ 0.000000] el1_undef+0x2c/0x4c [ 0.000000] el1h_64_sync_handler+0x88/0xd4 [ 0.000000] el1h_64_sync+0x78/0x7c [ 0.000000] __arm_smccc_smc+0x10/0x40 [ 0.000000] __invoke_psci_fn_smc+0x38/0x70 [ 0.000000] psci_0_2_get_version+0x2c/0x3c [ 0.000000] psci_0_2_init+0x34/0x284 [ 0.000000] psci_1_0_init+0x18/0x54 [ 0.000000] psci_dt_init+0x64/0xa4 [ 0.000000] setup_arch+0x428/0x5ac [ 0.000000] start_kernel+0x88/0x65c [ 0.000000] __primary_switched+0xc0/0xc8 [ 0.000000] Code: 17ffff8d a9445bf5 17ffffb1 a9045bf5 (d4210000) [ 0.000000] random: get_random_bytes called from oops_exit+0x3c/0xd0 with crng_init=0 [ 0.000000] ---[ end trace 0000000000000000 ]--- [ 0.000000] Kernel panic - not syncing: Attempted to kill the idle task! [ 0.000000] ---[ end Kernel panic - not syncing: Attempted to kill the idle task! ]--- ```
moqmar commented 10 months ago

Was solved with the help of Hailo's support team: I had to update the firmware according to the getting started guide, which in turn didn't work due to a Serial Timeout error, which was fixed by using a different USB cable (even though accessing the UART console worked with the other cable).

Thanks for the help! :)