iMX8QM HDMI plus Touch screen overlays

Hi,

We are trying to use both displays with imx8qm and ixora.

Tested with unmodified image from a link from toradex developer page image used: b2qt 6.4.3
from
Qt for Device Creation (Boot to Qt) | Toradex Developer Center

https://docs.toradex.com/106697-b2qt-embedded-qt5-image-apalis-imx8-tezi.tar?v=14

default settings for the display is HDMI and settings are following:
overlays.txt file:

fdt_overlays=apalis-imx8_hdmi_overlay.dtbo apalis-imx8_spi1_spidev_overlay.dtbo apalis-imx8_spi2_spidev_overlay.dtbo

kms.conf file:

{
  "hwcursor": false,
  "device": "/dev/dri/card1"
}

with these default settings HDMI works.

Then, we want to change it to use a touch screen :
overlays.txt file:

fdt_overlays=fdt_overlays=apalis-imx8_panel-lvds-dual-channel-1080p_overlay.dtbo

kms.conf file:

{
  "hwcursor": false,
  "device": "/dev/dri/card1",
  "outputs":
  [
   { "name":"LVDS-1", "mode":"1280x800", "virtualIndex":0 }
  ]
}

with these settings touch screen works.

But we want to use both screens.
When we change the settings on both files, kernel crashes on startup with different error on each time.

overlays.txt file:

fdt_overlays=fdt_overlays=apalis-imx8_panel-lvds-dual-channel-1080p_overlay.dtbo apalis-imx8_hdmi_overlay.dtbo apalis-imx8_spi1_spidev_overlay.dtbo apalis-imx8_spi2_spidev_overlay.dtbo

kms.conf file:

{
  "hwcursor": false,
  "device": "/dev/dri/card1"
  "outputs":
  [
   { "name":"LVDS-1", "mode":"1280x800", "virtualIndex":0 },
   { "name":"HDMI-A-1", "mode":"1920x1080" }
  ]
}

Following is the early step of the startup, added as a information:

U-Boot 2022.04-0+git.1c83b1aaad86 (Jan 05 2023 - 08:25:45 +0000)

CPU:   NXP i.MX8QM RevB A53 at 1200 MHz at 39C

DRAM:  4 GiB
Core:  186 devices, 15 uclasses, devicetree: separate
MMC:   FSL_SDHC: 0, FSL_SDHC: 1, FSL_SDHC: 2
Loading Environment from MMC... OK
In:    serial@5a070000
Out:   serial@5a070000
Err:   serial@5a070000
Model: Toradex 0037 Apalis iMX8QM 4GB WB IT V1.1E
Serial#: 14715897

 BuildInfo:
  - SCFW f5623878, SECO-FW c9de51c0, IMX-MKIMAGE 3bfcfccb, ATF 3c1583b
  - U-Boot 2022.04-0+git.1c83b1aaad86

Net:   eth0: ethernet@5b040000
Normal Boot
Hit any key to stop autoboot:  0
MMC: no card present
MMC: no card present
switch to partitions #0, OK
mmc0(part 0) is current device
Scanning mmc 0:1...
Found U-Boot script /boot.scr
5964 bytes read in 2 ms (2.8 MiB/s)
 Executing script at 9d480000
Loading DeviceTree: imx8qm-apalis-v1.1-eval.dtb
170359 bytes read in 7 ms (23.2 MiB/s)
98 bytes read in 2 ms (47.9 KiB/s)
Applying Overlay: apalis-imx8_panel-lvds-dual-channel-1080p_overlay.dtbo
1428 bytes read in 3 ms (464.8 KiB/s)
Applying Overlay: apalis-imx8_hdmi_overlay.dtbo
2205 bytes read in 3 ms (717.8 KiB/s)
11588488 bytes read in 261 ms (42.3 MiB/s)
Bootargs: pci=nomsi root=PARTUUID=c822a191-02 ro rootwait console=tty1 console=ttyLP1,115200 consoleblank=0 earlycon
   Uncompressing Kernel Image
Flattened Device Tree blob at 9d400000
   Booting using the fdt blob at 0x9d400000
   Loading Device Tree to 00000000fd64f000, end 00000000fd69bfff ... OK
Disable pwm@5a190000 rsrc 188 not owned
Disable clock-controller@5a590000 rsrc 188 not owned

Starting kernel ...

Following is the errors happening after it:
error 1:

       Starting Wait for udev To …plete Device Initialization...
[    6.538844] caam 31400000.crypto: device ID = 0x0a16040000000100 (Era 9)
[  OK  ] Created slice Slice /system/systemd-[    6.547304] caam 31400000.crypto: job rings = 2, qi = 0
backlight.
[    6.567131] systemd-journald[305]: Oldest entry in /run/log/journal/2d7ccc10af54451ba75ca6b7b726924a/system.journal is older than the configured file retention duration (1month), suggesting rotation.
[    6.571964] amphion-vpu-core 2d090000.vpu-core: encoder firmware version : 1.3.3
[    6.589902] systemd-journald[305]: /run/log/journal/2d7ccc10af54451ba75ca6b7b726924a/system.journal: Journal header limits reached or header out-of-date, rotating.
         Starting Load/Save Screen …ness of backlight:backlight...
[    6.621867] random: crng init done
[  OK  ] Started Network Time Synchronization[    6.627460] amphion-vpu-core 2d080000.vpu-core: decoder firmware version : 1.8.5
.
[  OK  ] Finished Load/Save Random Seed.
[  OK  ] Finished Load/Save Screen …htness of backlight:backlight.
[    6.688104] imx-drm display-subsystem: bound imx-drm-dpu-bliteng.2 (ops dpu_bliteng_ops)
[    6.701552] imx-drm display-subsystem: bound imx-drm-dpu-bliteng.5 (ops dpu_bliteng_ops)
[    6.711311] imx8_media_dev: module is from the staging directory, the quality is unknown, you have been warned.
[    6.711459] imx-drm display-subsystem: bound imx-dpu-crtc.0 (ops dpu_crtc_ops)
[    6.729539] imx-drm display-subsystem: bound imx-dpu-crtc.1 (ops dpu_crtc_ops)
[  OK  ] Reached target System Time Set.[    6.739117] imx-drm display-subsystem: bound imx-dpu-crtc.3 (ops dpu_crtc_ops)

[    6.752443] imx-drm display-subsystem: bound imx-dpu-crtc.4 (ops dpu_crtc_ops)
[    6.783243] mxc-jpeg 58400000.jpegdec: decoder device registered as /dev/video2 (81,2)
[    6.797635] mxc-jpeg 58450000.jpegenc: encoder device registered as /dev/video3 (81,3)
[    6.806601] CAN device driver interface
[  OK  ] Reached target Hardware activated USB[    6.846467] [drm] Started firmware!
 gadget.
[    6.866978] [drm] HDP FW Version - ver 34559 verlib 20560
[    6.883509] cdns-mhdp-imx 56268000.hdmi: lane-mapping 0x93
[    6.890487] [drm] HDCP is disabled
[    6.896350] imx-drm display-subsystem: bound 56268000.hdmi (ops cdns_mhdp_imx_ops [cdns_mhdp_imx])
[    6.908529] input: PenMount PM1410 as /devices/platform/bus@5b000000/5b0e0000.usb/ci_hdrc.1/usb3/3-1/3-1.3/3-1.3:1.0/0003:14E1:3508.0001/input/input2
[    6.932153] hdmi_pxl_clk: failed to set clock parent -16
[    6.937704] clk: failed to reparent hdmi_pxl_clk to hdmi_av_pll_clk: -16
[    6.938567] hid-multitouch 0003:14E1:3508.0001: input: USB HID v1.11 Device [PenMount PM1410] on usb-ci_hdrc.1-1.3/input0
[    6.955629] hdmi_pixel_mux_clk: failed to set clock parent -16
[    6.961724] clk: failed to reparent hdmi_pixel_mux_clk to hdmi_av_pll_clk: -16
[    6.970857] hdmi_pixel_link_clk: failed to set clock parent -16
[    6.979555] clk: failed to reparent hdmi_pixel_link_clk to hdmi_av_pll_clk: -16
[    6.996222] cfg80211: Loading compiled-in X.509 certificates for regulatory database
[    7.006647] imx-drm display-subsystem: bound imx-drm-dpu-bliteng.2 (ops dpu_bliteng_ops)
[    7.015006] imx-drm display-subsystem: bound imx-drm-dpu-bliteng.5 (ops dpu_bliteng_ops)
[    7.028421] imx-hdmi sound-hdmi: snd_soc_register_card failed (-517)
[    7.030933] imx-drm display-subsystem: bound imx-dpu-crtc.0 (ops dpu_crtc_ops)
[    7.046390] imx-drm display-subsystem: bound imx-dpu-crtc.1 (ops dpu_crtc_ops)
[    7.050831] cfg80211: Loaded X.509 cert 'sforshee: 00b28ddf47aef9cea7'
[    7.055581] imx-drm display-subsystem: bound imx-dpu-crtc.3 (ops dpu_crtc_ops)
[    7.074063] imx-drm display-subsystem: bound imx-dpu-crtc.4 (ops dpu_crtc_ops)
[    7.093894] SError Interrupt on CPU2, code 0xbf000002 -- SError
[    7.093921] CPU: 2 PID: 194 Comm: kworker/u12:3 Tainted: G         C O      5.15.77-0+git.349786b46e61 #1
[    7.093931] Hardware name: Toradex Apalis iMX8QM V1.1 on Apalis Evaluation Board (DT)
[    7.093938] Workqueue: events_unbound deferred_probe_work_func
[    7.093964] pstate: 60000005 (nZCv daif -PAN -UAO -TCO -DIT -SSBS BTYPE=--)
[    7.093973] pc : mutex_lock_io+0xd0/0x2ec
[    7.093984] lr : cdns_mhdp_bus_write+0xa4/0x100 [cdns_mhdp_drmcore]
[    7.094026] sp : ffff80000b0bb910
[    7.094029] x29: ffff80000b0bb910 x28: ffff000800765350 x27: ffff000804f83700
[    7.094039] x26: 0000000000000000 x25: ffff80000109b1b8 x24: ffff00080578e120
[    7.094048] x23: ffff00080578c080 x22: 0000000022222211 x21: ffff00080578cd88
[    7.094057] x20: 0000000000000004 x19: ffff00080578c080 x18: 0000000000000000
[    7.094066] x17: ffff80087600e000 x16: ffff800009c0c000 x15: 00007f57a150dbb6
[    7.094074] x14: 00000000000003b0 x13: 0000000000000001 x12: 0000000000000001
[    7.094083] x11: 0000000000000000 x10: 00000000000009c0 x9 : ffff80000b0bb810
[    7.094092] x8 : ffff0008017e7a20 x7 : ffff00087f75a400 x6 : 0000000000000000
[    7.094101] x5 : 0000000000220000 x4 : 0000000000000000 x3 : ffff00080578cd88
[    7.094110] x2 : 0000000000000000 x1 : ffff0008017e7000 x0 : ffff0008017e7000
[    7.094122] Kernel panic - not syncing: Asynchronous SError Interrupt
[    7.094127] CPU: 2 PID: 194 Comm: kworker/u12:3 Tainted: G         C O      5.15.77-0+git.349786b46e61 #1
[    7.094134] Hardware name: Toradex Apalis iMX8QM V1.1 on Apalis Evaluation Board (DT)
[    7.094137] Workqueue: events_unbound deferred_probe_work_func
[    7.094149] Call trace:
[    7.094150]  dump_backtrace+0x0/0x1cc
[    7.094164]  show_stack+0x18/0x70
[    7.094172]  dump_stack_lvl+0x68/0x84
[    7.094180]  dump_stack+0x18/0x34
[    7.094185]  panic+0x15c/0x31c
[    7.094194]  nmi_panic+0x8c/0x90
[    7.094205]  arm64_serror_panic+0x6c/0x7c
[    7.094210]  do_serror+0x58/0x5c
[    7.094215]  el1h_64_error_handler+0x30/0x50
[    7.094224]  el1h_64_error+0x78/0x7c
[    7.094231]  mutex_lock_io+0xd0/0x2ec
[    7.094237]  cdns_mhdp_firmware_write_section+0x74/0xa0 [cdns_mhdp_imx]
[    7.094252]  cdns_mhdp_firmware_init_imx8qm+0xac/0x1c0 [cdns_mhdp_imx]
[    7.094263]  __cdns_hdmi_probe+0x174/0x37c [cdns_mhdp_drmcore]
[    7.094291]  cdns_hdmi_bind+0x28/0x90 [cdns_mhdp_drmcore]
[    7.094317]  cdns_mhdp_imx_bind+0xe0/0x160 [cdns_mhdp_imx]
[    7.094328]  component_bind_all+0x124/0x284
[    7.094341]  imx_drm_bind+0x15c/0x20c
[    7.094348]  try_to_bring_up_master+0x228/0x314
[    7.094356]  __component_add+0xa0/0x18c
[    7.094364]  component_add+0x14/0x20
[    7.094371]  cdns_mhdp_imx_probe+0x1c/0x30 [cdns_mhdp_imx]
[    7.094382]  platform_probe+0x68/0xe0
[    7.094388]  really_probe+0xbc/0x46c
[    7.094395]  __driver_probe_device+0x114/0x190
[    7.094402]  driver_probe_device+0x40/0x100
[    7.094410]  __device_attach_driver+0xbc/0x160
[    7.094417]  bus_for_each_drv+0x78/0xd0
[    7.094424]  __device_attach+0xa8/0x1e4
[    7.094432]  device_initial_probe+0x14/0x20
[    7.094439]  bus_probe_device+0x98/0xa0
[    7.094446]  deferred_probe_work_func+0x94/0xe4
[    7.094453]  process_one_work+0x1d0/0x354
[    7.094461]  worker_thread+0x13c/0x470
[    7.094467]  kthread+0x150/0x160
[    7.094476]  ret_from_fork+0x10/0x20
[    7.094485] SMP: stopping secondary CPUs
[    7.094500] Kernel Offset: disabled
[    7.094502] CPU features: 0x800820b1,20000846
[    7.094507] Memory Limit: none

error 2 on another startup:

 [  OK  ] Started Network Time Synchronization.
[  OK  ] Reached target System Time Set.
[  OK  ] Created slice Slice /system/systemd-backlight.
[    6.766987] caam 31400000.crypto: device ID = 0x0a16040000000100 (Era 9)
[    6.768649] amphion-vpu-core 2d090000.vpu-core: encoder firmware version : 1.3.3
[    6.786089] caam 31400000.crypto: job rings = 2, qi = 0
         Starting Load/Save Screen …ness of backlight:backlight...
[    6.810161] amphion-vpu-core 2d080000.vpu-core: decoder firmware version : 1.8.5
[  OK  ] Finished Load/Save Screen …htness of backlight:backlight.
[    6.923103] imx-drm display-subsystem: bound imx-drm-dpu-bliteng.2 (ops dpu_bliteng_ops)
[  OK  ] Finished Coldplug All udev Devices    6.933842] imx-drm display-subsystem: bound imx-drm-dpu-bliteng.5 (ops dpu_bliteng_ops)
0m.
[    6.949687] imx-drm display-subsystem: bound imx-dpu-crtc.0 (ops dpu_crtc_ops)
[    6.959900] imx8_media_dev: module is from the staging directory, the quality is unknown, you have been warned.
[    6.962273] imx-drm display-subsystem: bound imx-dpu-crtc.1 (ops dpu_crtc_ops)
[    6.985157] imx-drm display-subsystem: bound imx-dpu-crtc.3 (ops dpu_crtc_ops)
         Starting Wait for udev To …plete Device Initi[    7.016515] imx-drm display-subsystem: bound imx-dpu-crtc.4 (ops dpu_crtc_ops)
alization...
[    7.118834] CAN device driver interface
[    7.126212] mxc-jpeg 58400000.jpegdec: decoder device registered as /dev/video2 (81,2)
[  OK  ] Reached target Hardware activated USB gadget.
[    7.162069] mxc-jpeg 58450000.jpegenc: encoder device registered as /dev/video3 (81,3)
[    7.207419] [drm] Started firmware!
[    7.220299] [drm] HDP FW Version - ver 34559 verlib 20560
[    7.235921] cdns-mhdp-imx 56268000.hdmi: lane-mapping 0x93
[    7.241858] [drm] HDCP is disabled
[    7.257783] imx-drm display-subsystem: bound 56268000.hdmi (ops cdns_mhdp_imx_ops [cdns_mhdp_imx])
[    7.283346] hdmi_pxl_clk: failed to set clock parent -16
[    7.288774] clk: failed to reparent hdmi_pxl_clk to hdmi_av_pll_clk: -16
[    7.293388] cfg80211: Loading compiled-in X.509 certificates for regulatory database
[    7.296566] hdmi_pixel_mux_clk: failed to set clock parent -16
[    7.310116] clk: failed to reparent hdmi_pixel_mux_clk to hdmi_av_pll_clk: -16
[    7.316323] input: PenMount PM1410 as /devices/platform/bus@5b000000/5b0e0000.usb/ci_hdrc.1/usb3/3-1/3-1.3/3-1.3:1.0/0003:14E1:3508.0001/input/input2
[    7.323277] cfg80211: Loaded X.509 cert 'sforshee: 00b28ddf47aef9cea7'
[    7.330921] hdmi_pixel_link_clk: failed to set clock parent -16
[    7.333555] hid-multitouch 0003:14E1:3508.0001: input: USB HID v1.11 Device [PenMount PM1410] on usb-ci_hdrc.1-1.3/input0
[    7.355389] clk: failed to reparent hdmi_pixel_link_clk to hdmi_av_pll_clk: -16
[    7.368556] imx-drm display-subsystem: bound imx-drm-dpu-bliteng.2 (ops dpu_bliteng_ops)
[    7.376840] imx-drm display-subsystem: bound imx-drm-dpu-bliteng.5 (ops dpu_bliteng_ops)
[    7.385666] imx-drm display-subsystem: bound imx-dpu-crtc.0 (ops dpu_crtc_ops)
[    7.393739] imx-drm display-subsystem: bound imx-dpu-crtc.1 (ops dpu_crtc_ops)
[    7.393820] mwifiex_pcie 0000:01:00.0: no quirks enabled
[    7.401432] imx-drm display-subsystem: bound imx-dpu-crtc.3 (ops dpu_crtc_ops)
[    7.408969] mwifiex_pcie 0000:01:00.0: enabling device (0000 -> 0002)
[    7.415332] imx-drm display-subsystem: bound imx-dpu-crtc.4 (ops dpu_crtc_ops)
[    7.420424] mwifiex_pcie: PCI memory map Virt0: (____ptrval____) PCI memory map Virt2: (____ptrval____)
[    7.441592] imx-hdmi sound-hdmi: snd_soc_register_card failed (-517)
[    7.447227] SError Interrupt on CPU5, code 0xbf000002 -- SError
[    7.447238] CPU: 5 PID: 186 Comm: kworker/u12:3 Tainted: G         C O      5.15.77-0+git.349786b46e61 #1
[    7.447244] Hardware name: Toradex Apalis iMX8QM V1.1 on Apalis Evaluation Board (DT)
[    7.447248] Workqueue: events_unbound deferred_probe_work_func
[    7.447267] pstate: 60000005 (nZCv daif -PAN -UAO -TCO -DIT -SSBS BTYPE=--)
[    7.447272] pc : cdns_mhdp_bus_write+0x8c/0x100 [cdns_mhdp_drmcore]
[    7.447295] lr : cdns_mhdp_bus_write+0x2c/0x100 [cdns_mhdp_drmcore]
[    7.447307] sp : ffff80000af9b910
[    7.447309] x29: ffff80000af9b910 x28: ffff000801258350 x27: ffff0008056ab200
[    7.447316] x26: 0000000000000000 x25: ffff80000109f1b8 x24: ffff0008054c2120
[    7.447321] x23: ffff0008054c0080 x22: 0000000022222211 x21: ffff0008054c0d88
[    7.447326] x20: 0000000000010004 x19: ffff0008054c0080 x18: 0000000000000000
[    7.447332] x17: ffff80087604a000 x16: ffff800009c24000 x15: 000000aab6440090
[    7.447337] x14: 0000000000000384 x13: 0000000000000001 x12: 0000000000000001
[    7.447342] x11: 0000000000000000 x10: 00000000000009c0 x9 : ffff80000af9b810
[    7.447347] x8 : ffff0008018c7a20 x7 : ffff00087f796400 x6 : 0000000000000000
[    7.447352] x5 : 0000000000220000 x4 : 0000000000000000 x3 : ffff0008054c0d88
[    7.447356] x2 : ffff0008018c7000 x1 : 0000000000000010 x0 : ffff80000a313008
[    7.447363] Kernel panic - not syncing: Asynchronous SError Interrupt
[    7.447366] CPU: 5 PID: 186 Comm: kworker/u12:3 Tainted: G         C O      5.15.77-0+git.349786b46e61 #1
[    7.447370] Hardware name: Toradex Apalis iMX8QM V1.1 on Apalis Evaluation Board (DT)
[    7.447372] Workqueue: events_unbound deferred_probe_work_func
[    7.447378] Call trace:
[    7.447379]  dump_backtrace+0x0/0x1cc
[    7.447387]  show_stack+0x18/0x70
[    7.447392]  dump_stack_lvl+0x68/0x84
[    7.447397]  dump_stack+0x18/0x34
[    7.447400]  panic+0x15c/0x31c
[    7.447405]  nmi_panic+0x8c/0x90
[    7.447411]  arm64_serror_panic+0x6c/0x7c
[    7.447414]  do_serror+0x58/0x5c
[    7.447416]  el1h_64_error_handler+0x30/0x50
[    7.447422]  el1h_64_error+0x78/0x7c
[    7.447426]  cdns_mhdp_bus_write+0x8c/0x100 [cdns_mhdp_drmcore]
[    7.447438]  cdns_mhdp_firmware_write_section+0x74/0xa0 [cdns_mhdp_imx]
[    7.447447]  cdns_mhdp_firmware_init_imx8qm+0xac/0x1c0 [cdns_mhdp_imx]
[    7.447453]  __cdns_hdmi_probe+0x174/0x37c [cdns_mhdp_drmcore]
[    7.447465]  cdns_hdmi_bind+0x28/0x90 [cdns_mhdp_drmcore]
[    7.447478]  cdns_mhdp_imx_bind+0xe0/0x160 [cdns_mhdp_imx]
[    7.447484]  component_bind_all+0x124/0x284
[    7.447491]  imx_drm_bind+0x15c/0x20c
[    7.447494]  try_to_bring_up_master+0x228/0x314
[    7.447499]  __component_add+0xa0/0x18c
[    7.447504]  component_add+0x14/0x20
[    7.447509]  cdns_mhdp_imx_probe+0x1c/0x30 [cdns_mhdp_imx]
[    7.447514]  platform_probe+0x68/0xe0
[    7.447518]  really_probe+0xbc/0x46c
[    7.447523]  __driver_probe_device+0x114/0x190
[    7.447527]  driver_probe_device+0x40/0x100
[    7.447532]  __device_attach_driver+0xbc/0x160
[    7.447536]  bus_for_each_drv+0x78/0xd0
[    7.447541]  __device_attach+0xa8/0x1e4
[    7.447545]  device_initial_probe+0x14/0x20
[    7.447550]  bus_probe_device+0x98/0xa0
[    7.447554]  deferred_probe_work_func+0x94/0xe4
[    7.447558]  process_one_work+0x1d0/0x354
[    7.447562]  worker_thread+0x13c/0x470
[    7.447564]  kthread+0x150/0x160
[    7.447569]  ret_from_fork+0x10/0x20
[    7.447574] SMP: stopping secondary CPUs
[    7.447996] Kernel Offset: disabled
[    7.447998] CPU features: 0x800820b1,20000846
[    7.448002] Memory Limit: none
[    7.769480] ---[ end Kernel panic - not syncing: Asynchronous SError Interrupt ]---

I see a massive difference on overlay file changes on this release.
On previouse releases boot/overlay/ folder had different dtbo files than this one. Such as, there were no apalis-imx8_spi1_spidev_overlay.dtbo apalis-imx8_spi2_spidev_overlay.dtbo files. Touch screen
overlays dtbo file had a different name.

ls /media/BOOT-mmcblk0p1/overlays/
apalis-imx8_ar0521_overlay.dtbo
apalis-imx8_hdmi_overlay.dtbo
apalis-imx8_mezzanine_can_overlay.dtbo
apalis-imx8_mezzanine_ov5640_overlay.dtbo
apalis-imx8_mezzanine_panel-cap-touch-10inch-lvds_overlay.dtbo
apalis-imx8_ov5640_overlay.dtbo
apalis-imx8_panel-cap-touch-10inch-lvds_overlay.dtbo
apalis-imx8_panel-lvds-dual-channel-1080p_overlay.dtbo
apalis-imx8_resistive-touch_overlay.dtbo
apalis-imx8_spi1_spidev_overlay.dtbo
apalis-imx8_spi2_spidev_overlay.dtbo
display-dpi-lt170410_overlay.dtbo
display-edt5.7_overlay.dtbo
display-edt7_overlay.dtbo
display-fullhd_overlay.dtbo
display-lt161010_overlay.dtbo
display-lt170410_overlay.dtbo
display-vga_overlay.dtbo

Could anyone help me on this. It is the default not-modified b2qt image and I’m still getting this error if I want to use dual screen setup.

Best regards
Ahmet.

Hi @ahmetg !

Toradex doesn’t maintain Boot2Qt image. You will be able to get better help from Qt directly.

Also, their documentation might be helpful to you

https://doc.qt.io/Boot2Qt/index.html

https://doc.qt.io/Boot2Qt/b2qt-how-to-customize.html

Best regards,

Hi Henrique,

Overlays and dtbo settings are coming form Toradex BSP, correct me if I’m wrong. In this example, we were trying to use correct dtbo in overlays.txt file to get screens work.
Do you have an example for how to make HDMI and LVDS work together.

Best regards
Ahmet

Hi @ahmetg !

This actually makes sense :slight_smile:

Sorry I didn’t catch this before.

You can go to Toradex Developer articles to find information about the overlays and related BSP versions.

This article will help you: Device Tree Overlays (Linux) | Toradex Developer Center. Be aware that the versions in there refer to Toradex BSP/Torizon OS version.

Best regards,

Hi @henrique.tx

I have downloaded toradex multimedia referance image Apalis-iMX8_Reference-Multimedia-Image-Tezi_6.4.0+build.8 from Toradex Artifactory web page.

Artifacts Toradex

And tested it with default settings for an HDMI screen. It works out of box.
/boot/overlyas.txt file which has overlay driver setting file is as follows:

root@apalis-imx8-14715897:~# cat /boot/overlays.txt
fdt_overlays=apalis-imx8_hdmi_overlay.dtbo apalis-imx8_spi1_spidev_overlay.dtbo apalis-imx8_spi2_spidev_overlay.dtbo

And changed it for a LVDS touch screen:

root@apalis-imx8-14715897:~# cat /boot/overlays.txt
fdt_overlays=apalis-imx8_panel-cap-touch-10inch-lvds_overlay.dtbo

It worked for the LVDS touch screen too.

Then I changed it for a dual screen usage.

root@apalis-imx8-14715897:~# cat /boot/overlays.txt
fdt_overlays=fdt_overlays=apalis-imx8_hdmi_overlay.dtbo apalis-imx8_spi1_spidev_overlay.dtbo 
apalis-imx8_spi2_spidev_overlay.dtbo apalis-imx8_panel-cap-touch-10inch-lvds_overlay.dtbo 

This time it crashes. This is Toradex multimedia reference image. Could you please help on this.

crash on bootup:

[  OK  ] Finished Load/Save Random Seed.
[  OK  ] Started Rule-based Manager for Device Events and Files.
[  OK  ] Finished Create Volatile Files and Directories.
         Starting Network Time Synchronization...
         Starting Record System Boot/Shutdown in UTMP...
[  OK  ] Finished Record System Boot/Shutdown in UTMP.
[  OK  ] Started Network Time Synchronization.
[  OK  ] Reached target System Time Set.
[    7.334769] amphion-vpu-core 2d090000.vpu-core: encoder firmware version : 1.3.3
[  OK  ] Created slice Slice /system/systemd-backlight.
         Starting Load/Save Screen …ness of backlight:backlight...
[    7.370172] caam 31400000.crypto: device ID = 0x0a16040000000100 (Era 9)
[    7.380032] caam 31400000.crypto: job rings = 2, qi = 0
[    7.380898] amphion-vpu-core 2d080000.vpu-core: decoder firmware version : 1.8.5
[  OK  ] Finished Coldplug All udev Devices.
[  OK  ] Finished Load/Save Screen …htness of backlight:backlight.
[    7.463687] imx-drm display-subsystem: bound imx-drm-dpu-bliteng.2 (ops dpu_bliteng_ops)
[    7.475011] imx-drm display-subsystem: bound imx-drm-dpu-bliteng.5 (ops dpu_bliteng_ops)
         Starting Wait for udev To …plete Device Initi[    7.484528] imx-drm display-subsystem: bound imx-dpu-crtc.0 (ops dpu_crtc_ops)
alization...
[    7.504549] imx8_media_dev: module is from the staging directory, the quality is unknown, you have been warned.
[    7.520860] imx-drm display-subsystem: bound imx-dpu-crtc.1 (ops dpu_crtc_ops)
[    7.530226] imx-drm display-subsystem: bound imx-dpu-crtc.3 (ops dpu_crtc_ops)
[    7.538303] imx-drm display-subsystem: bound imx-dpu-crtc.4 (ops dpu_crtc_ops)
[    7.551383] mxc-jpeg 58400000.jpegdec: decoder device registered as /dev/video2 (81,2)
[    7.561527] mxc-jpeg 58450000.jpegenc: encoder device registered as /dev/video3 (81,3)
[    7.591032] [drm] Started firmware!
[    7.603936] CAN device driver interface
[    7.610487] [drm] HDP FW Version - ver 34559 verlib 20560
[  OK  ] Found device /dev/ttyLP1.
[    7.626849] cdns-mhdp-imx 56268000.hdmi: lane-mapping 0x93
[    7.634356] [drm] HDCP is disabled
[    7.640491] imx-drm display-subsystem: bound 56268000.hdmi (ops cdns_mhdp_imx_ops [cdns_mhdp_imx])
[    7.671414] atmel_mxt_ts 4-004a: supply vdda not found, using dummy regulator
[    7.682646] hdmi_pxl_clk: failed to set clock parent -16
[    7.688154] clk: failed to reparent hdmi_pxl_clk to hdmi_av_pll_clk: -16
[    7.695306] hdmi_pixel_mux_clk: failed to set clock parent -16
[    7.701346] clk: failed to reparent hdmi_pixel_mux_clk to hdmi_av_pll_clk: -16
[    7.706928] atmel_mxt_ts 4-004a: supply vdd not found, using dummy regulator
[    7.708917] hdmi_pixel_link_clk: failed to set clock parent -16
[    7.721732] clk: failed to reparent hdmi_pixel_link_clk to hdmi_av_pll_clk: -16
[    7.732954] imx-drm display-subsystem: bound imx-drm-dpu-bliteng.2 (ops dpu_bliteng_ops)
[    7.741531] imx-drm display-subsystem: bound imx-drm-dpu-bliteng.5 (ops dpu_bliteng_ops)
[    7.751258] ahci-imx 5f020000.sata: Adding to iommu group 3
[    7.752800] imx-drm display-subsystem: bound imx-dpu-crtc.0 (ops dpu_crtc_ops)
[    7.757457] ahci-imx 5f020000.sata: phy impedance ratio is not specified.
[    7.764579] imx-drm display-subsystem: bound imx-dpu-crtc.1 (ops dpu_crtc_ops)
[    7.772847] ahci-imx 5f020000.sata: No cache used with register defaults set!
[    7.781741] imx-drm display-subsystem: bound imx-dpu-crtc.3 (ops dpu_crtc_ops)
[    7.786988] ahci-imx 5f020000.sata: supply ahci not found, using dummy regulator
[    7.793133] input: PenMount PM1410 as /devices/platform/bus@5b000000/5b0e0000.usb/ci_hdrc.1/usb3/3-1/3-1.3/3-1.3:1.0/0003:14E1:3508.0001/input/input2
[    7.794276] imx-drm display-subsystem: bound imx-dpu-crtc.4 (ops dpu_crtc_ops)
[    7.801089] ahci-imx 5f020000.sata: supply phy not found, using dummy regulator
[    7.809418] SError Interrupt on CPU1, code 0x00000000bf000002 -- SError
[    7.809436] CPU: 1 PID: 295 Comm: kworker/u12:7 Tainted: G         C O      5.15.129-6.4.0+git.67c3153d20ff #1
[    7.809446] Hardware name: Toradex Apalis iMX8QM V1.1 on Apalis Evaluation Board (DT)
[    7.809452] Workqueue: events_unbound deferred_probe_work_func
[    7.809474] pstate: 60000005 (nZCv daif -PAN -UAO -TCO -DIT -SSBS BTYPE=--)
[    7.809481] pc : mutex_unlock+0x44/0x70
[    7.809492] lr : cdns_mhdp_bus_write+0xa4/0x100 [cdns_mhdp_drmcore]
[    7.809529] sp : ffff80000d08b910
[    7.809531] x29: ffff80000d08b910 x28: ffff0008013ce550 x27: ffff00080560e300
[    7.809541] x26: 0000000000000000 x25: ffff8000010b01c0 x24: ffff0008014e6120
[    7.809550] x23: ffff0008014e4080 x22: 0000000022222211 x21: ffff0008014e4d88
[    7.809559] x20: 0000000000000004 x19: ffff0008014e4080 x18: 0000000000000000
[    7.809567] x17: 0000000000000000 x16: 0000000000000000 x15: 00006f5004b85d80
[    7.809575] x14: 0224439cbc14c200 x13: 0000000000000001 x12: 0000000000000001
[    7.809584] x11: 0000000000000001 x10: 00000000000009e0 x9 : ffff80000d08b810
[    7.809592] x8 : ffff000801073500 x7 : ffff00087f706440 x6 : 0000000000000000
[    7.809601] x5 : 0000000000220000 x4 : 0000000000000000 x3 : ffff0008014e4d88
[    7.809609] x2 : 0000000000000000 x1 : ffff000801072ac0 x0 : ffff000801072ac0
[    7.809620] Kernel panic - not syncing: Asynchronous SError Interrupt
[    7.809624] CPU: 1 PID: 295 Comm: kworker/u12:7 Tainted: G         C O      5.15.129-6.4.0+git.67c3153d20ff #1
[    7.809630] Hardware name: Toradex Apalis iMX8QM V1.1 on Apalis Evaluation Board (DT)
[    7.809634] Workqueue: events_unbound deferred_probe_work_func
[    7.809642] Call trace:
[    7.809644]  dump_backtrace+0x0/0x1f0
[    7.809657]  show_stack+0x18/0x40
[    7.809664]  dump_stack_lvl+0x68/0x84
[    7.809674]  dump_stack+0x18/0x34
[    7.809681]  panic+0x18c/0x34c
[    7.809686]  add_taint+0x0/0xc0
[    7.809697]  arm64_serror_panic+0x6c/0x7c
[    7.809703]  do_serror+0x58/0x5c
[    7.809707]  el1h_64_error_handler+0x30/0x50
[    7.809714]  el1h_64_error+0x78/0x7c
[    7.809720]  mutex_unlock+0x44/0x70
[    7.809727]  cdns_mhdp_firmware_write_section+0x74/0xa0 [cdns_mhdp_imx]
[    7.809742]  cdns_mhdp_firmware_init_imx8qm+0xac/0x1c0 [cdns_mhdp_imx]
[    7.809753]  __cdns_hdmi_probe+0x174/0x37c [cdns_mhdp_drmcore]
[    7.809778]  cdns_hdmi_bind+0x28/0x90 [cdns_mhdp_drmcore]
[    7.809804]  cdns_mhdp_imx_bind+0xe4/0x170 [cdns_mhdp_imx]
[    7.809815]  component_bind_all+0x124/0x284
[    7.809823]  imx_drm_bind+0x15c/0x210
[    7.809832]  try_to_bring_up_master+0x228/0x314
[    7.809838]  __component_add+0xa0/0x18c
[    7.809844]  component_add+0x14/0x20
[    7.809851]  cdns_mhdp_imx_probe+0x1c/0x30 [cdns_mhdp_imx]
[    7.809861]  platform_probe+0x68/0xe0
[    7.809869]  really_probe+0xbc/0x46c
[    7.809874]  __driver_probe_device+0x104/0x160
[    7.809880]  driver_probe_device+0x40/0x120
[    7.809886]  __device_attach_driver+0xbc/0x160
[    7.809892]  bus_for_each_drv+0x7c/0xdc
[    7.809901]  __device_attach+0xac/0x1f0
[    7.809907]  device_initial_probe+0x14/0x20
[    7.809913]  bus_probe_device+0x98/0xa0
[    7.809919]  deferred_probe_work_func+0x94/0xe4
[    7.809924]  process_one_work+0x1d0/0x374
[    7.809932]  worker_thread+0x13c/0x490
[    7.809937]  kthread+0x150/0x160
[    7.809948]  ret_from_fork+0x10/0x20
[    7.809957] SMP: stopping secondary CPUs
[    7.813925] Kernel Offset: disabled
[    7.813928] CPU features: 0x4,000820b1,20000846
[    7.813933] Memory Limit: none

Hi @ahmetg !

I had it working a couple of weeks ago, as you can see from the following picture:

As HDMI is enabled by default, I simply followed this to enable the LVDS on Apalis iMX8: Device Tree Overlays on Torizon | Toradex Developer Center

To quickly modify the set of overlays applied, I followed this (just like you are doing): Device Tree Overlays on Torizon | Toradex Developer Center

I see you still have the SPI overlays enabled. Have you tried to remove them?

Best regards,

Hi again, @ahmetg !

I just realized that you have fdt_overlays= twice in your /boot/overlays.txt. Please fix that before trying to remove the SPI-related overlays :wink:

Best regards,

Hi @henrique.tx

It was a copy paste error.
I booted with disabling fdt file from in uboot, “setenv skip_fdt_overlays 1”.

I checked it now. The following is the overlays.txt file.

root@b2qt-apalis-imx8:~# cat /media/BOOT-mmcblk0p1/overlays.txt
fdt_overlays=apalis-imx8_hdmi_overlay.dtbo apalis-imx8_spi1_spidev_overlay.dtbo apalis-imx8_spi2_spidev_overlay.dtbo apalis-imx8_panel-cap-touch-10inch-lvds_overlay.dtbo

It is still crashing on kernel start.

Best regards
Ahmet

Hi @ahmetg !

Please keep using the Reference Multimedia Image from Toradex.

We must first make it work there for you.

Best regards,

Hi @henrique.tx

Reference image is working. What is not working is dual screen setting.
We want to use HDMI and LVDS touch screen together.

Best regards
Ahmet.

Hi @ahmetg

Sorry. Let me be more explicit:

Please keep using the Reference Multimedia Image from Toradex.

We must first make the dual screen (HDMI + LVDS) work there for you in there.

Best regards,

Hi @henrique.tx

Changed

root@b2qt-apalis-imx8:~# cat /media/BOOT-mmcblk0p1/overlays.txt
fdt_overlays=apalis-imx8_hdmi_overlay.dtbo apalis-imx8_panel-cap-touch-10inch-lvds_overlay.dtbo

It still crashes at the startup.

Yes, it is what I’m trying to do here.
As one screen : HDMI works
As one screen : LVDS works
Dual screen, (no mirroring or no other modification to Toradex referance image): Crashes at the startup.
Only change is in the overlays.txt file.

What I want to see is at least proper boot. After I can check the /sys/class/drm for screen devices as such. But at this point it does not work at all.

And this is not a TorizonCore OS.
I have downloaded toradex multimedia referance image Apalis-iMX8_Reference-Multimedia-Image-Tezi_6.4.0+build.8 from Toradex Artifactory web page.

Artifacts Toradex

Best Regards
Ahmet

Hi @ahmetg !

From this, I see you are still using Boot2Qt. Please use Toradex Reference Multimedia Image.

Best regards,

Hi @henrique.tx

Thanks for pointing out that!

sorry for the confusion. Wrong imx8 card.

I tried with the Toradex Reference Multimedia Image, it is the same result.

root@apalis-imx8-14715897:~# cat /boot/overlays.txt
fdt_overlays=apalis-imx8_hdmi_overlay.dtbo apalis-imx8_spi1_spidev_overlay.dtbo apalis-imx8_spi2_spidev_overlay.dtbo apalis-imx8_panel-cap-touch-10inch-lvds_overlay.dtbo
root@apalis-imx8-14715897:~# sync

Boot sequence:

U-Boot 2022.04-6.4.0+git.dc27426aa417 (Sep 25 2023 - 13:34:50 +0000)

CPU:   NXP i.MX8QM RevB A53 at 1200 MHz at 84C

DRAM:  4 GiB
Core:  193 devices, 19 uclasses, devicetree: separate
MMC:   FSL_SDHC: 0, FSL_SDHC: 1, FSL_SDHC: 2
Loading Environment from MMC... OK
In:    serial
Out:   serial
Err:   serial
Model: Toradex 0037 Apalis iMX8QM 4GB WB IT V1.1E
Serial#: 14715897

 BuildInfo:
  - SCFW 6638c032, SECO-FW c9de51c0, IMX-MKIMAGE 3bfcfccb, ATF 3c1583b
  - U-Boot 2022.04-6.4.0+git.dc27426aa417

flash target is MMC:0
Net:   eth0: ethernet@5b040000
Fastboot: Normal
Normal Boot
Hit any key to stop autoboot:  0
MMC: no card present
MMC: no card present
switch to partitions #0, OK
mmc0(part 0) is current device
Scanning mmc 0:1...
Found U-Boot script /boot.scr
6010 bytes read in 3 ms (1.9 MiB/s)
 ## Executing script at 9d480000
Loading DeviceTree: imx8qm-apalis-v1.1-eval.dtb
170047 bytes read in 7 ms (23.2 MiB/s)
170 bytes read in 2 ms (83 KiB/s)
Applying Overlay: apalis-imx8_hdmi_overlay.dtbo
2205 bytes read in 3 ms (717.8 KiB/s)
Applying Overlay: apalis-imx8_spi1_spidev_overlay.dtbo
551 bytes read in 2 ms (268.6 KiB/s)
Applying Overlay: apalis-imx8_spi2_spidev_overlay.dtbo
551 bytes read in 3 ms (178.7 KiB/s)
Applying Overlay: apalis-imx8_panel-cap-touch-10inch-lvds_overlay.dtbo
1563 bytes read in 2 ms (762.7 KiB/s)
11663774 bytes read in 263 ms (42.3 MiB/s)
Bootargs: pci=nomsi root=PARTUUID=297f3ad4-02 ro rootwait console=tty1 console=ttyLP1,115200 consoleblank=0 earlycon
   Uncompressing Kernel Image
. ## Flattened Device Tree blob at 9d400000
   Booting using the fdt blob at 0x9d400000
   Loading Device Tree to 00000000fd626000, end 00000000fd672fff ... OK

Starting kernel ...

[    0.000000] Booting Linux on physical CPU 0x0000000000 [0x410fd034]
[    0.000000] Linux version 5.15.129-6.4.0+git.67c3153d20ff (oe-user@oe-host) (aarch64-tdx-linux-gcc (GCC) 11.4.0, GNU ld (GNU Binutils) 2.38.20220708) #1 SMP PREEMPT Wed Sep 27 12:30:36 UTC 2023
[    0.000000] Machine model: Toradex Apalis iMX8QM V1.1 on Apalis Evaluation Board

..
...
[    7.543913] imx-drm display-subsystem: bound imx-drm-dpu-bliteng.2 (ops dpu_bliteng_ops)
         Starting Load/Save Screen …ness of backlight:backlight...
[    7.564061] imx8_media_dev: module is from the staging directory, the quality is unknown, you have been warned.
[    7.581834] imx-drm display-subsystem: bound imx-drm-dpu-bliteng.5 (ops dpu_bliteng_ops)
[    7.606876] imx-drm display-subsystem: bound imx-dpu-crtc.0 (ops dpu_crtc_ops)
[    7.636971] imx-drm display-subsystem: bound imx-dpu-crtc.1 (ops dpu_crtc_ops)
[    7.653824] imx-drm display-subsystem: bound imx-dpu-crtc.3 (ops dpu_crtc_ops)
[    7.662823] imx-drm display-subsystem: bound imx-dpu-crtc.4 (ops dpu_crtc_ops)
[  OK  ] Finished Coldplug All udev Devices.
[  OK  ] Finished Load/Save Screen …htness of backlight:backlight.
[    7.725499] mxc-jpeg 58400000.jpegdec: decoder device registered as /dev/video2 (81,2)
[    7.731032] [drm] Started firmware!
[    7.746486] [drm] HDP FW Version - ver 34559 verlib 20560
[  OK  ] Found device /dev/ttyLP1.
[    7.759665] CAN device driver interface
[    7.771946] cdns-mhdp-imx 56268000.hdmi: lane-mapping 0x93
[    7.777745] [drm] HDCP is disabled
         Starting Wait for udev To …plete Device Initi[    7.798664] mxc-jpeg 58450000.jpegenc: encoder device registered as /dev/video3 (81,3)
alization...
[    7.803798] atmel_mxt_ts 4-004a: supply vdda not found, using dummy regulator
[    7.817798] imx-drm display-subsystem: bound 56268000.hdmi (ops cdns_mhdp_imx_ops [cdns_mhdp_imx])
[    7.843206] atmel_mxt_ts 4-004a: supply vdd not found, using dummy regulator
[    7.861100] hdmi_pxl_clk: failed to set clock parent -16
[    7.866861] clk: failed to reparent hdmi_pxl_clk to hdmi_av_pll_clk: -16
[    7.873994] hdmi_pixel_mux_clk: failed to set clock parent -16
[    7.879988] clk: failed to reparent hdmi_pixel_mux_clk to hdmi_av_pll_clk: -16
[    7.887834] hdmi_pixel_link_clk: failed to set clock parent -16
[    7.893889] clk: failed to reparent hdmi_pixel_link_clk to hdmi_av_pll_clk: -16
[    7.902714] imx-drm display-subsystem: bound imx-drm-dpu-bliteng.2 (ops dpu_bliteng_ops)
[    7.911369] imx-drm display-subsystem: bound imx-drm-dpu-bliteng.5 (ops dpu_bliteng_ops)
[    7.920070] imx-drm display-subsystem: bound imx-dpu-crtc.0 (ops dpu_crtc_ops)
[    7.927842] imx-drm display-subsystem: bound imx-dpu-crtc.1 (ops dpu_crtc_ops)
[    7.940642] imx-drm display-subsystem: bound imx-dpu-crtc.3 (ops dpu_crtc_ops)
[    7.948730] imx-drm display-subsystem: bound imx-dpu-crtc.4 (ops dpu_crtc_ops)
[    7.952941] ahci-imx 5f020000.sata: Adding to iommu group 3
[    7.962931] ahci-imx 5f020000.sata: phy impedance ratio is not specified.
[    7.969975] ahci-imx 5f020000.sata: No cache used with register defaults set!
[    7.973445] SError Interrupt on CPU0, code 0x00000000bf000002 -- SError
[    7.973462] CPU: 0 PID: 263 Comm: kworker/u12:5 Tainted: G         C O      5.15.129-6.4.0+git.67c3153d20ff #1
[    7.973470] Hardware name: Toradex Apalis iMX8QM V1.1 on Apalis Evaluation Board (DT)
[    7.973476] Workqueue: events_unbound deferred_probe_work_func
[    7.973498] pstate: 60000005 (nZCv daif -PAN -UAO -TCO -DIT -SSBS BTYPE=--)
[    7.973505] pc : mutex_unlock+0x44/0x70
[    7.973518] lr : cdns_mhdp_bus_write+0xa4/0x100 [cdns_mhdp_drmcore]
[    7.973557] sp : ffff80000a0bb910
[    7.973560] x29: ffff80000a0bb910 x28: ffff0008013b3d50 x27: ffff000804fcac80
[    7.973570] x26: 0000000000000000 x25: ffff8000010a31c0 x24: ffff0008056ca120
[    7.973579] x23: ffff0008056c8080 x22: 0000000022222211 x21: ffff0008056c8d88
[    7.973588] x20: 0000000000000004 x19: ffff0008056c8080 x18: 0000000000000000
[    7.973596] x17: ffff800875f86000 x16: ffff800008000000 x15: 000073f9879b9d83
[    7.973606] x14: 00000000000000be x13: 0000000000000000 x12: 0000000000000001
[    7.973614] x11: 0000000000000000 x10: 00000000000009e0 x9 : ffff80000a0bb810
[    7.973622] x8 : ffff0008001b6e00 x7 : ffff00087f6f2440 x6 : 0000000000000000
[    7.973631] x5 : 0000000000220000 x4 : 0000000000000000 x3 : ffff0008056c8d88
[    7.973639] x2 : 0000000000000000 x1 : ffff0008001b63c0 x0 : ffff0008001b63c0
[    7.973652] Kernel panic - not syncing: Asynchronous SError Interrupt
[    7.973658] CPU: 0 PID: 263 Comm: kworker/u12:5 Tainted: G         C O      5.15.129-6.4.0+git.67c3153d20ff #1
[    7.973664] Hardware name: Toradex Apalis iMX8QM V1.1 on Apalis Evaluation Board (DT)
[    7.973669] Workqueue: events_unbound deferred_probe_work_func
[    7.973677] Call trace:
[    7.973679]  dump_backtrace+0x0/0x1f0
[    7.973692]  show_stack+0x18/0x40
[    7.973700]  dump_stack_lvl+0x68/0x84
[    7.973710]  dump_stack+0x18/0x34
[    7.973717]  panic+0x18c/0x34c
[    7.973723]  add_taint+0x0/0xc0
[    7.973734]  arm64_serror_panic+0x6c/0x7c
[    7.973739]  do_serror+0x58/0x5c
[    7.973744]  el1h_64_error_handler+0x30/0x50
[    7.973753]  el1h_64_error+0x78/0x7c
[    7.973758]  mutex_unlock+0x44/0x70
[    7.973766]  cdns_mhdp_firmware_write_section+0x74/0xa0 [cdns_mhdp_imx]
[    7.973781]  cdns_mhdp_firmware_init_imx8qm+0xac/0x1c0 [cdns_mhdp_imx]
[    7.973792]  __cdns_hdmi_probe+0x174/0x37c [cdns_mhdp_drmcore]
[    7.973821]  cdns_hdmi_bind+0x28/0x90 [cdns_mhdp_drmcore]
[    7.973845]  cdns_mhdp_imx_bind+0xe4/0x170 [cdns_mhdp_imx]
[    7.973857]  component_bind_all+0x124/0x284
[    7.973865]  imx_drm_bind+0x15c/0x210
[    7.973874]  try_to_bring_up_master+0x228/0x314
[    7.973880]  __component_add+0xa0/0x18c
[    7.973886]  component_add+0x14/0x20
[    7.973892]  cdns_mhdp_imx_probe+0x1c/0x30 [cdns_mhdp_imx]
[    7.973904]  platform_probe+0x68/0xe0
[    7.973911]  really_probe+0xbc/0x46c
[    7.973916]  __driver_probe_device+0x104/0x160
[    7.973922]  driver_probe_device+0x40/0x120
[    7.973928]  __device_attach_driver+0xbc/0x160
[    7.973934]  bus_for_each_drv+0x7c/0xdc
[    7.973943]  __device_attach+0xac/0x1f0
[    7.973949]  device_initial_probe+0x14/0x20
[    7.973955]  bus_probe_device+0x98/0xa0
[    7.973961]  deferred_probe_work_func+0x94/0xe4
[    7.973966]  process_one_work+0x1d0/0x374
[    7.973973]  worker_thread+0x13c/0x490
[    7.973979]  kthread+0x150/0x160
[    7.973988]  ret_from_fork+0x10/0x20
[    7.973999] SMP: stopping secondary CPUs
[    7.977151] Kernel Offset: disabled
[    7.977154] CPU features: 0x4,000820b1,20000846
[    7.977159] Memory Limit: none

Image used: Apalis-iMX8_Reference-Multimedia-Image-Tezi_6.4.0+build.8.tar

Best regards
Ahmet

Hi @ahmetg !

I finally was able to reproduce the issue. When I tried it was indeed on Torizon OS. Just now it worked on Torizon OS 6.4.0.

  • Apalis iMX8QM 4GB WB IT V1.1C
  • Ixora V1.2A
    • Capacitive LVDS 10" from Toradex
    • HDMI capture

I performed the exact same steps as you and this is the contents of my overlays.txt:

fdt_overlays=apalis-imx8_hdmi_overlay.dtbo apalis-imx8_spi1_spidev_overlay.dtbo apalis-imx8_spi2_spidev_overlay.dtbo  apalis-imx8_panel-cap-touch-10inch-lvds_overlay.dtbo

But on Reference Multimedia Image from BSP 6.4.0 it indeed failed with the kernel panic you shared.

I will bring this up internally to be investigated.

Thanks for reporting!

Best regards,

Hi @ahmetg !

I just tested using the Reference Multimedia Image from the latest nightly (currently 6.5.0-devel-202312+build.16) and both displays worked.

Could you also try on your side?

The nightlies are available here: Download Links | Toradex Developer Center

If you want to download the exact same image I used, here is the link (also available from the page above):

https://artifacts.toradex.com/artifactory/tdxref-oe-prerelease-frankfurt/kirkstone-6.x.y/monthly/16/apalis-imx8/tdx-xwayland/tdx-reference-multimedia-image/oedeploy/Apalis-iMX8_Reference-Multimedia-Image-Tezi_6.5.0-devel-202312+build.16.tar

Best regards,

Hi @henrique.tx

Thanks for the link for the updated image.

But it still gets kernel panic most of the time, like 8 in 10 boot-up.
Yes, it works, when it boots up without kernel panic. Unfortunately, it still crashes most of the starts.

Could you try multiple power ups to confirm it works every time on your side?

Thanks
Ahmet

Hi @ahmetg !

You are right!

Sorry for getting to a conclusion so quickly. Seems like I was too lucky (or unlucky :sweat_smile: ).

In the meantime, I found out it is a known bug, as you can see here (ELB-5381): Toradex System/Computer on Modules - Linux BSP Release

I will send a new message here as soon as we have some updates.

Best regards,

Thanks @henrique.tx

Waiting for a response for the issue.

Here is a strange finding in one of startups. It started with no screens. There was no light or anything on the screens.
And there are FAILED and DEPEND states at startup log.
There is no screen device under “/sys/class/drm/”
It might be related to weston.service.
Added a log, that I found might be usable.

[ OK ] Reached target Bluetooth Support.
[ OK ] Started User Manager for UID 0.
[ OK ] Started Session c1 of User root.
[FAILED] Failed to start Weston, a …mpositor, as a system service.
See ‘systemctl status weston.service’ for details.
[DEPEND] Dependency failed for Start a wayland application.
[ OK ] Reached target Graphical Interface.
Starting Record Runlevel Change in UTMP…
[ OK ] Finished Record Runlevel Change in UTMP.

TDX Wayland with XWayland 6.5.0-devel-202312+build.16 (kirkstone) apalis-imx8-07107600 -
Apalis-iMX8_Reference-Multimedia-Image

apalis-imx8-07107600 login: [ 12.519222] fec 5b040000.ethernet eth0: Link is Up - 100Mbps/Full - flow control rx/tx
[ 12.527246] IPv6: ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready

apalis-imx8-07107600 login:
apalis-imx8-07107600 login: root
root@apalis-imx8-07107600:~# ls /sys/class/drm/
card0 renderD128 version
root@apalis-imx8-07107600:~# systemctl status weston.service
x weston.service - Weston, a Wayland compositor, as a system service
Loaded: loaded (/lib/systemd/system/weston.service; enabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Thu 2022-04-28 18:42:44 UTC; 1min 29s ago
TriggeredBy: * weston.socket
Docs: man:weston(1)
man:weston.ini(5)
http://wayland.freedesktop.org/
Process: 873 ExecStart=/usr/bin/weston --modules=systemd-notify.so (code=exited, status=1/FAILURE)
Main PID: 873 (code=exited, status=1/FAILURE)

Apr 28 18:42:43 apalis-imx8-07107600 systemd[1]: Starting Weston, a Wayland compositor, as a system service…
Apr 28 18:42:44 apalis-imx8-07107600 systemd[1]: weston.service: Main process exited, code=exited, status=1/FAILURE
Apr 28 18:42:44 apalis-imx8-07107600 systemd[1]: weston.service: Failed with result ‘exit-code’.
Apr 28 18:42:44 apalis-imx8-07107600 systemd[1]: Failed to start Weston, a Wayland compositor, as a system service.
root@apalis-imx8-07107600:~#

Best regards
Ahmet

Hi @ahmetg !

Thanks for sharing the additional information.

From what I could understand about the issue, it occurred before Weston, related to the initialization of the HDMI (you can see the __cdns_hdmi_probe in the call trace you shared here.

From that, I understand that when the module is able to (by chance) boot completely despite the error, DRM can’t start accordingly, so Weston will also fail.

In my tests, it usually fails and crashes during boot (with the same call trace you shared). Sometimes it completely succeeds (complete boot and working displays). And sometimes it boots completely, with the failure you just shared.

Best regards,