diff options
author | Lucas Stach <l.stach@pengutronix.de> | 2019-07-19 16:36:37 +0200 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2019-10-05 13:09:33 +0200 |
commit | a7ace049bddc64ae74668d1b1cc10dbcd6ade448 (patch) | |
tree | 5c2960a8a188329ed97263adcf7aab54dd49b4b6 /sound | |
parent | 3657e58405fb4b23646e683b3c06f5a47408754c (diff) | |
download | linux-stable-a7ace049bddc64ae74668d1b1cc10dbcd6ade448.tar.gz linux-stable-a7ace049bddc64ae74668d1b1cc10dbcd6ade448.tar.bz2 linux-stable-a7ace049bddc64ae74668d1b1cc10dbcd6ade448.zip |
ASoC: tlv320aic31xx: suppress error message for EPROBE_DEFER
[ Upstream commit b7e814deae33eb30f8f8c6528e8e69b107978d88 ]
Both the supplies and reset GPIO might need a probe deferral for the
resource to be available. Don't print a error message in that case, as
it is a normal operating condition.
Signed-off-by: Lucas Stach <l.stach@pengutronix.de>
Acked-by: Andrew F. Davis <afd@ti.com>
Link: https://lore.kernel.org/r/20190719143637.2018-1-l.stach@pengutronix.de
Signed-off-by: Mark Brown <broonie@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
Diffstat (limited to 'sound')
-rw-r--r-- | sound/soc/codecs/tlv320aic31xx.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/sound/soc/codecs/tlv320aic31xx.c b/sound/soc/codecs/tlv320aic31xx.c index bf92d36b8f8a..3c75dcf91741 100644 --- a/sound/soc/codecs/tlv320aic31xx.c +++ b/sound/soc/codecs/tlv320aic31xx.c @@ -1441,7 +1441,8 @@ static int aic31xx_i2c_probe(struct i2c_client *i2c, aic31xx->gpio_reset = devm_gpiod_get_optional(aic31xx->dev, "reset", GPIOD_OUT_LOW); if (IS_ERR(aic31xx->gpio_reset)) { - dev_err(aic31xx->dev, "not able to acquire gpio\n"); + if (PTR_ERR(aic31xx->gpio_reset) != -EPROBE_DEFER) + dev_err(aic31xx->dev, "not able to acquire gpio\n"); return PTR_ERR(aic31xx->gpio_reset); } @@ -1452,7 +1453,9 @@ static int aic31xx_i2c_probe(struct i2c_client *i2c, ARRAY_SIZE(aic31xx->supplies), aic31xx->supplies); if (ret) { - dev_err(aic31xx->dev, "Failed to request supplies: %d\n", ret); + if (ret != -EPROBE_DEFER) + dev_err(aic31xx->dev, + "Failed to request supplies: %d\n", ret); return ret; } |