summaryrefslogtreecommitdiff
path: root/sound/soc/tegra/tegra_rt5639.c
diff options
context:
space:
mode:
authorJohnny Qiu <joqiu@nvidia.com>2013-07-06 00:02:20 -0700
committerDan Willemsen <dwillemsen@nvidia.com>2013-09-14 13:30:39 -0700
commite74705f9abcb83acb1800e359a2c047dcc4a00a0 (patch)
treead3a325d4f38a7885b4817c2ecb8efd5ee0a8e0a /sound/soc/tegra/tegra_rt5639.c
parentee6f974b2b37e560899cff3aa7dfd74acaa4ead0 (diff)
asoc: tegra: rt5639/rt5645: add hp_det polarity
Change-Id: Ieac78ab76320c7d0161f351375e577afe063a95c Signed-off-by: Johnny Qiu <joqiu@nvidia.com> Reviewed-on: http://git-master/r/245782 Reviewed-by: Nikesh Oswal <noswal@nvidia.com> Tested-by: Nikesh Oswal <noswal@nvidia.com>
Diffstat (limited to 'sound/soc/tegra/tegra_rt5639.c')
-rw-r--r--sound/soc/tegra/tegra_rt5639.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/sound/soc/tegra/tegra_rt5639.c b/sound/soc/tegra/tegra_rt5639.c
index 22be59bcc6b9..305dae7993d1 100644
--- a/sound/soc/tegra/tegra_rt5639.c
+++ b/sound/soc/tegra/tegra_rt5639.c
@@ -403,7 +403,6 @@ static struct snd_soc_jack_gpio tegra_rt5639_hp_jack_gpio = {
.name = "headphone detect",
.report = SND_JACK_HEADPHONE,
.debounce_time = 150,
- .invert = 1,
};
#ifdef CONFIG_SWITCH
@@ -621,6 +620,8 @@ static int tegra_rt5639_init(struct snd_soc_pcm_runtime *rtd)
if (gpio_is_valid(pdata->gpio_hp_det)) {
tegra_rt5639_hp_jack_gpio.gpio = pdata->gpio_hp_det;
+ tegra_rt5639_hp_jack_gpio.invert =
+ !pdata->gpio_hp_det_active_high;
snd_soc_jack_new(codec, "Headphone Jack", SND_JACK_HEADPHONE,
&tegra_rt5639_hp_jack);
#ifndef CONFIG_SWITCH