pipewire/spa/plugins/alsa
Masum Reza f76327e076 alsa: acp: don’t override user-selected port on availability changes
ACP was re-selecting the “best” port on every port availability event,
even when a port was already explicitly selected by the user. This
differs from PulseAudio’s behavior, where port switching decisions are
left to higher-level policy.

This caused issues on devices where Line Out (speakers) and Headphones
share the same analog interface: when headphones are plugged in, ACP
would immediately switch away from the user-selected Line Out, or end up
in a state where no sound is produced despite selecting speakers explicitly from
clients like pwvucontrol.

Fix this by only re-evaluating and switching ports when:
  - no active port is currently selected, or
  - the active port has become unavailable

This preserves manual user choices and prevents ACP from fighting client
port selections during route activation.

Additionally, adjust ALSA mixer paths to better separate Line Out and
Headphones behavior:
  - Disable Line Out controls in the headphones path
  - Add explicit Line Out and Auto-Mute Mode handling in the lineout path

Together, these changes align PipeWire’s behavior more closely with
PulseAudio and fix cases where selecting speakers while headphones are
plugged results in no audio output.

Signed-off-by: John Titor <masumrezarock100@gmail.com>
2026-04-16 10:45:01 +00:00
..
acp spa/plugins/alsa/acp/compat.h: p is already const do not recast 2026-03-17 03:17:15 +11:00
mixer alsa: acp: don’t override user-selected port on availability changes 2026-04-16 10:45:01 +00:00
90-pipewire-alsa.rules alsa-card-profiles: Add config for a couple of JBL gaming headsets 2026-01-22 15:35:05 +00:00
acp-tool.c spa/plugins: include <stdlib.h> for alloca() on non-linux 2026-03-12 09:21:40 +00:00
alsa-acp-device.c alsa: acp: don’t override user-selected port on availability changes 2026-04-16 10:45:01 +00:00
alsa-compress-offload-device.c spa: alsa: avoid potential uninitialized variable use 2024-09-18 19:54:13 +00:00
alsa-compress-offload-sink.c alsa-compress-offload-sink: Improve write_queued_output_buffers comments 2025-07-18 10:53:59 +02:00
alsa-pcm-device.c spa: alsa: avoid potential uninitialized variable use 2024-09-18 19:54:13 +00:00
alsa-pcm-sink.c spa: acp: get and emit UCM information for SplitPCM devices 2024-12-21 16:03:19 +02:00
alsa-pcm-source.c spa: acp: get and emit UCM information for SplitPCM devices 2024-12-21 16:03:19 +02:00
alsa-pcm.c alsa-pcm: set rate_match rate to 1.0 when not matching 2026-02-05 10:45:11 +01:00
alsa-pcm.h spa: alsa: actually set the channel map when use-chmap=true 2026-01-05 15:37:05 +00:00
alsa-seq-bridge.c alsa-seq: add : between client and port name 2026-04-15 11:20:18 +02:00
alsa-seq.c midi: don't convert Midi in nodes 2026-03-25 11:59:43 +01:00
alsa-seq.h midi: don't convert Midi in nodes 2026-03-25 11:59:43 +01:00
alsa-udev.c alsa-udev: Add wireless device status monitoring 2026-03-30 07:43:27 +00:00
alsa.c meson: fix build with missing libudev-devel 2024-02-06 11:49:40 +01:00
alsa.h spa: remove unnecessary indirection for some spa_log_topics 2023-10-06 13:08:24 +00:00
compress-offload-api-util.c alsa-compress-offload: Add device object and udev based autodetection 2023-09-02 08:28:22 +00:00
compress-offload-api-util.h alsa-compress-offload: Add device object and udev based autodetection 2023-09-02 08:28:22 +00:00
compress-offload-api.c alsa-compress-offload-sink: Remove unused variable 2025-07-18 10:53:52 +02:00
compress-offload-api.h alsa-compress-offload: Add device object and udev based autodetection 2023-09-02 08:28:22 +00:00
meson.build meson: fix build with missing libudev-devel 2024-02-06 11:49:40 +01:00
test-hw-params.c treewide: use SPDX tags to specify copyright information 2023-02-16 10:54:48 +00:00
test-timer.c fix compilation some more 2024-06-18 15:41:12 +02:00