We are trying to get a firmware example to work on a Verdin with an IMX8M Plus and the Torizon Core image with containers. I am using the firmware “rpmsg_lite_str_echo_rtos_imxcm7.bin” that was built by someone else on our team. In a normal command shell I can do “dmesg | grep rpmsg” and can see that the rpmsg driver is registered. To load the firmware I am following the example here: How to load compiled binaries into Cortex-M | Toradex Developer Center
The image shows up in ext4ls mmc 2:1 and the environment commands in UBoot seem to take. I specified 32000 for m4image_size due to the larger binary and the address 0x7e0000 as in the example. However when I try to restart I get a kernel panic shown below.
Are there different values I should use? And how does Linux know to skip the memory block for the firmware code? On a related question (once we figure this out) we need to figure out how to reserve a 1M block of memory for the M4, is there and example on how to do that?
Thank you, Lloyd Shelby
Verdin iMX8MP # ext4ls mmc 2:1 ostree/deploy/torizon/var/
4096 . 4096 .. 4096 rootdirs 4096 lib 4096 tmp 11 lock 6 run 0 .ostree-selabeled 17 log 4096 sota 4096 volatile 4096 usrlocal 4096 cache 4096 spool 190 .updated 28780 rpmsg_lite_str_echo_rtos_imxcm7.bin…
973 bytes read in 1 ms (950.2 KiB/s)
Executing script at 50280000
4850 bytes read in 2 ms (2.3 MiB/s)
90156 bytes read in 2 ms (43 MiB/s)
147 bytes read in 1 ms (143.6 KiB/s)
Applying Overlay: verdin-imx8mp_hdmi_overlay.dtbo
2219 bytes read in 2 ms (1.1 MiB/s)
Applying Overlay: verdin-imx8mp_dsi-to-hdmi_overlay.dtbo
3165 bytes read in 2 ms (1.5 MiB/s)
Applying Overlay: verdin-imx8mp_spidev_overlay.dtbo
561 bytes read in 1 ms (547.9 KiB/s)
Applying Overlay: apalis-imx8_hmp_overlay.dtbo
Failed to load ‘/boot/boot/ostree/torizon-a7ab41e968c27662d7fc71a4adf501104af8a6b2ea99063c1d15ad3ea49ed099/dtb/overlays/apalis-imx8_hmp_overlay.dtbo’
13355717 bytes read in 43 ms (296.2 MiB/s)
11523429 bytes read in 37 ms (297 MiB/s)
Uncompressing Kernel Image
Flattened Device Tree blob at 50200000
Booting using the fdt blob at 0x50200000
Loading Device Tree to 00000000ffac7000, end 00000000ffb00fff … OK
Starting kernel …
[ 0.881772] Internal error: synchronous external abort: 96000210 [#1] PREEMPT SMP
[ 0.889270] Modules linked in:
[ 0.892333] CPU: 0 PID: 1 Comm: swapper/0 Not tainted 5.15.77-6.2.0+git.aa0ff7e3554e #1-TorizonCore
[ 0.901386] Hardware name: Toradex Verdin iMX8M Plus WB on Verdin Development Board (DT)
[ 0.909483] pstate: 60000005 (nZCv daif -PAN -UAO -TCO -DIT -SSBS BTYPE=–)
[ 0.916453] pc : imx_uart_probe+0x31c/0x7d0
[ 0.920650] lr : imx_uart_probe+0x30c/0x7d0
[ 0.924843] sp : ffff80000a28bb60
[ 0.928158] x29: ffff80000a28bb60 x28: 0000000000000000 x27: ffff800009a204c0
[ 0.935307] x26: ffff0000c4d3e880 x25: 00000000fffffffa x24: 00000000fffffffa
[ 0.942458] x23: ffff0000c015b410 x22: 000000000000002c x21: ffff0000c015b400
[ 0.949608] x20: 0000000000000000 x19: ffff0000c0943080 x18: ffffffffffffffff
[ 0.956757] x17: 647561625f657361 x16: 62202c3633203d20 x15: ffff0000c4d3e40a
[ 0.963905] x14: ffffffffffffffff x13: 0000000000000038 x12: 0101010101010101
[ 0.971054] x11: 0000000000000000 x10: 0101010101010101 x9 : 0000000000000004
[ 0.978203] x8 : 0101010101010101 x7 : 7f7f7f7f7f7f7f7f x6 : fffefefefeff6f6c
[ 0.985352] x5 : 8080808080800000 x4 : 0000000000000010 x3 : 0000000000000000
[ 0.992500] x2 : 0000000000000000 x1 : ffff80000aad0080 x0 : 0000000000000000
[ 0.999651] Call trace:
[ 1.002099] imx_uart_probe+0x31c/0x7d0
[ 1.005941] platform_probe+0x68/0xe0
[ 1.009610] really_probe+0xbc/0x46c
[ 1.013194] __driver_probe_device+0x114/0x190
[ 1.017650] driver_probe_device+0x40/0x100
[ 1.021839] __driver_attach+0xac/0x210
[ 1.025683] bus_for_each_dev+0x70/0xd0
[ 1.029531] driver_attach+0x24/0x30
[ 1.033116] bus_add_driver+0x14c/0x250
[ 1.036960] driver_register+0x78/0x130
[ 1.040809] __platform_driver_register+0x28/0x34
[ 1.045521] imx_uart_init+0x3c/0x64
[ 1.049106] do_one_initcall+0x44/0x290
[ 1.052950] kernel_init_freeable+0x228/0x2b0
[ 1.057316] kernel_init+0x24/0x12c
[ 1.060814] ret_from_fork+0x10/0x20
[ 1.064401] Code: 2a0003f4 35001820 f9400a61 91020021 (b9400021)
[ 1.070520] —[ end trace cbbfde314540c4bf ]—
[ 1.075143] Kernel panic - not syncing: synchronous external abort: Fatal exception
[ 1.082804] SMP: stopping secondary CPUs
[ 1.086742] Kernel Offset: disabled
[ 1.090233] CPU features: 0x00002001,20000846
[ 1.094595] Memory Limit: none
[ 1.097652] Rebooting in 5 seconds…