Crash when encountering an erroneous backlight device
Hoo boy, I wasn't even sure if I should report it here or to SDDM or to ddcci-driver. Looks like it's a Weston edge case crash so here I am.
I have SDDM set up to start in wayland mode, which uses Weston. I added the ddcci-driver
out-of-tree kernel driver and had the ddcci_backlight
module load on boot. My monitor returned invalid DDC/CI response. Weston crashed.
This only happened when I added these modules and stopped happening when I removed them.
Kernel noticing bad DDC/CI response:
lut 20 17:52:51 desktop-NixOS kernel: ddcci 8-0037: [6e:6e] invalid DDC/CI response, corrupted data - xor is 0x08, length 0x1d
lut 20 17:52:51 desktop-NixOS kernel: ddcci ddcci8: DDC/CI main device sent broken response on identification. Trying to detect solely based on capability information.
continued anyway:
lut 20 17:52:52 desktop-NixOS kernel: ddcci-backlight ddcci8: monitor doesn't announce support for backlight or luminance controls.
lut 20 17:52:52 desktop-NixOS systemd-modules-load[777]: Inserted module 'ddcci_backlight'
lut 20 17:52:52 desktop-NixOS kernel: ddcci-backlight ddcci8: registered backlight as backlight device ddcci8
lut 20 17:52:52 desktop-NixOS systemd[1]: Created slice Slice /system/systemd-backlight.
lut 20 17:52:52 desktop-NixOS systemd[1]: Starting Load/Save Screen Backlight Brightness of backlight:ddcci8...
lut 20 17:52:52 desktop-NixOS systemd-backlight[1072]: ddcci8: Maximum brightness is 0, ignoring device.
lut 20 17:52:52 desktop-NixOS systemd[1]: Finished Load/Save Screen Backlight Brightness of backlight:ddcci8.
and later this happened:
lut 20 17:52:53 desktop-NixOS openrgb[1171]: [i2c_smbus_linux] Failed to read i2c device PCI device ID
lut 20 17:52:53 desktop-NixOS openrgb[1171]: [i2c_smbus_linux] Failed to read i2c device PCI device ID
lut 20 17:52:53 desktop-NixOS openrgb[1171]: [i2c_smbus_linux] Failed to read i2c device PCI device ID
lut 20 17:52:53 desktop-NixOS sddm-helper-start-wayland[1583]: "[17:52:53.611] Loading module '/nix/store/mhzkzsx2hx281dm2h4vr5k7xylx3wv15-weston-12.0.2/lib/libweston-12/gl-renderer.so'\n"
lut 20 17:52:53 desktop-NixOS sddm-helper-start-wayland[1583]: "[17:52:53.617] Using rendering device: /dev/dri/renderD128\n"
lut 20 17:52:53 desktop-NixOS sddm-helper-start-wayland[1583]: "[17:52:53.617] EGL version: 1.5\n[17:52:53.617] EGL vendor: Mesa Project\n"
lut 20 17:52:53 desktop-NixOS sddm-helper-start-wayland[1583]: "[17:52:53.617] EGL client APIs: OpenGL OpenGL_ES \n"
lut 20 17:52:53 desktop-NixOS sddm-helper-start-wayland[1583]: "[17:52:53.617] EGL features:\n EGL Wayland extension: yes\n context priority: yes\n buffer age: yes\n partial update: no\n swap buffers with damage: no\n"
lut 20 17:52:53 desktop-NixOS sddm-helper-start-wayland[1583]: " configless context: yes\n surfaceless context: yes\n dmabuf support: modifiers\n"
lut 20 17:52:53 desktop-NixOS sddm-helper-start-wayland[1583]: "[17:52:53.619] GL version: OpenGL ES 3.2 Mesa 23.1.9\n[17:52:53.619] GLSL version: OpenGL ES GLSL ES 3.20\n"
lut 20 17:52:53 desktop-NixOS sddm-helper-start-wayland[1583]: "[17:52:53.619] GL vendor: AMD\n[17:52:53.619] GL renderer: AMD Radeon RX 6700 XT (navi22, LLVM 16.0.6, DRM 3.57, 6.7.5)\n"
lut 20 17:52:53 desktop-NixOS sddm-helper-start-wayland[1583]: "[17:52:53.624] GL ES 3.2 - renderer features:\n read-back format: ARGB8888\n glReadPixels supports y-flip: yes\n wl_shm 10 bpc formats: yes\n wl_shm 16 bpc formats: yes\n wl_shm half-float formats: yes\n internal R and RG formats: yes\n"
lut 20 17:52:53 desktop-NixOS sddm-helper-start-wayland[1583]: " OES_EGL_image_external: yes\n[17:52:53.624] Using GL renderer\n"
# Whole bunch of unrelated devices getting set up
lut 20 17:52:53 desktop-NixOS sddm-helper-start-wayland[1583]: "[17:52:53.800] DRM: head 'DP-1' found, connector 113 is disconnected.\n"
lut 20 17:52:53 desktop-NixOS sddm-helper-start-wayland[1583]: "[17:52:53.877] DRM: head 'DP-2' found, connector 121 is disconnected.\n"
lut 20 17:52:53 desktop-NixOS sddm-helper-start-wayland[1583]: "[17:52:53.881] DRM: EDID for the following head fails conformity:\nBlock 0, Base EDID:\n Invalid detailed timing descriptor ordering.\n\n"
lut 20 17:52:53 desktop-NixOS sddm-helper-start-wayland[1583]: "[17:52:53.958] DRM: head 'DP-3' found, connector 126 is connected, EDID make 'LG Electronics', model 'MP59G', serial '0x01010101'\n Supported EOTF modes: SDR, traditional gamma HDR, ST2084, HLG\n"
lut 20 17:52:54 desktop-NixOS sddm-helper-start-wayland[1583]: "[17:52:54.035] DRM: head 'HDMI-A-1' found, connector 132 is disconnected.\n"
lut 20 17:52:54 desktop-NixOS sddm-helper-start-wayland[1583]: "[17:52:54.035] Registered plugin API 'weston_drm_output_api_v1' of size 40\n"
lut 20 17:52:54 desktop-NixOS sddm-helper-start-wayland[1583]: "[17:52:54.035] Registered plugin API 'weston_drm_virtual_output_api_v2' of size 48\n[17:52:54.035] Color manager: no-op\n"
lut 20 17:52:54 desktop-NixOS sddm-helper-start-wayland[1583]: "[17:52:54.035] Output 'DP-3' attempts EOTF mode: SDR\n"
lut 20 17:52:54 desktop-NixOS sddm-helper-start-wayland[1583]: "[17:52:54.035] Output 'DP-3' using color profile: built-in default sRGB SDR profile\n"
lut 20 17:52:54 desktop-NixOS sddm-helper-start-wayland[1583]: "[17:52:54.036] Chosen EGL config details: id: 49 rgba: 8 8 8 0 buf: 24 dep: 0 stcl: 0 int: 1-1 type: win vis_id: XRGB8888 (0x34325258)\n"
lut 20 17:52:54 desktop-NixOS sddm-helper-start-wayland[1583]: "[17:52:54.036] Initialized backlight for head 'DP-3', device /sys/class/backlight/ddcci8\n"
lut 20 17:52:54 desktop-NixOS kernel: traps: weston[1585] trap divide error ip:7fa807ca8ab8 sp:7fff4d39cf70 error:0 in drm-backend.so[7fa807ca3000+16000]
lut 20 17:52:54 desktop-NixOS systemd[1]: Created slice Slice /system/systemd-coredump.
lut 20 17:52:54 desktop-NixOS systemd[1]: Started Process Core Dump (PID 1644/UID 0).
lut 20 17:52:54 desktop-NixOS systemd-coredump[1645]: Process 1585 (weston) of user 175 dumped core.
Module libxshmfence.so.1 without build-id.
Module libxcb-sync.so.1 without build-id.
Module libxcb-present.so.0 without build-id.
Module libxcb-xfixes.so.0 without build-id.
Module libxcb-dri2.so.0 without build-id.
Module libX11-xcb.so.1 without build-id.
Module libGLdispatch.so.0 without build-id.
Module libGLESv2.so.2 without build-id.
Module libEGL.so.1 without build-id.
Module gl-renderer.so without build-id.
Module libpciaccess.so.0 without build-id.
Module libxml2.so.2 without build-id.
Module libncursesw.so.6 without build-id.
Module libgcc_s.so.1 without build-id.
Module libstdc++.so.6 without build-id.
Module libxcb-dri3.so.0 without build-id.
Module libdrm_intel.so.1 without build-id.
Module libdrm_nouveau.so.2 without build-id.
Module libdrm_amdgpu.so.1 without build-id.
Module libelf.so.0 without build-id.
Module libdrm_radeon.so.1 without build-id.
Module libsensors.so.5 without build-id.
Module libz.so.1 without build-id.
Module libgpg-error.so.0 without build-id.
Module libzstd.so.1 without build-id.
Module liblzma.so.5 without build-id.
Module liblz4.so.1 without build-id.
Module libgcrypt.so.20 without build-id.
Module libXdmcp.so.6 without build-id.
Module libXau.so.6 without build-id.
Module libxcb.so.1 without build-id.
Module libsystemd.so.0 without build-id.
Module libxcb-randr.so.0 without build-id.
Module libexpat.so.1 without build-id.
Module libseat.so.1 without build-id.
Module libva-drm.so.2 without build-id.
Module libva.so.2 without build-id.
Module libdisplay-info.so.1 without build-id.
Module drm-backend.so without build-id.
Module libpcre2-8.so.0 without build-id.
Module libgudev-1.0.so.0 without build-id.
Module libcap.so.2 without build-id.
Module libaudit.so.1 without build-id.
Module libwacom.so.9 without build-id.
Module libudev.so.1 without build-id.
Module libmtdev.so.1 without build-id.
Module libffi.so.8 without build-id.
Module libpam.so.0 without build-id.
Module libxkbcommon.so.0 without build-id.
Module libdrm.so.2 without build-id.
Module libevdev.so.2 without build-id.
Module libinput.so.10 without build-id.
Module libweston-12.so.0 without build-id.
Module libexec_weston.so.0 without build-id.
Module weston without build-id.
Stack trace of thread 1585:
#0 0x00007fa807ca8ab8 drm_output_enable (drm-backend.so + 0x10ab8)
#1 0x00007fa808292509 weston_output_enable (libweston-12.so.0 + 0x27509)
#2 0x00007fa8084cb7eb drm_heads_changed (libexec_weston.so.0 + 0xc7eb)
#3 0x00007fa8082898f9 weston_compositor_call_heads_changed (libweston-12.so.0 + 0x1e8f9)
#4 0x00007fa8084ce73a wet_main (libexec_weston.so.0 + 0xf73a)
#5 0x00007fa8082fdfce __libc_start_call_main (libc.so.6 + 0x27fce)
#6 0x00007fa8082fe089 __libc_start_main@@GLIBC_2.34 (libc.so.6 + 0x28089)
#7 0x0000000000401075 _start (weston + 0x1075)
Stack trace of thread 1623:
#0 0x00007fa80835dcf6 __futex_abstimed_wait_common (libc.so.6 + 0x87cf6)
#1 0x00007fa8083604e8 pthread_cond_wait@@GLIBC_2.3.2 (libc.so.6 + 0x8a4e8)
#2 0x00007fa80530f289 cnd_wait (radeonsi_dri.so + 0x10f289)
#3 0x00007fa8052c334b util_queue_thread_func (radeonsi_dri.so + 0xc334b)
#4 0x00007fa80530f1c7 impl_thrd_routine (radeonsi_dri.so + 0x10f1c7)
#5 0x00007fa8083610e4 start_thread (libc.so.6 + 0x8b0e4)
#6 0x00007fa8083e375c __clone3 (libc.so.6 + 0x10d75c)
Stack trace of thread 1624:
#0 0x00007fa80835dcf6 __futex_abstimed_wait_common (libc.so.6 + 0x87cf6)
#1 0x00007fa8083604e8 pthread_cond_wait@@GLIBC_2.3.2 (libc.so.6 + 0x8a4e8)
#2 0x00007fa80530f289 cnd_wait (radeonsi_dri.so + 0x10f289)
#3 0x00007fa8052c334b util_queue_thread_func (radeonsi_dri.so + 0xc334b)
#4 0x00007fa80530f1c7 impl_thrd_routine (radeonsi_dri.so + 0x10f1c7)
#5 0x00007fa8083610e4 start_thread (libc.so.6 + 0x8b0e4)
#6 0x00007fa8083e375c __clone3 (libc.so.6 + 0x10d75c)
Stack trace of thread 1626:
#0 0x00007fa80835dcf6 __futex_abstimed_wait_common (libc.so.6 + 0x87cf6)
#1 0x00007fa8083604e8 pthread_cond_wait@@GLIBC_2.3.2 (libc.so.6 + 0x8a4e8)
#2 0x00007fa80530f289 cnd_wait (radeonsi_dri.so + 0x10f289)
#3 0x00007fa8052c334b util_queue_thread_func (radeonsi_dri.so + 0xc334b)
#4 0x00007fa80530f1c7 impl_thrd_routine (radeonsi_dri.so + 0x10f1c7)
#5 0x00007fa8083610e4 start_thread (libc.so.6 + 0x8b0e4)
#6 0x00007fa8083e375c __clone3 (libc.so.6 + 0x10d75c)
Stack trace of thread 1625:
#0 0x00007fa80835dcf6 __futex_abstimed_wait_common (libc.so.6 + 0x87cf6)
#1 0x00007fa8083604e8 pthread_cond_wait@@GLIBC_2.3.2 (libc.so.6 + 0x8a4e8)
#2 0x00007fa80530f289 cnd_wait (radeonsi_dri.so + 0x10f289)
#3 0x00007fa8052c334b util_queue_thread_func (radeonsi_dri.so + 0xc334b)
#4 0x00007fa80530f1c7 impl_thrd_routine (radeonsi_dri.so + 0x10f1c7)
#5 0x00007fa8083610e4 start_thread (libc.so.6 + 0x8b0e4)
#6 0x00007fa8083e375c __clone3 (libc.so.6 + 0x10d75c)
Stack trace of thread 1627:
#0 0x00007fa80835dcf6 __futex_abstimed_wait_common (libc.so.6 + 0x87cf6)
#1 0x00007fa8083604e8 pthread_cond_wait@@GLIBC_2.3.2 (libc.so.6 + 0x8a4e8)
#2 0x00007fa80530f289 cnd_wait (radeonsi_dri.so + 0x10f289)
#3 0x00007fa8052c334b util_queue_thread_func (radeonsi_dri.so + 0xc334b)
#4 0x00007fa80530f1c7 impl_thrd_routine (radeonsi_dri.so + 0x10f1c7)
#5 0x00007fa8083610e4 start_thread (libc.so.6 + 0x8b0e4)
#6 0x00007fa8083e375c __clone3 (libc.so.6 + 0x10d75c)
Stack trace of thread 1628:
#0 0x00007fa80835dcf6 __futex_abstimed_wait_common (libc.so.6 + 0x87cf6)
#1 0x00007fa8083604e8 pthread_cond_wait@@GLIBC_2.3.2 (libc.so.6 + 0x8a4e8)
#2 0x00007fa80530f289 cnd_wait (radeonsi_dri.so + 0x10f289)
#3 0x00007fa8052c334b util_queue_thread_func (radeonsi_dri.so + 0xc334b)
#4 0x00007fa80530f1c7 impl_thrd_routine (radeonsi_dri.so + 0x10f1c7)
#5 0x00007fa8083610e4 start_thread (libc.so.6 + 0x8b0e4)
#6 0x00007fa8083e375c __clone3 (libc.so.6 + 0x10d75c)
ELF object binary architecture: AMD x86-64
lut 20 17:52:54 desktop-NixOS systemd[1]: systemd-coredump@0-1644-0.service: Deactivated successfully.
lut 20 17:52:54 desktop-NixOS sddm-helper-start-wayland[1583]: wayland compositor finished 8 QProcess::CrashExit
lut 20 17:52:54 desktop-NixOS sddm-helper-start-wayland[1583]: quitting helper-start-wayland
I'd prefer not to attach the full boot log and hope this is enough context.