asoc: tegra: ALC5640 machine: fix GPIO_EXT_MIC_EN
Chandler Zhang [Mon, 27 Feb 2012 05:58:33 +0000 (13:58 +0800)]
Invert the gpio output because GPIO_EXT_MIC_EN is active low.

Bug 937914

Change-Id: Ifeccda092d7834dfdd39e3d1df616bda7bf516bc
Reviewed-on: http://git-master/r/86038
Reviewed-by: Liangchuan Mi <lmi@nvidia.com>
Tested-by: Chandler Zhang <chazhang@nvidia.com>
Reviewed-by: Johnny Qiu <joqiu@nvidia.com>
Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com>
Tested-by: Kerwin Wan <kerwinw@nvidia.com>

sound/soc/tegra/tegra_rt5640.c

index 2f1cee2..21264eb 100644 (file)
@@ -400,7 +400,7 @@ static int tegra_rt5640_event_ext_mic(struct snd_soc_dapm_widget *w,
                return 0;
 
        gpio_set_value_cansleep(pdata->gpio_ext_mic_en,
-                               SND_SOC_DAPM_EVENT_ON(event));
+                               !SND_SOC_DAPM_EVENT_ON(event));
 
        return 0;
 }