[pulseaudio-discuss] When (un)docking PA does not switch output between speakers and out

Tanu Kaskinen tanu.kaskinen at linux.intel.com
Thu Apr 17 01:50:51 PDT 2014


On Wed, 2014-04-16 at 11:21 +0000, Lukas Zapletal wrote:
> Hello,
> 
> in Fedora 20 we have this %SUBJ% bug which is annoying. Before I start 
> digging I want to ask if you guys know if this has been fixed upstream.
> 
> https://bugzilla.redhat.com/show_bug.cgi?id=1034882
> 
> If so, I will backport this into F20 because this is driving me crazy.
> 
> If not, please point me on the code bits I should start to hack. Thanks.

In the Redhat bugzilla you mentioned that you switch between the
Speakers and Analog Output ports. Do you have any other ports available?
The amixer output[1] shows that there is a Headphone mixer element, so
I'd expect that you have a Headphones port available too. If you have a
Headphones port, does selecting it instead of Analog Output work?

The Analog Output port doesn't and will not have any jack detection
(it's sort of dummy fallback thing), so the solution shouldn't be to
enable the Analog Output port when you want to use the dock headphones
output. If you have a Headphones port and it works for the dock
heaphones output, then there's the question that does the jack detection
for the Headphones port work. I suppose the Headphones port jack
detection might only detect changes in the integrated headphone jack,
not in the dock headphone jack. Your alsa driver appears to provide jack
detection for both "Headphone" and "Dock Headphone". PulseAudio doesn't
use the latter. We should probably add a new port for dock headphones.

You can use "pactl list cards" to see what PulseAudio thinks is plugged
in. In the "Ports:" section of the output there's a list of all ports of
the card, and there's the availability information for each port. For
example:

    analog-output-headphones: Headphones (priority: 9000, latency offset: 0 usec, available)

That shows that headphones are plugged in ("available"). If PulseAudio
thought that the headphones are not plugged in, it would print "not
available". If the availability is not printed at all, then PulseAudio
doesn't know if the headphones are plugged in or not.

How come this worked on Fedora 19 then? Maybe the kernel did the
auto-switching, but in Fedora 20 the kernel leaves the switching to the
userspace.

[1] https://bugzilla.redhat.com/attachment.cgi?id=829357

-- 
Tanu



More information about the pulseaudio-discuss mailing list