Bug 202873 - (amdgpu) Screen flickering when using a 75Hz monitor paired with an RX 480 GPU
Summary: (amdgpu) Screen flickering when using a 75Hz monitor paired with an RX 480 GPU
Status: NEW
Alias: None
Product: Drivers
Classification: Unclassified
Component: Video(DRI - non Intel) (show other bugs)
Hardware: Intel Linux
: P1 high
Assignee: drivers_video-dri
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-03-11 16:36 UTC by Maksim Ivanov
Modified: 2019-05-08 10:30 UTC (History)
2 users (show)

See Also:
Kernel Version: 4.18, 4.19, 4.20, 5.0
Subsystem:
Regression: No
Bisected commit-id:


Attachments

Description Maksim Ivanov 2019-03-11 16:36:17 UTC
My monitor is LG 24MP59G-P (75Hz, FreeSync) and my GPU is Sapphire Nitro+ RX 480 8GB.

Basically, whenever there is movement on my screen (oddly though, cursor movement doesn't cause it), it would flicker very badly. 

Here is a video of what I am talking about: https://streamable.com/5eu7p

Apart from trying different refresh rates, as seen in the video, I have also tried switching kernel versions, switching from DisplayPort to HDMI, changing compositor settings and turning off FreeSync from the monitor OSD, but nothing seems to resolve the bug.

What works for me as a workaround is changing /sys/class/drm/card0/device/power_dpm_force_performance_level from auto to either low or high. When I do watch -n 1 "/sys/class/drm/card0/device/pp_dpm_mclk" with the performance level on auto, it normally stays on the lowest (300MHz) and when I move a window around, it constantly switches from 300MHz to 2000MHz (the max on my GPU). Apparently, that's what's causing it to behave this way.

I should emphasize, that I observed the bug in Antergos, Debian 9 Buster (Stretch is good), Manjaro XFCE, Manjaro KDE, Ubuntu 18.10, KUbuntu 18.04 and KUbuntu 18.10. At first I thought it was only related to Arch Linux derivatives, since they all use bleeding-edge packages, but then I noticed, that after switching Debian 9 Stretch's (stable) sources to Buster (testing) and after updating KUbuntu 18.10, the bug appeared in both distros as well.

Here is a link to a thread I created in the Manjaro forums, where I asked for help: https://forum.manjaro.org/t/manjaro-kde-screen-flickering-cant-seem-to-find-a-solution/78349 - You can find all kinds of different things I tried there, as well as more in-depth system information.
Comment 1 Thomas 2019-03-29 12:45:48 UTC
I think I have the same error but just to get sure: What kernel version are you using? Just asking because 5.0.4 flickers for me while 4.18.12 doesn't. Sadly I can't bisect as kernels between these two versions won't boot for me cause of other bugs.

A bit info about my setup:
Sapphire Nitro+ Radeon RX 580 - "Advanced Micro Devices, Inc. [AMD/ATI] Ellesmere [Radeon RX 470/480/570/570X/580/580X] (rev e7)"
Gentoo Linux (amd64)
Mesa 18.3.4
LXQT
amdgpu.ppfeaturemask=0xffffffff amdgpu.dc=1 amdgpu.gpu_recovery=1


If this is the same bug and if you have a working kernel (4.18.12 maybe?) could you please bisect this? Also maybe compare the kernel versions of working and none-working distros? ;)
Comment 2 Thomas 2019-03-29 12:51:30 UTC
One more thing: I'm connected to a 60Hz monitor which AFAIK has no FreeSync support (Dell ST2220M).
Comment 3 Thomas 2019-03-29 13:06:44 UTC
Now I just realized that I have a second display (TV - Samsung UE40H5090 - AFAIK also no FreeSync) attached and turned it on to see what happens: Both displays flicker. If I disable the second screen in LXQTs settings the flickering stops and all is fine.
Comment 4 Thomas 2019-04-06 06:36:29 UTC
Kernel 5.0.5 still flickers. Anyway, after watching this more closely I'm pretty sure it's the same bug (the text cursor for entering username/password causes flickering on SDDM, for example). Still it seems to be fixed by deactivating the second monitor.
Comment 5 Thomas 2019-05-06 06:33:06 UTC
I got an X.org and SDDM update and now the PC freezes with a black screen while starting X if the second monitor is attached.
Comment 6 Haxk20 2019-05-08 10:27:05 UTC
Could you try Kernel 5.1 ?
It has a fix for flickering when Freesync is enabled.
Comment 7 Haxk20 2019-05-08 10:30:59 UTC
Ah sorry this is the old bug where clocks cause flickering. But still try 5.1. Maybe it will help.

Note You need to log in before you can comment on or make changes to this bug.