iio:imu:adis16400 remove an unneeded check
Subsystems (3)
PATCH 1/1 iio:imu:adis16400 remove an unneeded check
We know "ret" is zero here so there is no need to check.
Signed-off-by Dan Carpenter <[email protected]>
drivers/iio/imu/adis16400_core.c +1 -1
@@ -281,7 +281,7 @@ static ssize_t adis16400_write_frequency(struct device *dev, st->variant->set_freq (st, val);mutex_unlock (&indio_dev->mlock); -return ret ? ret : len; +return len; }/* Power down the device */
Quoted 3 lines · Dan Carpenter
We know "ret" is zero here so there is no need to check.
Signed-off-by Dan Carpenter <[email protected]>
Thanks.
Quoted 15 lines
drivers/iio/imu/adis16400_core.c +1
-1@@ -281,7 +281,7 @@ static ssize_t adis16400_write_frequency(struct device *dev, st->variant->set_freq (st, val);mutex_unlock (&indio_dev->mlock); -return ret ? ret : len; +return len; }/* Power down the device */
Quoted 6 lines · Lars-Peter Clausen
Quoted 3 lines · Dan Carpenter
We know "ret" is zero here so there is no need to check.
Signed-off-by Dan Carpenter <[email protected]>
Applied to the togreg branch of iio.git
Thanks,
Quoted 19 lines
Thanks.
Quoted 15 lines
drivers/iio/imu/adis16400_core.c +1
-1@@ -281,7 +281,7 @@ static ssize_t adis16400_write_frequency(struct device *dev, st->variant->set_freq (st, val);mutex_unlock (&indio_dev->mlock); -return ret ? ret : len; +return len; }/* Power down the device */