Skip to contentSkip to conversation

iio:gyro:itg3200 - drop unreachable return ret. Highlighted by smatch

PATCH Applied Jonathan Cameron 1 participant 2 messages Mar 1, 2014 – Mar 15, 2014 IIO

lore
Share & tools
lore

Jonathan Cameron

author maintainer
#0 lore raw

PATCH 1/1 iio:gyro:itg3200 - drop unreachable return ret. Highlighted by smatch

CHECK drivers/iio/gyro/itg3200_core.c
drivers/iio/gyro/itg3200_core.c:114 itg3200_read_raw() info: ignoring unreachable code.

Cc Neil Brown <[email protected]>
Cc Dan Carpenter <[email protected]>
---
 drivers/iio/gyro/itg3200_core.c | 2 --
 1 file changed, 2 deletions(-)
drivers/iio/gyro/itg3200_core.c +0 -2
index 4d3f3b9..8295e31 100644
@@ -110,8 +110,6 @@ static int itg3200_read_raw(struct iio_dev *indio_dev,
 	default:
 		return -EINVAL;
 	}
-
-	return ret;
 }
 
 static ssize_t itg3200_read_frequency(struct device *dev,
Signature · 1 line
1.9.0
author maintainer Applied
#1 lore raw
Quoted 6 lines · Jonathan Cameron

CHECK drivers/iio/gyro/itg3200_core.c
drivers/iio/gyro/itg3200_core.c:114 itg3200_read_raw() info: ignoring unreachable code.

Cc Neil Brown <[email protected]>
Cc Dan Carpenter <[email protected]>

Applied to the togreg branch of iio.git as clearly no one cares.

Quoted 18 lines
---
  drivers/iio/gyro/itg3200_core.c | 2 --
  1 file changed, 2 deletions(-)
drivers/iio/gyro/itg3200_core.c +0 -2
index 4d3f3b9..8295e31 100644
@@ -110,8 +110,6 @@ static int itg3200_read_raw(struct iio_dev *indio_dev,
  	default:
  		return -EINVAL;
  	}
-
-	return ret;
  }
 
  static ssize_t itg3200_read_frequency(struct device *dev,