[alsa-devel] [pulseaudio-discuss] [PATCH v0 07/20] Consider unknown availability in module-switch-on-port-available
Raymond Yau
superquad.vortex2 at gmail.com
Wed Aug 22 14:00:52 CEST 2012
2012-8-22 下午5:13 於 "David Henningsson" <david.henningsson at canonical.com> 寫道:
>
> On 08/22/2012 10:08 AM, Mikel Astiz wrote:
>>
>> From: Mikel Astiz <mikel.astiz at bmw-carit.de>
>>
>> A port with the availability state flag set to unknown should not be
>> considered an active port.
>> ---
>> src/modules/module-switch-on-port-available.c | 2 +-
>> 1 files changed, 1 insertions(+), 1 deletions(-)
>>
>> diff --git a/src/modules/module-switch-on-port-available.c
b/src/modules/module-switch-on-port-available.c
>> index 1da612d..8c16821 100644
>> --- a/src/modules/module-switch-on-port-available.c
>> +++ b/src/modules/module-switch-on-port-available.c
>> @@ -85,7 +85,7 @@ static pa_bool_t try_to_switch_profile(pa_card *card,
pa_device_port *port) {
>> PA_IDXSET_FOREACH(sink, card->sinks, state2) {
>> if (!sink->active_port)
>> continue;
>> - if (sink->active_port->available !=
PA_PORT_AVAILABLE_NO)
>> + if (sink->active_port->available ==
PA_PORT_AVAILABLE_YES)
>> found_active_port = TRUE;
>> }
>>
>>
>
> I think this will break the following use case (on a normal laptop) :
>
> Assume we plug in HDMI. With this patch we will get inconsistent
behaviour: if headphones are plugged in (available = yes), we won't switch
to HDMI, but if not (speakers are available = unknown), we will switch to
HDMI.
>
>
if you look at those bug reports of no sound for those on-board ac97 codecs
with ubuntu 12.04
https://bugs.launchpad.net/ubuntu/+source/alsa-driver/+bug/1033996
how does pulseaudio determine which controls are effective in the headphone
path and speaker path of those ac97 codecs ?
the analog-output-stereo profile for the line out jack is missing
( 0.056| 0.000) D: [pulseaudio] alsa-mixer.c: Removing path 'analog-output'
as it is a subset of 'analog-output-headphone
is there any solution for those snd-intel8x0 and those onboard ac97 codecs
with headphone playback volume control ( no ctljack control and no phantom
port)?
http://cgit.freedesktop.org/pulseaudio/pulseaudio/commit/src/modules/alsa/alsa-mixer.c?id=91b25005978d343a989c9485e226dc9a18a2fb28
http://git.freedesktop.org/pulseaudio/pulseaudio/commit/src/modules/alsa/alsa-mixer.c?id=5c832a5b8a2bc2ce7447eab10acaeed30cd3ed78
More information about the Alsa-devel
mailing list