[amdgpu] Screen flickers after waking up from suspend

Bug #1885363 reported by Benjamin Altpeter
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
linux (Ubuntu)
Fix Released
Undecided
Unassigned
xserver-xorg-video-amdgpu (Ubuntu)
Fix Released
Undecided
Unassigned

Bug Description

I upgraded my Ubuntu 20.04 system with a new graphics card a few days ago. Everything seems fine when running the system normally, however whenever I suspend the machine and then wake it back up, severe problems occur.
The first time, the machine froze completely. Switching to a different TTY didn't work anymore and the keyboard LEDs didn't respond to caps and num lock anymore, so I had to force shutdown. The second time, it came back OK but the screen has been flickering heavily since. Restarting Gnome and unplugging and plugging monitors back in hasn't helped.

Relevant specs:
CPU: AMD® Ryzen 9 3900x 12-core processor × 24
GPU: AMD® Radeon rx 5600 xt (MSI RADEON RX 5600 XT MECH OC)
Monitors: 1x Acer running at 3840x2160 60Hz, 2x Medion (showing up as "Messeltronik Dresden GmbH") both running at 1920x1080 60Hz.
Gnome: 3.36.2
X11
Apt doesn't report any updates.

The flickering is most pronounced on the Acer. On the Medions, it seems to only happen when something changes on the screen. I have tried to capture this on video: https://youtu.be/HWT1J76-x94

This bug seem quite similar to this one (https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1874588). I can also stop the flickering by switching the Acer to 1080p but when switching back to 4k, the problem reappears.

I hope that ubuntu-bug has included all the necessary details. Let me know if you need anything else.

Thank you very much for your help!

ProblemType: Bug
DistroRelease: Ubuntu 20.04
Package: xorg 1:7.7+19ubuntu14
ProcVersionSignature: Ubuntu 5.4.0-39.43-generic 5.4.41
Uname: Linux 5.4.0-39-generic x86_64
ApportVersion: 2.20.11-0ubuntu27.3
Architecture: amd64
BootLog: Error: [Errno 13] Permission denied: '/var/log/boot.log'
CasperMD5CheckResult: skip
CompizPlugins: No value set for `/apps/compiz-1/general/screen0/options/active_plugins'
CompositorRunning: None
CurrentDesktop: GNOME
Date: Sat Jun 27 10:44:32 2020
DistUpgraded: 2020-04-30 20:17:33,403 DEBUG Running PostInstallScript: './xorg_fix_proprietary.py'
DistroCodename: focal
DistroVariant: ubuntu
DkmsStatus:
 nvidia, 440.100, 5.4.0-37-generic, x86_64: installed
 nvidia, 440.100, 5.4.0-39-generic, x86_64: installed
ExtraDebuggingInterest: Yes
GraphicsCard:
 Advanced Micro Devices, Inc. [AMD/ATI] Navi 10 [Radeon RX 5600 OEM/5600 XT / 5700/5700 XT] [1002:731f] (rev ca) (prog-if 00 [VGA controller])
   Subsystem: Micro-Star International Co., Ltd. [MSI] Navi 10 [Radeon RX 5600 OEM/5600 XT / 5700/5700 XT] [1462:381e]
InstallationDate: Installed on 2019-03-26 (458 days ago)
InstallationMedia: Ubuntu 18.10 "Cosmic Cuttlefish" - Release amd64 (20181017.3)
MachineType: To Be Filled By O.E.M. To Be Filled By O.E.M.
ProcKernelCmdLine: BOOT_IMAGE=/boot/vmlinuz-5.4.0-39-generic root=/dev/mapper/ubuntu--vg-root ro quiet splash vt.handoff=7
SourcePackage: xorg
Symptom: display
UpgradeStatus: Upgraded to focal on 2020-04-30 (57 days ago)
dmi.bios.date: 04/08/2020
dmi.bios.vendor: American Megatrends Inc.
dmi.bios.version: P2.60
dmi.board.name: X570 Extreme4
dmi.board.vendor: ASRock
dmi.chassis.asset.tag: To Be Filled By O.E.M.
dmi.chassis.type: 3
dmi.chassis.vendor: To Be Filled By O.E.M.
dmi.chassis.version: To Be Filled By O.E.M.
dmi.modalias: dmi:bvnAmericanMegatrendsInc.:bvrP2.60:bd04/08/2020:svnToBeFilledByO.E.M.:pnToBeFilledByO.E.M.:pvrToBeFilledByO.E.M.:rvnASRock:rnX570Extreme4:rvr:cvnToBeFilledByO.E.M.:ct3:cvrToBeFilledByO.E.M.:
dmi.product.family: To Be Filled By O.E.M.
dmi.product.name: To Be Filled By O.E.M.
dmi.product.sku: To Be Filled By O.E.M.
dmi.product.version: To Be Filled By O.E.M.
dmi.sys.vendor: To Be Filled By O.E.M.
version.compiz: compiz N/A
version.libdrm2: libdrm2 2.4.101-2
version.libgl1-mesa-dri: libgl1-mesa-dri 20.0.4-2ubuntu1
version.libgl1-mesa-glx: libgl1-mesa-glx 20.0.4-2ubuntu1
version.xserver-xorg-core: xserver-xorg-core 2:1.20.8-2ubuntu2.1
version.xserver-xorg-input-evdev: xserver-xorg-input-evdev N/A
version.xserver-xorg-video-ati: xserver-xorg-video-ati 1:19.1.0-1
version.xserver-xorg-video-intel: xserver-xorg-video-intel 2:2.99.917+git20200226-1
version.xserver-xorg-video-nouveau: xserver-xorg-video-nouveau 1:1.0.16-1

Revision history for this message
Benjamin Altpeter (baltpeter) wrote :
Revision history for this message
Benjamin Altpeter (baltpeter) wrote :

Did some more testing:

* If I logout when the screen flickers, it also flickers in the login screen after logging out and also after logging back in.

* After a reboot (without logging in), the flickering disappears. After suspending from there and waking up, the flickering appears on the login screen.

* After another reboot (this time logging in), there is also no flickering.

* Booting from a live Fedora 32 USB, the flickering after suspend does *not* occur, even after multiple suspends.

* Booting from a live Ubuntu 20.04 USB, the flickering *does* occur after suspend.

tags: added: amdgpu
summary: - Screen flickers after waking up from suspend
+ [amdgpu] Screen flickers after waking up from suspend
affects: xorg (Ubuntu) → xserver-xorg-video-amdgpu (Ubuntu)
Revision history for this message
Ubuntu Kernel Bot (ubuntu-kernel-bot) wrote : Status changed to Confirmed

This change was made by a bot.

Changed in linux (Ubuntu):
status: New → Confirmed
Revision history for this message
Kai-Heng Feng (kaihengfeng) wrote :
Changed in linux (Ubuntu):
status: Confirmed → Incomplete
Revision history for this message
Benjamin Altpeter (baltpeter) wrote :

With the mainline kernel you linked, I get different behaviour:

Most of the time after suspending and waking up again, the system freezes completely (sometimes immediately to a black screen, sometimes I can see a second roll over on the clock before it freezes). In this frozen state, the mouse and keyboard don't work, nothing changes on the screen an I cannot switch to another TTY. Pressing capslock and numlock doesn't change the indicator LEDs on the keyboard.

Of the couple times I tried, the system woke up correctly two times. Those two times, everything worked normally and there was no flickering.

Revision history for this message
Kai-Heng Feng (kaihengfeng) wrote :

So the original issue was fixed by mainline kernel, but there's another issue on suspend/resume?
Can you please attach `journalctl -b -1 -k` on the next boot of failed suspend?

Revision history for this message
Benjamin Altpeter (baltpeter) wrote :

Of course, kernel log is attached below.

Revision history for this message
Kai-Heng Feng (kaihengfeng) wrote :

Ok, nothing gets collected. Can you please use crash kernel [1] to try to collect some log?

[1] https://wiki.ubuntu.com/Kernel/CrashdumpRecipe

Revision history for this message
Benjamin Altpeter (baltpeter) wrote :

Ok, I installed linux-crashdump and reproduced the problem. Afterwards, there was a /var/crash/202007160905/dump-incomplete file. Can I just upload that here or will that contain sensitive data?

Revision history for this message
Kai-Heng Feng (kaihengfeng) wrote :

Please file an upstream bug at
https://gitlab.freedesktop.org/drm/amd/issues

So no sensitive data exposed.

Revision history for this message
Benjamin Altpeter (baltpeter) wrote :

Just upgraded to Ubuntu 20.10. It seems like the issue is fixed with that version, so this can be closed.

Revision history for this message
Sebastien Bacher (seb128) wrote :

Thanks closing the bug now

Changed in xserver-xorg-video-amdgpu (Ubuntu):
status: New → Fix Released
Changed in linux (Ubuntu):
status: Incomplete → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.