diff options
author | Jonathan Cameron <jic23@kernel.org> | 2013-01-12 10:35:00 +0000 |
---|---|---|
committer | Jonathan Cameron <jic23@kernel.org> | 2013-01-26 10:36:51 +0000 |
commit | a722dcca4da47a480a6042c0c0275695a597b77f (patch) | |
tree | ed236ca9587914a10d5840c26bc121161f67fc3f /drivers/staging/iio | |
parent | a9e244f65df170ae6efba03bdb0a203626ae1cd3 (diff) | |
download | linux-a722dcca4da47a480a6042c0c0275695a597b77f.tar.bz2 |
staging:iio:tsl2563 Simplify exit path on error in read_interrupt_config.
A rather over complicated exit path given there is only one exit
route and nothing much is done after it.
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
Acked-by: Peter Meerwald <pmeerw@pmeerw.net>
Diffstat (limited to 'drivers/staging/iio')
-rw-r--r-- | drivers/staging/iio/light/tsl2563.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/staging/iio/light/tsl2563.c b/drivers/staging/iio/light/tsl2563.c index 547203cfd5d5..1a3092a515ff 100644 --- a/drivers/staging/iio/light/tsl2563.c +++ b/drivers/staging/iio/light/tsl2563.c @@ -672,11 +672,9 @@ static int tsl2563_read_interrupt_config(struct iio_dev *indio_dev, TSL2563_CMD | TSL2563_REG_INT); mutex_unlock(&chip->lock); if (ret < 0) - goto error_ret; - ret = !!(ret & 0x30); -error_ret: + return ret; - return ret; + return !!(ret & 0x30); } static struct i2c_driver tsl2563_i2c_driver; |