pipewire/spa/plugins/alsa/acp
Daniel Nouri 571ff40704 alsa: Fix IEC958 digital output not unmuted on path activation
When selecting an HDMI/DisplayPort (IEC958) output path, the hardware
mute switch remains in kernel default state (muted), causing no audio
output despite correct software routing.

Root cause: pa_alsa_path_select() only sets mute switches when
mute_during_activation is enabled. No mixer paths enable this setting,
making the switch configuration code unreachable for IEC958 paths.

Solution: Always set mute switches to match device mute status after
path activation, regardless of mute_during_activation setting.

Testing: Added test-alsa-path-select tool to verify the fix.
- Loads mixer path and calls pa_alsa_path_select()
- Verifies switch states match expected values
- Tested on AMD Radeon HDMI and Realtek ALC257 analog

Manual verification:
- Before: IEC958 switch OFF, no audio
- After: IEC958 switch set correctly, audio works

This bug was inherited from PulseAudio's ALSA mixer path code where
HDMI path configurations lack IEC958 unmute sections.

Fixes: https://gitlab.freedesktop.org/pipewire/pipewire/-/issues/3261
See-Also: https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/issues/562
See-Also: 33be660e4b
See-Also: https://bugs.launchpad.net/hundredpapercuts/+bug/681996
2025-10-07 17:21:05 +02:00
..
acp.c alsa: force IRQ scheduling for firewire in pro-audio profile 2025-09-07 18:23:31 +00:00
acp.h *: don't include standard C headers inside of extern "C" 2025-05-30 09:48:28 +01:00
alsa-mixer.c alsa: Fix IEC958 digital output not unmuted on path activation 2025-10-07 17:21:05 +02:00
alsa-mixer.h spa: acp: Allow Volume control which supports mute to be used as a hardware mute 2025-05-05 07:40:29 +00:00
alsa-ucm.c spa: alsa: fix some coverity warnings 2025-06-14 14:38:26 +03:00
alsa-ucm.h spa: acp: indicate ALSA UCM profile errors in UIs 2025-03-13 21:25:55 +00:00
alsa-util.c spa: alsa: autodetect supported iec958 codecs via ELD info 2024-11-28 09:18:07 +01:00
alsa-util.h spa: alsa: autodetect supported iec958 codecs via ELD info 2024-11-28 09:18:07 +01:00
array.h *: don't include standard C headers inside of extern "C" 2025-05-30 09:48:28 +01:00
card.h alsa: add option to disable pro-audio profiles 2025-07-02 08:11:48 -04:00
channelmap.h *: don't include standard C headers inside of extern "C" 2025-05-30 09:48:28 +01:00
compat.c *: unify config.h handling 2025-05-30 10:24:13 +00:00
compat.h spa: alsa: fix some coverity warnings 2025-06-14 14:38:26 +03:00
conf-parser.c config.h is a local header, not a system one 2021-06-10 09:04:16 +10:00
conf-parser.h alsa-acp: Add libacp based card device 2020-07-06 12:20:09 +02:00
device-port.h *: don't include standard C headers inside of extern "C" 2025-05-30 09:48:28 +01:00
dynarray.h *: don't include standard C headers inside of extern "C" 2025-05-30 09:48:28 +01:00
hashmap.h *: don't include standard C headers inside of extern "C" 2025-05-30 09:48:28 +01:00
idxset.h *: don't include standard C headers inside of extern "C" 2025-05-30 09:48:28 +01:00
llist.h alsa-acp: Add libacp based card device 2020-07-06 12:20:09 +02:00
meson.build alsa: Fix IEC958 digital output not unmuted on path activation 2025-10-07 17:21:05 +02:00
proplist.h *: don't include standard C headers inside of extern "C" 2025-05-30 09:48:28 +01:00
test-alsa-path-select.c alsa: Fix IEC958 digital output not unmuted on path activation 2025-10-07 17:21:05 +02:00
volume.h *: don't include standard C headers inside of extern "C" 2025-05-30 09:48:28 +01:00