summaryrefslogtreecommitdiff
path: root/sound/soc/codecs/tlv320aic31xx.c
diff options
context:
space:
mode:
authorAndrew F. Davis <afd@ti.com>2017-11-29 11:13:54 -0600
committerMark Brown <broonie@kernel.org>2017-11-30 12:24:22 +0000
commita825f31f93281bbe7126b25801deb476d07aaf82 (patch)
treefa9cafb6ffa5fa96ffa607aae813c7cfce27dea2 /sound/soc/codecs/tlv320aic31xx.c
parentf00e0030bcbf49936d265330f6e0b8c739ad90c3 (diff)
ASoC: tlv320aic31xx: Use standard reset GPIO OF name
The correct DT property for specifying a GPIO used for reset is "reset-gpios", fix this here. [Retitled for accuracy -- broonie] Signed-off-by: Andrew F. Davis <afd@ti.com> Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/codecs/tlv320aic31xx.c')
-rw-r--r--sound/soc/codecs/tlv320aic31xx.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/sound/soc/codecs/tlv320aic31xx.c b/sound/soc/codecs/tlv320aic31xx.c
index e2862372c26e..4837f25b0760 100644
--- a/sound/soc/codecs/tlv320aic31xx.c
+++ b/sound/soc/codecs/tlv320aic31xx.c
@@ -1279,9 +1279,16 @@ static void aic31xx_pdata_from_of(struct aic31xx_priv *aic31xx)
aic31xx->pdata.micbias_vg = MICBIAS_2_0V;
}
- ret = of_get_named_gpio(np, "gpio-reset", 0);
- if (ret > 0)
+ ret = of_get_named_gpio(np, "reset-gpios", 0);
+ if (ret > 0) {
aic31xx->pdata.gpio_reset = ret;
+ } else {
+ ret = of_get_named_gpio(np, "gpio-reset", 0);
+ if (ret > 0) {
+ dev_warn(aic31xx->dev, "Using deprecated property \"gpio-reset\", please update your DT");
+ aic31xx->pdata.gpio_reset = ret;
+ }
+ }
}
#else /* CONFIG_OF */
static void aic31xx_pdata_from_of(struct aic31xx_priv *aic31xx)