I'm struggling with very weird issue. I have two displays connected to my laptop. When I first start X everything is working fine.
xrandr
displays:
DVI-I-2-2 connected 1920x1080+0+0 (normal left inverted right x axis y axis) 531mm x 299mm
1920x1080 60.00*+ 119.98 50.00 59.94
DVI-I-1-1 connected 2560x1440+1920+0 (normal left inverted right x axis y axis) 597mm x 336mm
2560x1440 59.95*+ 74.97
However, if I disconnect those displays and connect again it reports:
DVI-I-2-2 connected (normal left inverted right x axis y axis)
1920x1080 60.00 + 119.98 50.00 59.94
DVI-I-1-1 connected (normal left inverted right x axis y axis)
2560x1440 59.95 + 74.97
Notice missing size of screen in mm at the end of each line. When I try to run xrandr to configure those displays it's crashing. I've debugged it and it's because it's trying to divide by screen size in mm but DisplayHeightMM returns 0:
https://man.docs.euro-linux.com/EL%209/libX11-devel/DisplayHeightMM.3.en.html
It's failing with floating point error.
After restarting X it's working fine again.
I'm using USB-C hub but when I tried connecting a display using HDMI I had the same issue.
I'm using amdgpu driver.
Any ideas?
Asked by Efrum
(1 rep)
Jul 18, 2025, 07:13 PM