UPSTREAM: ASoC: rt5616: Return error if device ID mismatch

Signed-off-by: Axel Lin <axel.lin@ingics.com>
Acked-by: Bard Liao <bardliao@realtek.com>
Signed-off-by: Mark Brown <broonie@kernel.org>

Bug: 25923642
Patchset: rt5616 audio

(cherry picked from broonie/sound.git#for-next 36ddd489b0)
Signed-off-by: Kees Cook <keescook@chromium.org>

Change-Id: I55e15dfb42bf5022a976451311214980c4897aa5
Signed-off-by: Jacob Chen <jacob2.chen@rock-chips.com>
This commit is contained in:
Jacob Chen
2016-07-15 09:42:51 +08:00
committed by Huang, Tao
parent 89301d7512
commit 57ab3becfe

View File

@@ -1314,7 +1314,7 @@ static int rt5616_i2c_probe(struct i2c_client *i2c,
dev_err(&i2c->dev,
"Device with ID register %#x is not rt5616\n",
val);
ret = -ENODEV;
return -ENODEV;
}
regmap_write(rt5616->regmap, RT5616_RESET, 0);
regmap_update_bits(rt5616->regmap, RT5616_PWR_ANLG1,