diff mbox series

iio: remove unneeded break

Message ID 20201019172824.32166-1-trix@redhat.com (mailing list archive)
State New, archived
Headers show
Series iio: remove unneeded break | expand

Commit Message

Tom Rix Oct. 19, 2020, 5:28 p.m. UTC
From: Tom Rix <trix@redhat.com>

A break is not needed if it is preceded by a return

Signed-off-by: Tom Rix <trix@redhat.com>
---
 drivers/iio/adc/meson_saradc.c       | 2 --
 drivers/iio/imu/bmi160/bmi160_core.c | 1 -
 2 files changed, 3 deletions(-)

Comments

Martin Blumenstingl Oct. 20, 2020, 7:39 p.m. UTC | #1
On Mon, Oct 19, 2020 at 7:28 PM <trix@redhat.com> wrote:
>
> From: Tom Rix <trix@redhat.com>
>
> A break is not needed if it is preceded by a return
>
> Signed-off-by: Tom Rix <trix@redhat.com>
> ---
>  drivers/iio/adc/meson_saradc.c       | 2 --
for meson_saradc.c:
Reviewed-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
Jonathan Cameron Nov. 1, 2020, 3:32 p.m. UTC | #2
On Tue, 20 Oct 2020 21:39:17 +0200
Martin Blumenstingl <martin.blumenstingl@googlemail.com> wrote:

> On Mon, Oct 19, 2020 at 7:28 PM <trix@redhat.com> wrote:
> >
> > From: Tom Rix <trix@redhat.com>
> >
> > A break is not needed if it is preceded by a return
> >
> > Signed-off-by: Tom Rix <trix@redhat.com>
> > ---
> >  drivers/iio/adc/meson_saradc.c       | 2 --  
> for meson_saradc.c:
> Reviewed-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
Applied,

Thanks,

Jonathan
diff mbox series

Patch

diff --git a/drivers/iio/adc/meson_saradc.c b/drivers/iio/adc/meson_saradc.c
index e03988698755..66dc452d643a 100644
--- a/drivers/iio/adc/meson_saradc.c
+++ b/drivers/iio/adc/meson_saradc.c
@@ -593,13 +593,11 @@  static int meson_sar_adc_iio_info_read_raw(struct iio_dev *indio_dev,
 	case IIO_CHAN_INFO_RAW:
 		return meson_sar_adc_get_sample(indio_dev, chan, NO_AVERAGING,
 						ONE_SAMPLE, val);
-		break;
 
 	case IIO_CHAN_INFO_AVERAGE_RAW:
 		return meson_sar_adc_get_sample(indio_dev, chan,
 						MEAN_AVERAGING, EIGHT_SAMPLES,
 						val);
-		break;
 
 	case IIO_CHAN_INFO_SCALE:
 		if (chan->type == IIO_VOLTAGE) {
diff --git a/drivers/iio/imu/bmi160/bmi160_core.c b/drivers/iio/imu/bmi160/bmi160_core.c
index 222ebb26f013..431076dc0d2c 100644
--- a/drivers/iio/imu/bmi160/bmi160_core.c
+++ b/drivers/iio/imu/bmi160/bmi160_core.c
@@ -486,7 +486,6 @@  static int bmi160_write_raw(struct iio_dev *indio_dev,
 	case IIO_CHAN_INFO_SCALE:
 		return bmi160_set_scale(data,
 					bmi160_to_sensor(chan->type), val2);
-		break;
 	case IIO_CHAN_INFO_SAMP_FREQ:
 		return bmi160_set_odr(data, bmi160_to_sensor(chan->type),
 				      val, val2);