summaryrefslogtreecommitdiff
path: root/sound/soc/samsung
diff options
context:
space:
mode:
authorJaechul Lee <jcsing.lee@samsung.com>2017-09-06 04:04:15 +0300
committerMark Brown <broonie@kernel.org>2017-09-19 17:59:07 +0300
commit975b6a93088e83a41ba2f0dec2f086678fdb2a7a (patch)
tree5030a50627446ecbb8f961e860e2cce8b931b547 /sound/soc/samsung
parente8d93208905a9987c211f97a14a93f2776ab52e7 (diff)
downloadlinux-975b6a93088e83a41ba2f0dec2f086678fdb2a7a.tar.xz
ASoC: samsung: Fix invalid argument when devm_gpiod_get is called
devm_gpiod_get is called with GPIOF_OUT_INIT_LOW but the function doesn't allow the parameters. Unluckily, GPIOF_OUT_INIT_LOW is same value as GPIOD_ASIS and gpio direction isn't set properly. Muted stream comes up when I try recording some sounds on TM2. mic-bias gpiod state can't be changed because the gpiod is created with the invalid parameter. The gpio should be set GPIOD_OUT_HIGH. Fixes: 1bfbc260a5b4 ("ASoC: samsung: Add machine driver for Exynos5433 based TM2 board") Signed-off-by: Jaechul Lee <jcsing.lee@samsung.com> Reviewed-by: Krzysztof Kozlowski <krzk@kernel.org> Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/samsung')
-rw-r--r--sound/soc/samsung/tm2_wm5110.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/sound/soc/samsung/tm2_wm5110.c b/sound/soc/samsung/tm2_wm5110.c
index 710e2151141f..a55d18703fe7 100644
--- a/sound/soc/samsung/tm2_wm5110.c
+++ b/sound/soc/samsung/tm2_wm5110.c
@@ -439,8 +439,7 @@ static int tm2_probe(struct platform_device *pdev)
snd_soc_card_set_drvdata(card, priv);
card->dev = dev;
- priv->gpio_mic_bias = devm_gpiod_get(dev, "mic-bias",
- GPIOF_OUT_INIT_LOW);
+ priv->gpio_mic_bias = devm_gpiod_get(dev, "mic-bias", GPIOD_OUT_HIGH);
if (IS_ERR(priv->gpio_mic_bias)) {
dev_err(dev, "Failed to get mic bias gpio\n");
return PTR_ERR(priv->gpio_mic_bias);