All of lore.kernel.org
 help / color / mirror / Atom feed
* [RFE] Power down AC'97 when muted
@ 2004-12-22 19:41 Pierre Ossman
  2004-12-23 15:10 ` Takashi Iwai
  0 siblings, 1 reply; 4+ messages in thread
From: Pierre Ossman @ 2004-12-22 19:41 UTC (permalink / raw)
  To: alsa-devel

I have a request for a new feature in the AC97 driver (my card is an 
intel ICH4). I'd like to see the driver power off the AC97 part when the 
master volume is muted. Currently the power control has a seperate 
volume control that can be used.

The reason I want this is because my laptop has a LED indicating mute 
status. This is triggered by the power down function of the AC97 function.

Since the power is exposed through a volume control this could be done 
in user space, but that would me that every program that mutes the sound 
card would need special logic to see if the card has an "External 
amplifier" (as the channel is called). Therefore it seems much better to 
do this in the driver.

Another point is that Windows seems to have this behaviour (since the 
LED functions fine there in every application) so manufacturers rely on 
this (HP in my case).

I tried doing this myself by adding an extra call inside 
ac97_put_double() checking for changes to the master channel but I 
couldn't get it to work. I just got a faint flicker out of the LED. If 
people give me enough pointers I might be able to put together a patch 
for this.

Rgds
Pierre


-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now. 
http://productguide.itmanagersjournal.com/

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [RFE] Power down AC'97 when muted
  2004-12-22 19:41 [RFE] Power down AC'97 when muted Pierre Ossman
@ 2004-12-23 15:10 ` Takashi Iwai
  2004-12-23 18:56   ` Pierre Ossman
  0 siblings, 1 reply; 4+ messages in thread
From: Takashi Iwai @ 2004-12-23 15:10 UTC (permalink / raw)
  To: Pierre Ossman; +Cc: alsa-devel

At Wed, 22 Dec 2004 20:41:23 +0100,
Pierre Ossman wrote:
> 
> I have a request for a new feature in the AC97 driver (my card is an 
> intel ICH4). I'd like to see the driver power off the AC97 part when the 
> master volume is muted. Currently the power control has a seperate 
> volume control that can be used.
> 
> The reason I want this is because my laptop has a LED indicating mute 
> status. This is triggered by the power down function of the AC97 function.
> 
> Since the power is exposed through a volume control this could be done 
> in user space, but that would me that every program that mutes the sound 
> card would need special logic to see if the card has an "External 
> amplifier" (as the channel is called). Therefore it seems much better to 
> do this in the driver.
> 
> Another point is that Windows seems to have this behaviour (since the 
> LED functions fine there in every application) so manufacturers rely on 
> this (HP in my case).
> 
> I tried doing this myself by adding an extra call inside 
> ac97_put_double() checking for changes to the master channel but I 
> couldn't get it to work. I just got a faint flicker out of the LED. If 
> people give me enough pointers I might be able to put together a patch 
> for this.

It's BUG #667, right?
	https://bugtrack.alsa-project.org/alsa-bug/view.php?id=667

I uploaded a test patch there.  Please give it a try.



Takashi


-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now. 
http://productguide.itmanagersjournal.com/

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [RFE] Power down AC'97 when muted
  2004-12-23 15:10 ` Takashi Iwai
@ 2004-12-23 18:56   ` Pierre Ossman
  2004-12-27 14:05     ` Takashi Iwai
  0 siblings, 1 reply; 4+ messages in thread
From: Pierre Ossman @ 2004-12-23 18:56 UTC (permalink / raw)
  To: Takashi Iwai; +Cc: alsa-devel

Takashi Iwai wrote:

>
>It's BUG #667, right?
>	https://bugtrack.alsa-project.org/alsa-bug/view.php?id=667
>
>I uploaded a test patch there.  Please give it a try.
>
>  
>
Yup, seems to be the same thing. I tried the patch and got it working 
after a few tweaks:

* None of the parts applied cleanly. You had a strange path to 
ac97_codec.h and you also seemed to have a newer version of the driver 
than I had (2.6.9 here).
* My card had a different subsystem vendor that in the patch:
        {
                .vendor = 0x0e11,
                .device = 0x0860,
                .name = "HP/Compaq nx7010",
                .type = AC97_TUNE_MUTE_LED
        },
* The new function called set_single not set_double which caused all 
kinds of strange effects.

I also noted another "feature". The quirk seems to take some time to go 
into effect since the LED doesn't light up if the mute is enabled 
directly after the module is loaded (done by scripts in FC3 during 
module load).

Rgds
Pierre



-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now. 
http://productguide.itmanagersjournal.com/

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [RFE] Power down AC'97 when muted
  2004-12-23 18:56   ` Pierre Ossman
@ 2004-12-27 14:05     ` Takashi Iwai
  0 siblings, 0 replies; 4+ messages in thread
From: Takashi Iwai @ 2004-12-27 14:05 UTC (permalink / raw)
  To: Pierre Ossman; +Cc: alsa-devel

At Thu, 23 Dec 2004 19:56:57 +0100,
Pierre Ossman wrote:
> 
> Takashi Iwai wrote:
> 
> >
> >It's BUG #667, right?
> >	https://bugtrack.alsa-project.org/alsa-bug/view.php?id=667
> >
> >I uploaded a test patch there.  Please give it a try.
> >
> >  
> >
> Yup, seems to be the same thing. I tried the patch and got it working 
> after a few tweaks:
> 
> * None of the parts applied cleanly. You had a strange path to 
> ac97_codec.h and you also seemed to have a newer version of the driver 
> than I had (2.6.9 here).

It's to alsa-kernel tree.  It's not to the linux kernel tree.

> * My card had a different subsystem vendor that in the patch:
>         {
>                 .vendor = 0x0e11,
>                 .device = 0x0860,
>                 .name = "HP/Compaq nx7010",
>                 .type = AC97_TUNE_MUTE_LED
>         },

Added.

> * The new function called set_single not set_double which caused all 
> kinds of strange effects.
> 
> I also noted another "feature". The quirk seems to take some time to go 
> into effect since the LED doesn't light up if the mute is enabled 
> directly after the module is loaded (done by scripts in FC3 during 
> module load).

Fixed on CVS version.


Takashi


-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now. 
http://productguide.itmanagersjournal.com/

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2004-12-27 14:05 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-12-22 19:41 [RFE] Power down AC'97 when muted Pierre Ossman
2004-12-23 15:10 ` Takashi Iwai
2004-12-23 18:56   ` Pierre Ossman
2004-12-27 14:05     ` Takashi Iwai

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.