[alsa-devel] Mute LED on HP Pavilion DV7-1160eg

Thoralf Freitag thoralf.freitag at cactus-online.de
Sat May 1 22:19:14 CEST 2010


I tried to find a way for switching/control Mute LED on an HP DV 7
notebook. I found a solution which is very ugly. According the solution
described here
(http://mailman.alsa-project.org/pipermail/alsa-devel/2009-April/016126.html)
I changed the value for LED control in this manner:

diff -u alsa-driver-1.0.23/sound/pci/hda/patch_sigmatel.c
alsa-driver-1.0.23_b/sound/pci/hda/patch_sigmatel.c
--- alsa-driver-1.0.23/sound/pci/hda/patch_sigmatel.c    2010-04-16
13:10:10.000000000 +0200
+++ alsa-driver-1.0.23_b/sound/pci/hda/patch_sigmatel.c    2010-05-01
21:37:36.719063655 +0200
@@ -4952,9 +4952,9 @@
         }
     }
     if (muted)
-        spec->gpio_data &= ~spec->gpio_led; /* orange */
+        spec->gpio_data &= ~0x01; /* orange */
     else
-        spec->gpio_data |= spec->gpio_led; /* white */
+        spec->gpio_data |= 0x01; /* white */
 
     if (!spec->gpio_led_polarity) {
         /* LED state is inverted on these systems */

I hate this solution. Maybe someone of the programming experts could
give me a way to make it better. On which position should I make which
changes ?

Thanx for your guidance.

Thoralf



More information about the Alsa-devel mailing list