Bug 491908 - Volume level reset to 100% after screen is turned off
Summary: Volume level reset to 100% after screen is turned off
Status: RESOLVED UPSTREAM
Alias: None
Product: plasma-pa
Classification: Plasma
Component: general (show other bugs)
Version: 6.1.2
Platform: Arch Linux Linux
: NOR normal
Target Milestone: ---
Assignee: Plasma Bugs List
URL:
Keywords: multiscreen, regression
Depends on:
Blocks:
 
Reported: 2024-08-19 15:56 UTC by Iyán M. V.
Modified: 2024-08-30 12:39 UTC (History)
5 users (show)

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Iyán M. V. 2024-08-19 15:56:58 UTC
SUMMARY

I think this is related to the already reported Bug 490017, but I open this one since there are two different issues so it's easy to track, although I suspect the underlying bug is causing both. I also found out a way to reliably reproduce the issue all the times.

The problem is that no matter what the volume is (it can be muted, 10%, etc.), after the screen is turned off (e.g., by pressing Esc after locking the screen), the volume after logging back in is always 100%.

This happens whenever my laptop is connected to an external screen or docking station.


STEPS TO REPRODUCE
1. Connect laptop to an external screen with HDMI/DP or via a docking station
2. Change volume to any desired value (or mute the HDMI/DP device)
3. Lock the screen (Super + L)
4. Press Esc (this turns off the screen)
5. Press Enter to wake up the screen
6. Log in and observe volume of HDMI/DP, which is now 100%

OBSERVED RESULT
Volume level not restored after screen turns off. This does not happen if session is locked, but screen never turns off (via Esc or after 1 minute by default). In addition, built-in laptop speakers are not visible (see Bug 490017).

EXPECTED RESULT
Volume level is restored independently if the screen turns off or not. Also, the built-in speaker should be listed, and the user could choose the audio output to be the built-in speaker rather than the external device.

SOFTWARE/OS VERSIONS
Operating System: Arch Linux 
KDE Plasma Version: 6.1.4
KDE Frameworks Version: 6.5.0
Qt Version: 6.7.2
Kernel Version: 6.10.5-arch1-1 (64-bit)
Graphics Platform: Wayland
Processors: 22 × Intel® Core™ Ultra 7 155H
Memory: 30.9 GiB of RAM
Graphics Processor: Mesa Intel® Arc
Manufacturer: LENOVO
Product Name: 21KDS00600
System Version: ThinkPad X1 Carbon Gen 12

ADDITIONAL INFORMATION
pipewire 1:1.2.2-2
wireplumber 0.5.5-1
Comment 1 TraceyC 2024-08-29 17:14:16 UTC
I am not able to reproduce this bug on
- Plasma 6.1.4 -  Laptop plugged into dock and connected to DP monitor
- git-master - Laptop connected to an HDMI monitor

Both systems have pipewire 1.2.3
Can you update pipewire on your system to 1.2.3 and see if you still experience the bug? Thanks!
Comment 2 Nate Graham 2024-08-29 19:46:15 UTC
Also cannot reproduce with PipeWire 1.0.7 and git master with a laptop plugged into a DP directly, or an HDMI monitor directly or via a USB-C dock.

 This is prooooobably going to to be a PulseAudio/PipeWire/Wireplumber bug like Bug 490017.
Comment 3 Harald Sitter 2024-08-30 00:52:02 UTC
Indeed sounds like something may be going wrong with pipewire's stream restoring. We don't really set volumes in reaction to anything but user input AFAIK.
Comment 4 Iyán M. V. 2024-08-30 12:39:05 UTC
Since I wrote the original issue, pipewire got updated in Arch Linux. Here are the current versions:

kpipewire 6.1.4-1
libpipewire 1:1.2.3-1
pipewire 1:1.2.3-1
pipewire-audio 1:1.2.3-1
pipewire-libcamera 1:1.2.3-1
pipewire-pulse 1:1.2.3-1
pipewire-session-manager 1:1.2.3-1
qemu-audio-pipewire 9.0.2-1
libwireplumber 0.5.5-1
wireplumber 0.5.5-1

I still observe the same issue, but yeah, probably not a KDE bug. I will close this since it is reported upstream. Hopefully it gets fixed soon.