Bug 96211 - unplugging hdmi from intel gpu doesn't redirect audio back to local speakers
Summary: unplugging hdmi from intel gpu doesn't redirect audio back to local speakers
Status: RESOLVED MOVED
Alias: None
Product: PulseAudio
Classification: Unclassified
Component: core (show other bugs)
Version: unspecified
Hardware: x86-64 (AMD64) Linux (All)
: medium normal
Assignee: pulseaudio-bugs
QA Contact: pulseaudio-bugs
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2016-05-25 12:47 UTC by Christian Hergert
Modified: 2018-07-30 10:03 UTC (History)
1 user (show)

See Also:
i915 platform:
i915 features:


Attachments
with audio directed to TV via HDMI (4.60 KB, text/plain)
2016-05-25 13:23 UTC, Christian Hergert
Details
with tv/hdmi disconnected but sound has not been redirected to local speakers (4.57 KB, text/plain)
2016-05-25 13:24 UTC, Christian Hergert
Details

Description Christian Hergert 2016-05-25 12:47:51 UTC
Setup:

  Lenovo Gen3 X1 Carbon w/ Intel GPU
  Audio redirected via HDMI to a samsung TV
  Both Wayland and Xorg sessions

I manually set the audio output to the HDMI output in GNOME control center. I thought it would remember my setting like it does for monitor layout, but that does not seem to happen. It sounds like is supposed to be handled by PulseAudio?

Likewise, when I remove the HDMI device, I would expect audio to be redirected back to my laptop speakers.

Is it correct that this should be handled by PulseAudio and not by something like gnome-settings-daemon/control-center?
Comment 1 Tanu Kaskinen 2016-05-25 12:56:26 UTC
What's the PulseAudio version?

What does "pactl list cards" show when you have the TV plugged in and directed audio to it, and what does it show after unplugging the TV? Close gnome-control-center when plugging out the cable - I've seen g-c-c interfering with the routing during unplug events.
Comment 2 Christian Hergert 2016-05-25 13:23:03 UTC
(In reply to Tanu Kaskinen from comment #1)
> What's the PulseAudio version?

From F24 - pulseaudio-8.0-6.fc24.x86_64

> What does "pactl list cards" show when you have the TV plugged in and
> directed audio to it, and what does it show after unplugging the TV?

I'll attach two versions. First is connected and sound directed to TV. Second is TV unplugged but before manually changing output back to laptop speakers.

> Close gnome-control-center when plugging out the cable - I've seen g-c-c
> interfering with the routing during unplug events.

I've seen this too. I think it has to do with GtkTreeViewSelection updating the "browse-mode" selection when displaying the sound settings.
Comment 3 Christian Hergert 2016-05-25 13:23:35 UTC
Created attachment 124083 [details]
with audio directed to TV via HDMI
Comment 4 Christian Hergert 2016-05-25 13:24:12 UTC
Created attachment 124084 [details]
with tv/hdmi disconnected but sound has not been redirected to local speakers
Comment 5 Tanu Kaskinen 2016-05-25 13:42:08 UTC
Ok, so HDMI is on a different alsa card than analog output. That explains why unplugging HDMI doesn't result in moving audio to the analog output. We don't currently automatically reroute from one card to another on an unplug event. This should be fixed, but I can't give any timeline.

You also had some issue with remembering routing choices. Is it so that if you route to HDMI and reboot, audio isn't routed to HDMI any more, even if the HDMI cable stays plugged in all the time?
Comment 6 Christian Hergert 2016-05-25 14:00:52 UTC
(In reply to Tanu Kaskinen from comment #5)
> You also had some issue with remembering routing choices. Is it so that if
> you route to HDMI and reboot, audio isn't routed to HDMI any more, even if
> the HDMI cable stays plugged in all the time?

I haven't tested that (and it's a bit hard for me to test right now).

My problem is that I unplug the HDMI, go work in another part of the house, and then come back and plug the HDMI back in. I would expect the audio/video to be redirected as a pair (even though they are separate sub-systems in implementation).
Comment 7 Raymond 2016-05-28 01:22:02 UTC
(In reply to Tanu Kaskinen from comment #5)
> Ok, so HDMI is on a different alsa card than analog output. That explains
> why unplugging HDMI doesn't result in moving audio to the analog output. We
> don't currently automatically reroute from one card to another on an unplug
> event. This should be fixed, but I can't give any timeline.

but there is no available HDMI ports available anymore , this mean that the only available port is the internal speaker as headphone is not plugged
Comment 8 Tanu Kaskinen 2016-05-28 11:07:05 UTC
(In reply to Raymond from comment #7)
> but there is no available HDMI ports available anymore , this mean that the
> only available port is the internal speaker as headphone is not plugged

Yes. What's the reason for stating this fact? If you had some point to make, I didn't catch that.
Comment 9 GitLab Migration User 2018-07-30 10:03:13 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/pulseaudio/pulseaudio/issues/185.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.