Bug 1212954 - amdgpu: Monitor displaying wrong resolution
Summary: amdgpu: Monitor displaying wrong resolution
Status: IN_PROGRESS
Alias: None
Product: openSUSE Distribution
Classification: openSUSE
Component: X.Org (show other bugs)
Version: Leap 15.5
Hardware: x86-64 openSUSE Leap 15.5
: P3 - Medium : Normal (vote)
Target Milestone: ---
Assignee: Gfx Bugs
QA Contact: Gfx Bugs
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-07-03 15:07 UTC by Holger Sickenberg
Modified: 2024-02-16 13:34 UTC (History)
4 users (show)

See Also:
Found By: Development
Services Priority:
Business Priority:
Blocker: ---
Marketing QA Status: ---
IT Deployment: ---


Attachments
IMG_20230703_164538751_HDR.jpg (4.76 MB, image/jpeg)
2023-07-03 15:07 UTC, Holger Sickenberg
Details
hwinfo-samsung.txt (722.87 KB, text/plain)
2023-07-03 15:08 UTC, Holger Sickenberg
Details
xrandr-samsung.txt (4.22 KB, text/plain)
2023-07-03 15:08 UTC, Holger Sickenberg
Details
dmesg-samsung.txt (90.88 KB, text/plain)
2023-07-03 15:08 UTC, Holger Sickenberg
Details
xrandr-verbose-samsung.txt (56.91 KB, text/plain)
2023-07-03 15:09 UTC, Holger Sickenberg
Details
hwinfo-philips.txt (722.79 KB, text/plain)
2023-07-03 15:09 UTC, Holger Sickenberg
Details
xrandr-philips.txt (4.20 KB, text/plain)
2023-07-03 15:10 UTC, Holger Sickenberg
Details
dmesg-philips.txt (90.86 KB, text/plain)
2023-07-03 15:10 UTC, Holger Sickenberg
Details
IMG_20230703_180130037.jpg (5.60 MB, image/jpeg)
2023-07-03 16:04 UTC, Holger Sickenberg
Details
dmesg-5.14.21-150500.1.g08214d9-default.txt (90.16 KB, text/plain)
2023-08-17 09:24 UTC, Holger Sickenberg
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Holger Sickenberg 2023-07-03 15:07:07 UTC
Created attachment 867944 [details]
IMG_20230703_164538751_HDR.jpg

Having a 4K monitor (SAMSUNG LU28R55) attached to the docking station of my ThinkPad via HDMI I can easily 1:1 mirror the screen output of the laptop and the monitor with openSUSE Leap 15.4. Doing the same with openSUSE Leap 15.5 will result in monitor displaying a resolution 1980x2160 instead of the set 1980x1080.
Using a 4x different screen (Philips) is working fine.

Photo of monitor attached.
Comment 1 Holger Sickenberg 2023-07-03 15:08:18 UTC
Created attachment 867945 [details]
hwinfo-samsung.txt
Comment 2 Holger Sickenberg 2023-07-03 15:08:38 UTC
Created attachment 867946 [details]
xrandr-samsung.txt
Comment 3 Holger Sickenberg 2023-07-03 15:08:54 UTC
Created attachment 867947 [details]
dmesg-samsung.txt
Comment 4 Holger Sickenberg 2023-07-03 15:09:13 UTC
Created attachment 867948 [details]
xrandr-verbose-samsung.txt
Comment 5 Holger Sickenberg 2023-07-03 15:09:37 UTC
Created attachment 867949 [details]
hwinfo-philips.txt
Comment 6 Holger Sickenberg 2023-07-03 15:10:02 UTC
Created attachment 867950 [details]
xrandr-philips.txt
Comment 7 Holger Sickenberg 2023-07-03 15:10:28 UTC
Created attachment 867951 [details]
dmesg-philips.txt
Comment 8 Holger Sickenberg 2023-07-03 15:12:30 UTC
Adding a modline created with
> cvt -r 1920 1080
with:
> xrandr --newmode "1920x1080R"  138.50  1920 1968 2000 2080  1080 1083 1088 1111 +hsync -vsync
> xrandr --addmode DP-3  "1920x1080R"
> xrandr --output DP-3 --mode 1920x1080R

will result in having monitor displaying the correct resolution
Comment 9 Stefan Dirsch 2023-07-03 15:19:57 UTC
Thanks for reporting, Holgi!
Comment 10 Stefan Dirsch 2023-07-03 15:23:13 UTC
Looks like it uses some weird DoubleScan mode here ... maybe that's a feature of latest driver(s) on Leap 15.5 kernels.

1920x1080     60.01*   59.97    59.96    60.00    50.00    59.94    59.93  

1920x1080 (0x4b) 356.375MHz -HSync +VSync DoubleScan
        h: width  1920 start 2080 end 2288 total 2656 skew    0 clock 134.18KHz
        v: height 1080 start 1081 end 1084 total 1118           clock  60.01Hz
  1920x1080 (0x4c) 266.500MHz +HSync -VSync DoubleScan
        h: width  1920 start 1944 end 1960 total 2000 skew    0 clock 133.25KHz
        v: height 1080 start 1081 end 1084 total 1111           clock  59.97Hz
  1920x1080 (0x4d) 173.000MHz -HSync +VSync
        h: width  1920 start 2048 end 2248 total 2576 skew    0 clock  67.16KHz
        v: height 1080 start 1083 end 1088 total 1120           clock  59.96Hz
  1920x1080 (0xc1) 148.500MHz +HSync +VSync
        h: width  1920 start 2008 end 2052 total 2200 skew    0 clock  67.50KHz
        v: height 1080 start 1084 end 1089 total 1125           clock  60.00Hz
  1920x1080 (0xc2) 148.500MHz +HSync +VSync
        h: width  1920 start 2448 end 2492 total 2640 skew    0 clock  56.25KHz
        v: height 1080 start 1084 end 1089 total 1125           clock  50.00Hz
  1920x1080 (0xc3) 148.352MHz +HSync +VSync
        h: width  1920 start 2008 end 2052 total 2200 skew    0 clock  67.43KHz
        v: height 1080 start 1084 end 1089 total 1125           clock  59.94Hz
  1920x1080 (0x4e) 138.500MHz +HSync -VSync *current
        h: width  1920 start 1968 end 2000 total 2080 skew    0 clock  66.59KHz
        v: height 1080 start 1083 end 1088 total 1111           clock  59.93Hz
Comment 11 Takashi Iwai 2023-07-03 15:44:51 UTC
Could you check the behavior with the upstream 6.4.x kernel?  Test with the one in OBS Kernel:stable:Backport repo.

If the upstream kernel is confirmed to work, test with the one in OBS home:tiwai:kernel:6.3 and home:tiwai:kernel:6.2 (use "backport" repo for Leap -- "standard" is for TW), so that we can narrow down a regression fix range.
Comment 12 Holger Sickenberg 2023-07-03 16:04:32 UTC
Created attachment 867952 [details]
IMG_20230703_180130037.jpg

Same behavior as with regular 15.5 kernel - see photo
Comment 13 Takashi Iwai 2023-07-03 16:13:28 UTC
OK, then it means that it's an upstream bug :)

We need to report it to the upstream bug tracker, gitlab.freedesktop.org DRM/AMD Issues.
Comment 14 Takashi Iwai 2023-07-06 13:09:05 UTC
BTW, does this happen with Wayland, too?

I stumbled on the existing report:
  https://gitlab.freedesktop.org/xorg/driver/xf86-video-amdgpu/-/issues/68
and it says it's X who adds DoubleScan modes.
Comment 15 Stefan Dirsch 2023-07-06 13:14:53 UTC
Ok. But that would mean that Holger runs amdgpu X driver. Holger, have you installed xf86-video-amdgpu package. Could you attach your  X logfile,  please?
Comment 16 Stefan Dirsch 2023-07-06 13:16:57 UTC
If Holger really uses the amdgpu X driver and removing xf86-video-amdgpu packages fixes the issue, it's indeed the amdgpu driver.
Comment 17 Stefan Dirsch 2023-07-06 13:35:58 UTC
Sorry, it's reported against amdgpu X driver, but the issue is in X server. Not sure why this didn't happen yet on Leap 15.4. We still have xorg-server 1.20.3 there, whereas we have 21.1.4 on Leap 15.5, but I think we didn't see relevant changes to this aspect.
Comment 18 Takashi Iwai 2023-07-06 14:30:37 UTC
Also, I built a test kernel with a hackish patch to limit the doublescan for HDMI.  Could you try the kernel in OBS home:tiwai:bsc1212954 repo?
Comment 19 Holger Sickenberg 2023-08-17 09:24:25 UTC
Created attachment 868854 [details]
dmesg-5.14.21-150500.1.g08214d9-default.txt

Unfortunately, still same behavior with your test kernel
Comment 20 Takashi Iwai 2023-08-21 09:05:19 UTC
As the issue happens only with X amdgpu driver, I reassign now.
Please take back to kernel if it turned out to be a kernel problem.
Comment 21 Stefan Dirsch 2023-08-26 13:08:21 UTC
(In reply to Stefan Dirsch from comment #15)
> Ok. But that would mean that Holger runs amdgpu X driver. Holger, have you
> installed xf86-video-amdgpu package. Could you attach your  X logfile, 
> please?

Could you still check this, please? Thanks!
Comment 22 Holger Sickenberg 2023-09-25 15:12:51 UTC
No, package "xf86-video-amdgpu" is not installed:

holger@t14s:~> rpm -qa | grep -i amdgpu
kernel-firmware-amdgpu-20230724-150500.3.6.1.noarch
libdrm_amdgpu1-2.4.114-150500.3.2.x86_64
Comment 23 Stefan Dirsch 2023-09-25 18:37:50 UTC
Ok. So obviously it's not the amdgpu X driver. So either Xserver itself or amdgpu kernel driver. If it doesn't happen with Wayland we can safely assume it's the Xserver. Can you try this, Holger. Easiest would be to install gdm+GNOME and try with a GNOME session. Check what you're runnng with ...

# echo $XDG_SESSION_TYPE 
x11
Comment 24 Stefan Dirsch 2023-11-26 16:10:41 UTC
(In reply to Stefan Dirsch from comment #23)
> Ok. So obviously it's not the amdgpu X driver. So either Xserver itself or
> amdgpu kernel driver. If it doesn't happen with Wayland we can safely assume
> it's the Xserver. Can you try this, Holger. Easiest would be to install
> gdm+GNOME and try with a GNOME session. Check what you're runnng with ...
> 
> # echo $XDG_SESSION_TYPE 
> x11

Could you still try this, please?
Comment 25 Stefan Dirsch 2024-02-09 12:48:45 UTC
Any news on that one?
Comment 26 Holger Sickenberg 2024-02-16 13:15:53 UTC
Unfortunately enabling of Wayland did not work as expected, even using gdm.
Comment 27 Stefan Dirsch 2024-02-16 13:34:02 UTC
(In reply to Holger Sickenberg from comment #26)
> Unfortunately enabling of Wayland did not work as expected, even using gdm.

Yes, we don't know why. gdm/Gnome for some reasons the hardware isn't capable of handling a Wayland desktop.