--- kernel26.orig/sound/soc/pxa/beetles.c	2008-03-16 03:56:17.000000000 +0100
+++ kernel26/sound/soc/pxa/beetles.c	2008-03-16 23:57:15.000000000 +0100
@@ -319,14 +319,16 @@
 static int htcbeetles_spk_power(struct snd_soc_dapm_widget *w, int event)
 {
 	asic3_set_gpio_out_a(&htcsable_asic3.dev, 1<<GPIOA_SPKMIC_PWR2_ON,
-				1<<GPIOA_SPKMIC_PWR2_ON);
+				SND_SOC_DAPM_EVENT_ON(event) ?
+				1<<GPIOA_SPKMIC_PWR2_ON : 0);
 	return 0;
 }
 
 static int htcbeetles_hp_power(struct snd_soc_dapm_widget *w, int event)
 {
 	asic3_set_gpio_out_a(&htcsable_asic3.dev, 1<<GPIOA_HEADPHONE_PWR_ON,
-				1<<GPIOA_HEADPHONE_PWR_ON);
+				SND_SOC_DAPM_EVENT_ON(event) ?
+				1<<GPIOA_HEADPHONE_PWR_ON : 0);
 	return 0;
 }
 

