Flickering desktop

Hello,

My system: Tumbleweed+KDE
Video card: RX560. HDMI connection.
My desktop flickers a lot with wayland.
With X11 everything is fine.

xrandr output:

Screen 0: minimum 320 x 200, current 1920 x 1080, maximum 16384 x 16384
DisplayPort-0 disconnected (normal left inverted right x axis y axis)
HDMI-A-0 connected primary 1920x1080+0+0 (normal left inverted right x axis y axis) 480mm x 270mm
   1920x1080     74.97*+  60.00    50.00    59.94  
   1680x1050     59.88  
   1400x1050     59.95  
   1600x900      60.00  
   1280x1024     75.02    60.02  
   1440x900      59.90  
   1280x800      59.91  
   1152x864      75.00  
   1280x720      60.00    50.00    59.94  
   1024x768      75.03    60.00  
   800x600       75.00    60.32  
   720x576       50.00  
   720x480       60.00    59.94  
   640x480       75.00    60.00    59.94  
   720x400       70.08  
DVI-D-0 disconnected (normal left inverted right x axis y axis)

Thank you.

PS. I do not think that is a hardware problem. Before I put this question on the forum I tried Fedora to be sure that is not a hardware issue. Fedora works.

On Wayland the mouse cursor is huge when is over the Desktop (Plasma). Over the Firefox screen it becomes normal.

Then stick to X11 for now, I’d say.

PS. I do not think that is a hardware problem.

No, but it’s likely a graphics driver problem.

Wayland uses GLES instead of OpenGL, and this might trigger problems that don’t appear in X11.

That’s one of the known problems in Plasma/Wayland. (I think a fix is pending for 5.14, a workaround should be to choose a specific size instead of “resolution dependent” in the cursor theme settings IIRC)
It is still not completely finished and has to be considered experimental to some degree.

Here’s a list of the most severe known problems:
https://community.kde.org/Plasma/Wayland_Showstoppers
And there’s also Plasma/5.12 Errata - KDE Community Wiki and Plasma/5.13 Errata - KDE Community Wiki

Thank you for the answer.
I have no choice but to stick with X11.

Tumbleweed+Gnome+Wayland= no problems at all.

Well, GNOME/gnome-shell is not KDE/Plasma, and GNOME’s compositor is not kwin.

They use different graphics features, and they even use different (custom) Wayland protocols for certain more advanced features.

I am aware of that.
I change my video card (nvidia > amd) because I was tired of nvidia’s problems. And I want to use wayland.
I think I will change my DE for a while (KDE > Gnome).
I want to say that I actually use both of them but for a while I will use more Gnome.:wink:

Thanks again for you answers.

Maybe playing with these environment variables may help?
https://community.kde.org/KWin/Environment_Variables

KWIN_COMPOSE and KWIN_OPENGL_INTERFACE in particular, although I think on Wayland the latter is irrelevant as only egl is supported anyway AFAIK.
I’d try setting KWIN_COMPOSE to Q (QPainter backend) and O2ES (OpenGL2 ES) at least.

Btw, what driver are you actually using?
Maybe that’s the difference between your Tumbleweed installation and the Fedora you tried. (although there likely are version differences in some of the involved components as well)

Sorry for the late reply.
I use amdgpu

/sbin/lspci -nnk |grep -A3 VGA
0a:00.0 VGA compatible controller [0300]: Advanced Micro Devices, Inc. [AMD/ATI] Baffin [Radeon RX 460/560D / Pro 450/455/460/560] [1002:67ef] (rev e5)
        Subsystem: Sapphire Technology Limited Device [1da2:e348]
        Kernel driver in use: amdgpu
        Kernel modules: amdgpu

I add to boot (vmlinuz)

amdgpu.dc=1 video=HDMI-A-1:1920x1080@60

Thanks for the answer. I really appreciate it.

Ok, I assume that means the amdcpu X driver as well?
You may try to uninstall xf86-video-amdgpu and use modesetting instead, maybe it improves things (or not).

Another option might be to try amdgpu-pro (the proprietary driver), but I can’t really help with that.

I add to boot (vmlinuz)

amdgpu.dc=1 video=HDMI-A-1:1920x1080@60

Have you tried without the amdgpu.dc=1 (or even amdgpu.dc=0)?
I do remember flickering problems caused by DC for some users in the past (on TW, when it became enabled by default).

I removed xf86-video-amdgpu. :bad:

I do not want any proprietary stuff after the problems with nvidia driver.

I read about it. I tried in the past amdgpu.dc=0 (kernel 4.16 and 4.17.1). I try it now (kernel 4.17.2). :bad:

Thank you.

PS: maybe also look at AMDGPU - ArchWiki .

In particular try this:

Screen artifacts and frequency problemIf you have screen artifacts when setting your screen frequency up to 120+Hz your “Memory Clock” and “GPU Clock” are certainly too low to handle the screen request.
A workaround [1]](https://bugs.freedesktop.org/show_bug.cgi?id=96868#c13) is saving high or low in /sys/class/drm/card0/device/power_dpm_force_performance_level.

Maybe that would help?

Thanks Wolfi. Again.:slight_smile:

When I have a problem first thing that I do is to read ArchWiki. I read it few days ago.
My refresh rate is maximum 75 Hz.
And about this solution I read that it is possible to raise GPU temp a lot. I do not want to.
After few days of testing:
KDE did not work;
Gnome+TW work with a minor problem - if the screen is locked, when I login, desktop begin to fliker;
Gnome+Fedora - no problems at all.
I think I will stick with Gnome (at least for a while) .

Well, I actually found this suggestion at Flickering with AMDGPU driver - #10 by razorskinned - Linux - Level1Techs Forums .
The person who referred to this later wrote:

I was actually having the issue with running a single monitor at 1440p60, I was only able to run it at 1080p and 50hz without flickering. By setting the power state of the RX 550 to stay at higher levels, I am now able to run 1440p at 60hz, on not just one monitor but three.

I.e. he experienced the problem with 60Hz already.
So it might be worth a try with 75Hz as well.

Keeping the power state at higher levels might indeed raise the GPU temp though.
Personally, I would at least try it to see if it would help. :wink:

I check it. It is set on performance level.

BTW, I think it is a kernel’s problem.
Like I said, TW+Gnome - after the screen is locked, when I login, screen begin to flicker.
Fedora did not have that problem with kernel 4.16. But, with kernel 4.17 - the same problem like TW+Gnome and 4.17.2.

That can easily be the case. A part of the driver is in the kernel, like with all other KMS drivers (radeon, intel, nouveau).

Fedora did not have that problem with kernel 4.16. But, with kernel 4.17 - the same problem like TW+Gnome and 4.17.2.

So it seems to be a regression in kernel 4.17.

There are some 4.16.x packages available in some home: repos on OBS which you could try to install to verify that.
Or maybe give kernel 4.18rc1 (available in Kernel:HEAD) a try…

If it’s fixed in 4.18, an openSUSE bug report may be a good idea, maybe they can backport the fix (although, maybe the release is not too far away anyway, I don’t know).

It is enough for me to find the reason why it does not work.
I will stay with Kernel 4.17.2 with 60 Hz not 75 Hz.
But I will try kernel 4.18 for a bug report.

You mean the flickering is gone with 60 Hz?
Then it might indeed be a problem with the power state level (or the dynamic switching thereof)

With Kernel 4.16.x it works with 75 Hz.

Sure, I think we already established that it seems to be a regression in kernel 4.17. :wink:

My question was if the flickering goes away with kernel 4.17 if you use 60 Hz for the display.