mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2025-11-07 13:30:03 -05:00
alsa: fix infinite loop with Intel HDMI LPE
The Intel HDMI LPE driver works in a peculiar way when the HDMI cable is not plugged in: any written audio is immediately discarded and underrun is reported. That resulted in an infinite loop, because PulseAudio tried to keep the buffer filled, which was futile since the written audio was immediately consumed/discarded. This patch adds special handling for the LPE driver: if the active port of the sink is unavailable, the sink suspends itself. A new suspend cause is added: PA_SUSPEND_UNAVAILABLE. BugLink: https://bugs.freedesktop.org/show_bug.cgi?id=100488
This commit is contained in:
parent
d9624e0382
commit
94fc586c01
4 changed files with 58 additions and 0 deletions
|
|
@ -364,6 +364,7 @@ int pa_alsa_set_mixer_rtpoll(struct pa_alsa_mixer_pdata *pd, snd_mixer_t *mixer,
|
|||
struct pa_alsa_port_data {
|
||||
pa_alsa_path *path;
|
||||
pa_alsa_setting *setting;
|
||||
bool suspend_when_unavailable;
|
||||
};
|
||||
|
||||
void pa_alsa_add_ports(void *sink_or_source_new_data, pa_alsa_path_set *ps, pa_card *card);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue