ASoC: samsung: midas_wm1811: Fix error code in probe()
This accidentally returns success instead of -EINVAL.
Fixes: c91d0c2e19
("ASoC: samsung: midas_wm1811: Add GPIO-based headset jack detection")
Signed-off-by: Dan Carpenter <dan.carpenter@linaro.org>
Acked-by: Artur Weber <aweber.kernel@gmail.com>
Link: https://lore.kernel.org/r/01590109-cf27-404b-88ff-b42bb73ca1c6@moroto.mountain
Signed-off-by: Mark Brown <broonie@kernel.org>
This commit is contained in:
parent
c38082bf22
commit
5c33876a20
@ -623,7 +623,7 @@ static int midas_probe(struct platform_device *pdev)
|
|||||||
|
|
||||||
if (channel_type != IIO_VOLTAGE) {
|
if (channel_type != IIO_VOLTAGE) {
|
||||||
dev_err(dev, "ADC channel is not voltage\n");
|
dev_err(dev, "ADC channel is not voltage\n");
|
||||||
return ret;
|
return -EINVAL;
|
||||||
}
|
}
|
||||||
|
|
||||||
priv->gpio_headset_key = devm_gpiod_get(dev, "headset-key",
|
priv->gpio_headset_key = devm_gpiod_get(dev, "headset-key",
|
||||||
|
Loading…
Reference in New Issue
Block a user