Bug 1212961

Summary: KDE 5.27.x and Newer Kernels Post Suspend/Sleep, After Resume Black Screen & Freezing Issue
Product: [openSUSE] openSUSE Distribution Reporter: Holy Gates <holygatestudio>
Component: KernelAssignee: openSUSE Kernel Bugs <kernel-bugs>
Status: RESOLVED FIXED QA Contact: E-mail List <qa-bugs>
Severity: Critical    
Priority: P5 - None CC: cgoll, holygatestudio, tiwai
Version: Leap 15.5   
Target Milestone: ---   
Hardware: x86-64   
OS: openSUSE Leap 15.5   
Whiteboard:
Found By: --- Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---
Attachments: Journactl log file after resume issue.
Var/Log Messages.
Var/Log Messages v2

Description Holy Gates 2023-07-03 20:39:48 UTC
OpenSUSE Leap 15.5 & TW with KDE 5.27.x version with higher version than 5.14.21-150400.24.66 kernel always produces after sleep-resume black screen / freezing.

Reproducible: Always

Steps to Reproduce:
1. Upgrade Leap 15.4 to 15.5 or TW with 5.14.21-150500.53 or newer+ kernel
2. Put system sleep/suspend
3. Do this almost 20+ sleep-resume cycle
4. Try resume
5. Black screen/freezing.


My Specs:

Machine: Laptop 
System: Acer product: Nitro AN515-44 v: V1.04
Desktop: KDE Plasma v: 5.27.4 Distro: openSUSE Leap 15.5

CPU:
  Info: 8-core model: AMD Ryzen 7 4800H with Radeon Graphics bits: 64
    type: MT MCP cache: L2: 4 MiB
  Speed (MHz): avg: 1463 min/max: 1400/2900 cores: 1: 1971 2: 2030 3: 1397
    4: 1397 5: 1397 6: 1397 7: 1391 8: 1397 9: 1392 10: 1397 11: 1399 12: 1390
    13: 1397 14: 1319 15: 1350 16: 1397

Graphics:
  Device-1: NVIDIA TU117M [GeForce GTX 1650 Ti Mobile] driver: nouveau
    v: kernel
  Device-2: AMD Renoir driver: amdgpu v: kernel
  Device-3: Quanta HD User Facing type: USB driver: uvcvideo
  Display: x11 server: X.Org v: 1.21.1.4 with: Xwayland v: 22.1.5 driver: X:
    loaded: amdgpu,modesetting,nouveau unloaded: fbdev,vesa dri: radeonsi,zink
    gpu: amdgpu resolution: 1920x1080
  API: OpenGL v: 4.6 Mesa 22.3.5 renderer: AMD Radeon Graphics (renoir LLVM
    15.0.7 DRM 3.42 5.14.21-150400.24.66-default)

I have installed NVIDIA drivers which also produced same issue, neither amd's integrated driver nor NVIDIA's one helped to solve it due to kernel's bug. Then I rollback to Leap 15.5 with lower kernel version which is 5.14.21-150400.24.66 working properly with KDE 5.27.4 but kernel 5.14.21-150400.24.66 black screen.

Moreover tried with other DEs as well, then same after resume issue occurred with kernel 5.14.21-150400.24.66 and higher ones. So it's not directly related to DE in my observations.

Tried;

- Deep sleep mode
- Nomodoset
- Disabling screen saver/lock
- Proprietary drivers / open drivers
- Other DEs and Wayland sessions
- Different display managers
- Many other advice on the web.

Nothing helped I'm using Leap 15.5 KDE Plasma 5.27.4 with kernel 5.14.21-150400.24.66 an no any after resume problems but cannot use update version of kernel.
Comment 1 Takashi Iwai 2023-07-04 06:00:38 UTC
Just to be sure: could you check the behavior with the kernel in OBS Kernel:SLE15-SP5 repo?

If the problem persists, please check with the kernel in OBS Kernel:stable:Backport.  This is a 6.4.x kernel built for Leap.
Comment 2 Christian Goll 2023-07-04 09:37:00 UTC
I am experiencing similar problems and I can test the backport kernel. But before I start, is the backport kernel signed or do I have to disable secure boot?
Comment 3 Takashi Iwai 2023-07-04 09:43:19 UTC
It's an unofficial build, so disable Secure Boot, yes.
All kernels in OBS Kernel:* or home:* are unofficial builds in general.

(To be more precise: it's signed with a downstream key. You may deploy the cert manually if you want, too.  Each OBS project has its own key, so each project may need a different cert.)
Comment 4 Holy Gates 2023-07-04 09:49:04 UTC
Tried both repos' kernels,

5.14.21-150500.143.1.g4919d63.x86_64
6.4.1-lp154.2.gb8cc951.x86_64

That also stuck and frozen-black screen after 21 times sleep-awake cycles.
Comment 5 Takashi Iwai 2023-07-04 09:51:19 UTC
If the problem is seen on 6.4.x kernel, it's something to be addressed in the upstream at first.

Do you get any kernel stack traces or such useful info for debugging?
Comment 6 Holy Gates 2023-07-04 10:48:36 UTC
I am not very familiar with this, can you give me an example of how I should do it?
Comment 7 Takashi Iwai 2023-07-04 10:59:30 UTC
Check the kernel log of the previous (crashing) boots, either via journalctl or /var/log/messages, depending on the setup.  Do you see any traces by a kernel crash / Oops?
Comment 8 Holy Gates 2023-07-04 11:44:04 UTC
Created attachment 867969 [details]
Journactl log file after resume issue.
Comment 9 Takashi Iwai 2023-07-05 06:43:04 UTC
Through a quick glance, there is no sign of crash in the log, unfortunately.

And, the screen-freezing is not only about the graphics, but also the whole kernel doesn't work?  For example, no remote access possible?
Comment 10 Holy Gates 2023-07-05 07:39:06 UTC
Created attachment 867988 [details]
Var/Log Messages.

When freezing/black screen occurs then nothing works even TTY options.
Comment 11 Takashi Iwai 2023-07-05 07:43:15 UTC
In the last log, we see lots of errors from nouveau.  Could you try to blacklist it and retest?
Comment 12 Holy Gates 2023-07-05 08:47:42 UTC
Created attachment 867990 [details]
Var/Log Messages v2

Strange cause I'd not have nouveau driver when I use TW but it has not work with new kernels too.

Tried after blacklisting nouveau and cycled sleep-awake resume, after 21+ cycles it once again frozen.

added last operation updated log message.

now I completely removed nouveau and taboo it, gonna retest sleep resume against that frustrating issue.
Comment 13 Takashi Iwai 2023-07-05 08:52:27 UTC
Did you enable nouveau via force_probe module option for Leap 15.5 kernel?
Leap 15.5 kernel has a downstream patch to disable nouveau for the recent chips, and I thought it should prevent it loaded.

In anyway, I see a few graphics related messages such as
  Fence fallback timer expired on ring gfx_low
which might be relevant.  But who knows...

There is another test kernel with the missing amdgpu fixes, and it's ready in OBS home:tiwai:bsc1212961 repo.  Could you give it a try?
Comment 14 Holy Gates 2023-07-05 09:33:11 UTC
I did not enable the module. After removal of nouveau still no chance for resume.

wanna try your test kernel but cannot install due to;

"No update candidate for 'kernel-default-5.14.21-150500.53.2.x86_64'. The highest available version is already installed."

rollback to leap kernel to switch from 6.4.x to 5.14 but still get this error.
Comment 15 Takashi Iwai 2023-07-05 09:55:44 UTC
For testing kernel packages, the easiest way would be to download kernel-default.rpm (and kernel-default-extra.rpm and kernel-default-optional.rpm for Leap), and install them with "zypper install".  You can pass --oldpackage option for installing the old kernels.

Also, I recommend to increase the number of installable kernels beforehand.
Edit /etc/zypp/zypp.conf, and add more entries to the line defining "multiversion.kernels", e.g.
  multiversion.kernels = latest,latest-1,latest-2,latest-3,running
Comment 16 Holy Gates 2023-07-05 11:20:19 UTC
Your test kernel worked without any suspend-sleep resume issue. I think you have fixed something on it. Tried several times more than 30+ sleep-awake cycles and no freezing, black screen but only sometimes in first seconds black screen to normal display. However this is not huge problem maybe related to my plasma theming.

Please let me know when I can use this fixing with official repo release? Also would like to try with TW's latest test kernel on yours fixing.

Thanks mate.
Comment 17 Takashi Iwai 2023-07-05 11:29:40 UTC
Good to hear!  I sent a PR to SLE15-SP5 git branch for inclusion, and hopefully it'll be included in the next maintenance update in July.

You can keep using my test kernel until the fix reaches to the official repo, of course.
Comment 18 Holy Gates 2023-07-05 12:01:43 UTC
Should I change bug's status to resolved > fixed or upstream?
Comment 19 Takashi Iwai 2023-07-05 12:07:34 UTC
Let me do that :)

BTW, it's not sure whether a maintenance update will happen in July.
Check the changelog and see whether the fixes referring this bug entry (bsc#1212961) appear.
Comment 20 Christian Goll 2023-07-05 12:25:00 UTC
I had no time try the new kernel, as I suspend and resume not that often.
Thanks to you both.
Comment 23 Maintenance Automation 2023-07-18 16:33:18 UTC
SUSE-SU-2023:2871-1: An update that solves 82 vulnerabilities, contains 25 features and has 390 fixes can now be installed.

Category: security (important)
Bug References: 1065729, 1109158, 1142685, 1152472, 1152489, 1155798, 1160435, 1166486, 1172073, 1174777, 1177529, 1186449, 1187829, 1189998, 1189999, 1191731, 1193629, 1194869, 1195175, 1195655, 1195921, 1196058, 1197534, 1197617, 1198101, 1198400, 1198438, 1198835, 1199304, 1199701, 1200054, 1202353, 1202633, 1203039, 1203200, 1203325, 1203331, 1203332, 1203693, 1203906, 1204356, 1204363, 1204662, 1204993, 1205153, 1205191, 1205205, 1205544, 1205650, 1205756, 1205758, 1205760, 1205762, 1205803, 1205846, 1206024, 1206036, 1206056, 1206057, 1206103, 1206224, 1206232, 1206340, 1206459, 1206492, 1206493, 1206552, 1206578, 1206640, 1206649, 1206677, 1206824, 1206843, 1206876, 1206877, 1206878, 1206880, 1206881, 1206882, 1206883, 1206884, 1206885, 1206886, 1206887, 1206888, 1206889, 1206890, 1206891, 1206893, 1206894, 1206935, 1206992, 1207034, 1207036, 1207050, 1207051, 1207088, 1207125, 1207149, 1207158, 1207168, 1207185, 1207270, 1207315, 1207328, 1207497, 1207500, 1207501, 1207506, 1207507, 1207521, 1207553, 1207560, 1207574, 1207588, 1207589, 1207590, 1207591, 1207592, 1207593, 1207594, 1207602, 1207603, 1207605, 1207606, 1207607, 1207608, 1207609, 1207610, 1207611, 1207612, 1207613, 1207614, 1207615, 1207616, 1207617, 1207618, 1207619, 1207620, 1207621, 1207622, 1207623, 1207624, 1207625, 1207626, 1207627, 1207628, 1207629, 1207630, 1207631, 1207632, 1207633, 1207634, 1207635, 1207636, 1207637, 1207638, 1207639, 1207640, 1207641, 1207642, 1207643, 1207644, 1207645, 1207646, 1207647, 1207648, 1207649, 1207650, 1207651, 1207652, 1207653, 1207734, 1207768, 1207769, 1207770, 1207771, 1207773, 1207795, 1207827, 1207842, 1207845, 1207875, 1207878, 1207933, 1207935, 1207948, 1208050, 1208076, 1208081, 1208105, 1208107, 1208128, 1208130, 1208149, 1208153, 1208183, 1208212, 1208219, 1208290, 1208368, 1208410, 1208420, 1208428, 1208429, 1208449, 1208534, 1208541, 1208542, 1208570, 1208588, 1208598, 1208599, 1208600, 1208601, 1208602, 1208604, 1208605, 1208607, 1208619, 1208628, 1208700, 1208741, 1208758, 1208759, 1208776, 1208777, 1208784, 1208787, 1208815, 1208816, 1208829, 1208837, 1208843, 1208845, 1208848, 1208864, 1208902, 1208948, 1208976, 1209008, 1209039, 1209052, 1209092, 1209159, 1209256, 1209258, 1209262, 1209287, 1209288, 1209290, 1209291, 1209292, 1209366, 1209367, 1209436, 1209457, 1209504, 1209532, 1209556, 1209600, 1209615, 1209635, 1209636, 1209637, 1209684, 1209687, 1209693, 1209739, 1209779, 1209780, 1209788, 1209798, 1209799, 1209804, 1209805, 1209856, 1209871, 1209927, 1209980, 1209982, 1209999, 1210034, 1210050, 1210158, 1210165, 1210202, 1210203, 1210206, 1210216, 1210230, 1210294, 1210301, 1210329, 1210335, 1210336, 1210337, 1210409, 1210439, 1210449, 1210450, 1210453, 1210454, 1210498, 1210506, 1210533, 1210551, 1210565, 1210584, 1210629, 1210644, 1210647, 1210725, 1210741, 1210762, 1210763, 1210764, 1210765, 1210766, 1210767, 1210768, 1210769, 1210770, 1210771, 1210775, 1210783, 1210791, 1210793, 1210806, 1210816, 1210817, 1210827, 1210853, 1210940, 1210943, 1210947, 1210953, 1210986, 1211014, 1211025, 1211037, 1211043, 1211044, 1211089, 1211105, 1211113, 1211131, 1211205, 1211263, 1211280, 1211281, 1211299, 1211346, 1211387, 1211400, 1211410, 1211414, 1211449, 1211465, 1211519, 1211564, 1211590, 1211592, 1211593, 1211595, 1211654, 1211686, 1211687, 1211688, 1211689, 1211690, 1211691, 1211692, 1211693, 1211714, 1211794, 1211796, 1211804, 1211807, 1211808, 1211820, 1211836, 1211847, 1211852, 1211855, 1211960, 1212051, 1212129, 1212154, 1212155, 1212158, 1212265, 1212350, 1212445, 1212448, 1212456, 1212494, 1212495, 1212504, 1212513, 1212540, 1212556, 1212561, 1212563, 1212564, 1212584, 1212592, 1212603, 1212605, 1212606, 1212619, 1212685, 1212701, 1212741, 1212835, 1212838, 1212842, 1212848, 1212861, 1212869, 1212892, 1212961, 1213010, 1213011, 1213012, 1213013, 1213014, 1213015, 1213016, 1213017, 1213018, 1213019, 1213020, 1213021, 1213024, 1213025, 1213032, 1213034, 1213035, 1213036, 1213037, 1213038, 1213039, 1213040, 1213041, 1213087, 1213088, 1213089, 1213090, 1213092, 1213093, 1213094, 1213095, 1213096, 1213098, 1213099, 1213100, 1213102, 1213103, 1213104, 1213105, 1213106, 1213107, 1213108, 1213109, 1213110, 1213111, 1213112, 1213113, 1213114, 1213116, 1213134
CVE References: CVE-2022-36280, CVE-2022-38096, CVE-2022-4269, CVE-2022-45884, CVE-2022-45885, CVE-2022-45886, CVE-2022-45887, CVE-2022-45919, CVE-2022-4744, CVE-2023-0045, CVE-2023-0122, CVE-2023-0179, CVE-2023-0394, CVE-2023-0461, CVE-2023-0469, CVE-2023-0590, CVE-2023-0597, CVE-2023-1075, CVE-2023-1076, CVE-2023-1077, CVE-2023-1079, CVE-2023-1095, CVE-2023-1118, CVE-2023-1249, CVE-2023-1382, CVE-2023-1513, CVE-2023-1582, CVE-2023-1583, CVE-2023-1611, CVE-2023-1637, CVE-2023-1652, CVE-2023-1670, CVE-2023-1829, CVE-2023-1838, CVE-2023-1855, CVE-2023-1989, CVE-2023-1998, CVE-2023-2002, CVE-2023-21102, CVE-2023-21106, CVE-2023-2124, CVE-2023-2156, CVE-2023-2162, CVE-2023-2176, CVE-2023-2235, CVE-2023-2269, CVE-2023-22998, CVE-2023-23000, CVE-2023-23001, CVE-2023-23004, CVE-2023-23006, CVE-2023-2430, CVE-2023-2483, CVE-2023-25012, CVE-2023-2513, CVE-2023-26545, CVE-2023-28327, CVE-2023-28410, CVE-2023-28464, CVE-2023-28866, CVE-2023-3006, CVE-2023-30456, CVE-2023-30772, CVE-2023-3090, CVE-2023-31084, CVE-2023-3111, CVE-2023-3141, CVE-2023-31436, CVE-2023-3161, CVE-2023-3212, CVE-2023-3220, CVE-2023-32233, CVE-2023-33288, CVE-2023-3357, CVE-2023-3358, CVE-2023-3389, CVE-2023-33951, CVE-2023-33952, CVE-2023-35788, CVE-2023-35823, CVE-2023-35828, CVE-2023-35829
Jira References: PED-1549, PED-3210, PED-3259, PED-3692, PED-370, PED-3750, PED-3759, PED-376, PED-3931, PED-4022, PED-835, SES-1880, SLE-18375, SLE-18377, SLE-18378, SLE-18379, SLE-18383, SLE-18384, SLE-18385, SLE-18978, SLE-18992, SLE-19001, SLE-19253, SLE-19255, SLE-19556
Sources used:
openSUSE Leap 15.5 (src): kernel-livepatch-SLE15-SP5_Update_1-1-150500.11.7.1, kernel-syms-5.14.21-150500.55.7.1, kernel-obs-qa-5.14.21-150500.55.7.1, kernel-obs-build-5.14.21-150500.55.7.1, kernel-source-5.14.21-150500.55.7.1, kernel-default-base-5.14.21-150500.55.7.1.150500.6.2.5
Basesystem Module 15-SP5 (src): kernel-source-5.14.21-150500.55.7.1, kernel-default-base-5.14.21-150500.55.7.1.150500.6.2.5
Development Tools Module 15-SP5 (src): kernel-source-5.14.21-150500.55.7.1, kernel-syms-5.14.21-150500.55.7.1, kernel-obs-build-5.14.21-150500.55.7.1
SUSE Linux Enterprise Live Patching 15-SP5 (src): kernel-livepatch-SLE15-SP5_Update_1-1-150500.11.7.1

NOTE: This line indicates an update has been released for the listed product(s). At times this might be only a partial fix. If you have questions please reach out to maintenance coordination.
Comment 25 Holy Gates 2023-07-19 19:11:43 UTC
Installed and working properly, flawlessly.

Thanks all.
Comment 26 Maintenance Automation 2023-07-19 20:35:00 UTC
SUSE-SU-2023:2892-1: An update that solves 15 vulnerabilities, contains one feature and has 85 fixes can now be installed.

Category: security (important)
Bug References: 1187829, 1189998, 1194869, 1205758, 1208410, 1209039, 1209780, 1210335, 1210565, 1210584, 1210853, 1211014, 1211346, 1211400, 1211410, 1211794, 1211852, 1212051, 1212265, 1212350, 1212405, 1212445, 1212448, 1212456, 1212494, 1212495, 1212504, 1212513, 1212540, 1212556, 1212561, 1212563, 1212564, 1212584, 1212592, 1212603, 1212605, 1212606, 1212619, 1212685, 1212701, 1212741, 1212835, 1212838, 1212842, 1212848, 1212861, 1212869, 1212892, 1212961, 1213010, 1213011, 1213012, 1213013, 1213014, 1213015, 1213016, 1213017, 1213018, 1213019, 1213020, 1213021, 1213024, 1213025, 1213032, 1213034, 1213035, 1213036, 1213037, 1213038, 1213039, 1213040, 1213041, 1213087, 1213088, 1213089, 1213090, 1213092, 1213093, 1213094, 1213095, 1213096, 1213098, 1213099, 1213100, 1213102, 1213103, 1213104, 1213105, 1213106, 1213107, 1213108, 1213109, 1213110, 1213111, 1213112, 1213113, 1213114, 1213116, 1213134
CVE References: CVE-2023-1249, CVE-2023-1829, CVE-2023-2430, CVE-2023-28866, CVE-2023-3090, CVE-2023-3111, CVE-2023-3212, CVE-2023-3220, CVE-2023-3357, CVE-2023-3358, CVE-2023-3389, CVE-2023-35788, CVE-2023-35823, CVE-2023-35828, CVE-2023-35829
Jira References: PED-3931
Sources used:
openSUSE Leap 15.5 (src): kernel-syms-azure-5.14.21-150500.33.6.1, kernel-source-azure-5.14.21-150500.33.6.1
Public Cloud Module 15-SP5 (src): kernel-syms-azure-5.14.21-150500.33.6.1, kernel-source-azure-5.14.21-150500.33.6.1

NOTE: This line indicates an update has been released for the listed product(s). At times this might be only a partial fix. If you have questions please reach out to maintenance coordination.
Comment 33 Maintenance Automation 2023-08-14 08:30:18 UTC
SUSE-SU-2023:3302-1: An update that solves 28 vulnerabilities, contains two features and has 115 fixes can now be installed.

Category: security (important)
Bug References: 1150305, 1187829, 1193629, 1194869, 1206418, 1207129, 1207894, 1207948, 1208788, 1210335, 1210565, 1210584, 1210627, 1210780, 1210825, 1210853, 1211014, 1211131, 1211243, 1211738, 1211811, 1211867, 1212051, 1212256, 1212265, 1212301, 1212445, 1212456, 1212502, 1212525, 1212603, 1212604, 1212685, 1212766, 1212835, 1212838, 1212842, 1212846, 1212848, 1212861, 1212869, 1212892, 1212901, 1212905, 1212961, 1213010, 1213011, 1213012, 1213013, 1213014, 1213015, 1213016, 1213017, 1213018, 1213019, 1213020, 1213021, 1213024, 1213025, 1213032, 1213034, 1213035, 1213036, 1213037, 1213038, 1213039, 1213040, 1213041, 1213059, 1213061, 1213087, 1213088, 1213089, 1213090, 1213092, 1213093, 1213094, 1213095, 1213096, 1213098, 1213099, 1213100, 1213102, 1213103, 1213104, 1213105, 1213106, 1213107, 1213108, 1213109, 1213110, 1213111, 1213112, 1213113, 1213114, 1213116, 1213134, 1213167, 1213205, 1213206, 1213226, 1213233, 1213245, 1213247, 1213252, 1213258, 1213259, 1213263, 1213264, 1213272, 1213286, 1213287, 1213304, 1213417, 1213493, 1213523, 1213524, 1213533, 1213543, 1213578, 1213585, 1213586, 1213588, 1213601, 1213620, 1213632, 1213653, 1213705, 1213713, 1213715, 1213747, 1213756, 1213759, 1213777, 1213810, 1213812, 1213856, 1213857, 1213863, 1213867, 1213870, 1213871, 1213872
CVE References: CVE-2022-40982, CVE-2023-0459, CVE-2023-1829, CVE-2023-20569, CVE-2023-20593, CVE-2023-21400, CVE-2023-2156, CVE-2023-2166, CVE-2023-2430, CVE-2023-2985, CVE-2023-3090, CVE-2023-31083, CVE-2023-3111, CVE-2023-3117, CVE-2023-31248, CVE-2023-3212, CVE-2023-3268, CVE-2023-3389, CVE-2023-3390, CVE-2023-35001, CVE-2023-3567, CVE-2023-3609, CVE-2023-3611, CVE-2023-3776, CVE-2023-3812, CVE-2023-38409, CVE-2023-3863, CVE-2023-4004
Jira References: PED-4718, PED-4758
Sources used:
openSUSE Leap 15.5 (src): kernel-livepatch-SLE15-SP5-RT_Update_3-1-150500.11.5.1, kernel-syms-rt-5.14.21-150500.13.11.1, kernel-source-rt-5.14.21-150500.13.11.1
SUSE Linux Enterprise Live Patching 15-SP5 (src): kernel-livepatch-SLE15-SP5-RT_Update_3-1-150500.11.5.1
SUSE Real Time Module 15-SP5 (src): kernel-syms-rt-5.14.21-150500.13.11.1, kernel-source-rt-5.14.21-150500.13.11.1

NOTE: This line indicates an update has been released for the listed product(s). At times this might be only a partial fix. If you have questions please reach out to maintenance coordination.