Bug 467767 - [nvidia,wayland] Messing with night light freezes the screen
Summary: [nvidia,wayland] Messing with night light freezes the screen
Status: RESOLVED UPSTREAM
Alias: None
Product: kwin
Classification: Plasma
Component: general (other bugs)
Version First Reported In: 5.27.3
Platform: Gentoo Packages Linux
: NOR normal
Target Milestone: ---
Assignee: KWin default assignee
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-03-24 22:04 UTC by Arsen Arsenović
Modified: 2024-04-25 14:33 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed/Implemented In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Arsen Arsenović 2023-03-24 22:04:11 UTC
SUMMARY
I've first noticed something is awry a few days ago, when Plasma stopped being able to re-enable the screen after turning it off via DPMS (saying 'kwin_wayland_drm: Setting dpms mode failed!' - I am decently sure this is a known issue).
This seemed to have gone away after a bit (and an update), but some of the problem remains - namely, if I left the screen off when going outside around noon, despite screens being able to wake up before that,  when I returned, I'd found that the screens are unable to reenable with the same log being printed.
Shortly after, I had backported kwin!3868 as it seemed related (the jury is still out on whether this helps in the "screen is off" case), and the thread referenced in that PR piqued my interest with regards to the Night Color.
As a result, I toggled night color in the settings, to find that my screen frozen (but enabled).

I will remove the patch and re-test momentarily (apologies for the delay).

Running 'qdbus org.kde.NightColor /ColorCorrect org.kde.kwin.ColorCorrect.inhibit' recovers the screen.

STEPS TO REPRODUCE
1. Open Night Color settings,
2. Toggle it's active state (i.e. go from always on/on at set times -> always off or vice versa),
3. Hit apply

OBSERVED RESULT
Screen freezes.

EXPECTED RESULT
Screen does nothing (since I don't think this feature works on Nvidia devices at all, if it does, then the expected result is an oranger screen :-).

SOFTWARE/OS VERSIONS
Operating System: Gentoo GNU/Linux 2.13
KDE Plasma Version: 5.27.3
KDE Frameworks Version: 5.104.0
Qt Version: 5.15.8
Kernel Version: 6.1.13-gentoo-dist-hardened (64-bit)
Graphics Platform: Wayland
Processors: 16 × AMD Ryzen 7 3800X 8-Core Processor
Memory: 62.7 GiB of RAM
Graphics Processor: NVIDIA GeForce GTX 1050 Ti/PCIe/SSE2
Manufacturer: Gigabyte Technology Co., Ltd.
Product Name: B550M DS3H

ADDITIONAL INFORMATION
The build I'm currently running has https://invent.kde.org/plasma/kwin/-/merge_requests/3868 backported into it.
As I have a feeling Nvidia is probably integral here, I currently have x11-drivers/nvidia-drivers-525.89.02 installed.
Comment 1 Arsen Arsenović 2023-03-24 23:37:02 UTC
OK, I've tested without the patch - the problem seems to not be introduced by it.

Though, it has come to my attention that my original reproduction steps are incomplete!  Here are the new ones:

1. Lock the desktop,
2. Let it go into inactivity and turn off the screen,
3. Unlock the desktop,
4. Open Night Color settings,
5. Toggle it's active state (i.e. go from always on/on at set times -> always off or vice versa),
6. Hit apply
Comment 2 Arsen Arsenović 2023-03-24 23:39:45 UTC
Oh, sorry - I missed one more observation: the key only freezes for the duration of the transitional period (which might be quite long if you're currently in magic hour), so if you toggle from Always On to Always Off or vice versa, you get a brief freeze of a few seconds with the usual...

Mar 25 00:32:25 bstg kwin_wayland[275491]: kwin_wayland_drm: Failed to create gamma blob! Invalid argument
Mar 25 00:32:25 bstg kwin_wayland[275491]: kwin_wayland_drm: Failed to create gamma blob! Invalid argument

... spam in logs.
Comment 3 Nate Graham 2023-04-04 22:32:56 UTC
I believe this should be fixed with Plasma 5.27.4. Can you re-test?
Comment 4 Arsen Arsenović 2023-04-06 19:53:08 UTC
I can still reproduce this with 5.27.4 and x11-drivers/nvidia-drivers-530.41.03, per steps in #c1.

Operating System: Gentoo GNU/Linux 2.13
KDE Plasma Version: 5.27.4
KDE Frameworks Version: 5.104.0
Qt Version: 5.15.8
Kernel Version: 6.1.22-gentoo-dist-hardened (64-bit)
Graphics Platform: Wayland
Processors: 16 × AMD Ryzen 7 3800X 8-Core Processor
Memory: 62.7 GiB of RAM
Graphics Processor: NVIDIA GeForce GTX 1050 Ti/PCIe/SSE2
Manufacturer: Gigabyte Technology Co., Ltd.
Product Name: B550M DS3H
Comment 5 Bug Janitor Service 2023-04-21 03:45:48 UTC
Dear Bug Submitter,

This bug has been in NEEDSINFO status with no change for at least
15 days. Please provide the requested information as soon as
possible and set the bug status as REPORTED. Due to regular bug
tracker maintenance, if the bug is still in NEEDSINFO status with
no change in 30 days the bug will be closed as RESOLVED > WORKSFORME
due to lack of needed information.

For more information about our bug triaging procedures please read the
wiki located here:
https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

If you have already provided the requested information, please
mark the bug as REPORTED so that the KDE team knows that the bug is
ready to be confirmed.

Thank you for helping us make KDE software even better for everyone!
Comment 6 Arsen Arsenović 2023-04-24 14:47:09 UTC
Ah - sorry about not marking the bug as reported again.

I've gotten a chance to re-test, and I could still reproduce the issue.

Operating System: Gentoo GNU/Linux 2.13
KDE Plasma Version: 5.27.4
KDE Frameworks Version: 5.105.0
Qt Version: 5.15.9
Kernel Version: 6.1.22-gentoo-dist-hardened (64-bit)
Graphics Platform: Wayland
Processors: 16 × AMD Ryzen 7 3800X 8-Core Processor
Memory: 62.7 GiB of RAM
Graphics Processor: NVIDIA GeForce GTX 1050 Ti/PCIe/SSE2
Manufacturer: Gigabyte Technology Co., Ltd.
Product Name: B550M DS3H
Comment 7 David Edmundson 2024-04-25 14:33:05 UTC
Driver issue