Unable to load edid via kernel args

Following the instructions here: Display Output, Resolution and Timings (Linux) | Toradex Developer Center

I’m getting an error (which I believe is ENOENT)

apalis-imx6-10924932 login: [   38.245401] [drm:drm_load_edid_firmware] *ERROR* Requesting EDID firmware "edid/zl084.bin" failed (err=-2)
[   38.465834] [drm:drm_load_edid_firmware] *ERROR* Requesting EDID firmware "edid/zl084.bin" failed (err=-2)

apalis-imx6-10924932 login: torizon
Password:
torizon@apalis-imx6-10924932:~$ ls -la /lib/firmware/edid/zl034.bin
-rw-r--r-- 1 root root 256 Feb  9 16:48 /lib/firmware/edid/zl034.bin

Using stock torizoncore 5.4 build, KCONFIG is correct, a edid is verified on several other computers.

Any suggestions or work arounds?

Greetings @ed-bear,

Your error message says “zl084.bin”, but in the filesystem you find “zl034.bin”. Perhaps it’s just a type with the filenames?

Best Regards,
Jeremias

Oooo, I wish that was it, but this output was actually just from a demo I mocked up to post information here. The typo in the first post is real, but so is the issue I’m having:

[   42.823839] [drm:drm_load_edid_firmware] *ERROR* Requesting EDID firmware "edid/ZL034.bin" failed (err=-2)
[   43.046546] [drm:drm_load_edid_firmware] *ERROR* Requesting EDID firmware "edid/ZL034.bin" failed (err=-2)
torizon@apalis-imx6-10924932:~$ ls -la /lib/firmware/
LICENCE.Marvell               imx/                          rtlwifi/
LICENCE.rtlwifi_firmware.txt  mrvl/                         vpu/
LICENSE.sdma_firmware         regulatory.db
edid/                         regulatory.db.p7s
torizon@apalis-imx6-10924932:~$ ls -la /lib/firmware/edid/ZL034.bin
-rw-r--r-- 1 root root 256 Jan  1  1970 /lib/firmware/edid/ZL034.bin

Ah okay, well so much for an easy solution.

Okay, so starting from the beginning then. I have some initial questions/suggestions to make sure I understand everything.

First of all I assume you’re trying to load this custom edid binary because the default edid from your HDMI display doesn’t work or something similiar, correct?

Did you create this edid binary yourself or did you get it from somewhere? I assume you then manually wrote the binary to /lib/firmware/edid/ correct?

As for a suggestion, we admittedly haven’t tested this edid loading functionality too much in TorizonCore. If it’s not too much trouble could you flash our reference image instead and try the edid loading functionality there.

It would help us to narrow down whether the issue is with the lower-level BSP or with the upper-level TorizonCore.

Best Regards,
Jeremias

Hi @ed-bear , you have to put ZL034.bin into the weston container instead of /lib/firmware/edid/ on TorizonCore. For example, ZL034.bin is placed at /home/torizon/firmware and /home/torizon/firmware will be mounted to /home/torizon/firmware in a weston container e.g. torizon/weston-vivante:2. This is a docker-compose example. Meanwhile, add parameter to kernel command line. fw_setenv tdxargs drm.edid_firmware=ZL034.bin

  weston:
    cap_add:
    - CAP_SYS_TTY_CONFIG
    device_cgroup_rules:
    - c 4:0 rmw
    - c 4:7 rmw
    - c 13:* rmw
    - c 199:* rmw
    - c 226:* rmw
    environment:
    - ACCEPT_FSL_EULA=1
#    image: benjaminhu/weston-vivante-1080p:1
    image: torizon/weston-vivante:2
    network_mode: host
    volumes:
    - source: /tmp
      target: /tmp
      type: bind
    - source: /dev
      target: /dev
      type: bind
    - source: /run/udev
      target: /run/udev
      type: bind
    - source: /home/torizon/firmware
      target: /lib/firmware
      type: bind

Hi,
I’m experiencing the same issue as reported by @ed-bear with Torizon 6.7.0 and Yavia board
I have created a binary edid file 800x600.bin by compiling the files in
~/bin/build-torizon/tmp/work-shared/verdin-imx8mp/kernel-source/tools/edid

this file has been placed in /lib/firmware/edid/800x600.bin

The location /lib/firmware was read only. To create the folder edid and have the 800x600.bin file in it I had to follow the help of @jeremias.tx at https://community.toradex.com/t/how-to-configure-display-timing-for-7-non-toradex-monitor/12179/13 sudo mount -o remount,rw /dev/mmcblk2p2 /usr

Then I reboot and block the uboot and execute:
setenv tdxargs drm.edid_firmware=edid/800x600.bin
boot

After boot is finished I receive the same errors as @ed-bear
[ 2.741913] [drm:edid_load] ERROR Requesting EDID firmware “edid/600x600.bin” failed (err=-2)

Looking at the driver the error is generated here:
err = request_firmware(&fw, name, &pdev->dev);
platform_device_unregister(pdev);
if (err) {
DRM_ERROR(“Requesting EDID firmware "%s" failed (err=%d)\n”,
name, err);
return ERR_PTR(err);
}

uname -a
Linux verdin-imx8mp-15140068 5.15.148-6.7.0-devel+git.bfdbfb2c85fb #1-TorizonCore SMP PREEMPT Thu Jun 20 15:59:41 UTC 2024 aarch64 aarch64 aarch64 GNU/Linux

Can you please help me with the topic?

Hello @VMB,

Your general procedure is correct, but I believe that there was a typo in the setenv command, as you error message says edid/600x600.bin instead of edid/800x600.bin:

If this is not the problem, please open another topic on the community so we can look into this issue separately.

Best Regards,
Bruno

1 Like

Hi @bruno.tx,

I realized that it is just the file name and not its content to select between different modes. As you suggested I opened another topic here:

1 Like