diff options
author | Axel Lin <axel.lin@gmail.com> | 2010-08-05 20:09:14 -0400 |
---|---|---|
committer | Liam Girdwood <lrg@slimlogic.co.uk> | 2010-08-11 06:38:02 -0400 |
commit | 27ef7f00c96e45192d5dcc7e4589376f3a2fded3 (patch) | |
tree | 423e03c5e672c36bb9feca2c8fa7b89c7bbd3c94 /drivers/regulator | |
parent | 1b69d8e3fde65ab2b7c5e1d4adee59e8a67b0b4f (diff) |
regulator: lp3971 - remove unnecessary ret value checking in lp3971_i2c_write()
We already check count value before calling i2c_smbus_read_byte_data(),
no need to check it again.
Signed-off-by: Axel Lin <axel.lin@gmail.com>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Liam Girdwood <lrg@slimlogic.co.uk>
Diffstat (limited to 'drivers/regulator')
-rw-r--r-- | drivers/regulator/lp3971.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/regulator/lp3971.c b/drivers/regulator/lp3971.c index 8ae3732eb24b..5362289c7d69 100644 --- a/drivers/regulator/lp3971.c +++ b/drivers/regulator/lp3971.c | |||
@@ -377,7 +377,7 @@ static int lp3971_i2c_read(struct i2c_client *i2c, char reg, int count, | |||
377 | if (count != 1) | 377 | if (count != 1) |
378 | return -EIO; | 378 | return -EIO; |
379 | ret = i2c_smbus_read_byte_data(i2c, reg); | 379 | ret = i2c_smbus_read_byte_data(i2c, reg); |
380 | if (ret < 0 || count != 1) | 380 | if (ret < 0) |
381 | return -EIO; | 381 | return -EIO; |
382 | 382 | ||
383 | *dest = ret; | 383 | *dest = ret; |