Skip to contentSkip to conversation

iio:temp:mlx90614 trivial drop of unnecessary ret return from write_raw.

PATCH In review Jonathan Cameron 1 participant 2 messages May 2, 2015 – May 13, 2015

Subsystems (2)
lore
Share & tools
lore

Jonathan Cameron

author maintainer
#0 lore raw

PATCH 1/1 iio:temp:mlx90614 trivial drop of unnecessary ret return from write_raw.

This is mostly part of an effort to clean out our current warnings and make the autobuilder build reports more useful.

Still a worthwhile if trivial cleanup!

Cc Vianney le Clément de Saint-Marcq <[email protected]>
Cc Peter Meerwald <[email protected]>
---
 drivers/iio/temperature/mlx90614.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)
drivers/iio/temperature/mlx90614.c +1 -3
index b2d3b56f1260..cb2e8ad8bfdc 100644
@@ -254,9 +254,7 @@ static int mlx90614_write_raw(struct iio_dev *indio_dev,
 		mutex_unlock(&data->lock);
 		mlx90614_power_put(data);
 
-		if (ret < 0)
-			return ret;
-		return 0;
+		return ret;
 	default:
 		return -EINVAL;
 	}
Signature · 1 line
2.3.5
author maintainer
#1 lore raw
Quoted 9 lines · Jonathan Cameron

This is mostly part of an effort to clean out our current warnings and make the autobuilder build reports more useful.

Still a worthwhile if trivial cleanup!

Cc Vianney le Clément de Saint-Marcq <[email protected]>
Cc Peter Meerwald <[email protected]>

Applied to the togreg branch of iio.git - pushed out as testing.

Jonathan

Quoted 20 lines
---
 drivers/iio/temperature/mlx90614.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)
drivers/iio/temperature/mlx90614.c +1 -3
index b2d3b56f1260..cb2e8ad8bfdc 100644
@@ -254,9 +254,7 @@ static int mlx90614_write_raw(struct iio_dev *indio_dev,
 		mutex_unlock(&data->lock);
 		mlx90614_power_put(data);
 
-		if (ret < 0)
-			return ret;
-		return 0;
+		return ret;
 	default:
 		return -EINVAL;
 	}