diff options
author | Axel Lin <axel.lin@gmail.com> | 2011-11-18 21:15:53 -0500 |
---|---|---|
committer | Mark Brown <broonie@opensource.wolfsonmicro.com> | 2011-11-21 12:05:52 -0500 |
commit | ea0756158110fef07b2f2975e38890cecde6a1ce (patch) | |
tree | aa03afad8e5f36c046a6f037aaca5cef114f34b0 /sound/soc/codecs | |
parent | 6413d542b04800188fd5401d97d141880c638df6 (diff) |
ASoC: cs42l73: Return proper error code if device id mismatch
Return -ENODEV instead of 0 if device id mismatch.
Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Diffstat (limited to 'sound/soc/codecs')
-rw-r--r-- | sound/soc/codecs/cs42l73.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/sound/soc/codecs/cs42l73.c b/sound/soc/codecs/cs42l73.c index 6fe259aceb7b..fdd8aa207730 100644 --- a/sound/soc/codecs/cs42l73.c +++ b/sound/soc/codecs/cs42l73.c | |||
@@ -1369,6 +1369,7 @@ static __devinit int cs42l73_i2c_probe(struct i2c_client *i2c_client, | |||
1369 | 1369 | ||
1370 | 1370 | ||
1371 | if (devid != CS42L73_DEVID) { | 1371 | if (devid != CS42L73_DEVID) { |
1372 | ret = -ENODEV; | ||
1372 | dev_err(&i2c_client->dev, | 1373 | dev_err(&i2c_client->dev, |
1373 | "CS42L73 Device ID (%X). Expected %X\n", | 1374 | "CS42L73 Device ID (%X). Expected %X\n", |
1374 | devid, CS42L73_DEVID); | 1375 | devid, CS42L73_DEVID); |