diff mbox series

[v5,02/11] staging: iio: ad7780: add missing switch default case

Message ID 84375be9b21a30dde736e47a7e2f72c1aedf7e92.1552700652.git.renatogeh@gmail.com (mailing list archive)
State New, archived
Headers show
Series staging: iio: ad7780: move out of staging | expand

Commit Message

Renato Lui Geh March 16, 2019, 2:12 a.m. UTC
This patch simply adds a missing switch default case in read_raw.

Signed-off-by: Renato Lui Geh <renatogeh@gmail.com>
---
 drivers/staging/iio/adc/ad7780.c | 2 ++
 1 file changed, 2 insertions(+)

Comments

Jonathan Cameron March 16, 2019, 5:48 p.m. UTC | #1
On Fri, 15 Mar 2019 23:12:53 -0300
Renato Lui Geh <renatogeh@gmail.com> wrote:

> This patch simply adds a missing switch default case in read_raw.
> 
> Signed-off-by: Renato Lui Geh <renatogeh@gmail.com>
Applied,

Thanks,

Jonathan

> ---
>  drivers/staging/iio/adc/ad7780.c | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/drivers/staging/iio/adc/ad7780.c b/drivers/staging/iio/adc/ad7780.c
> index 07e5e35c92a3..f4cd7bc3e02f 100644
> --- a/drivers/staging/iio/adc/ad7780.c
> +++ b/drivers/staging/iio/adc/ad7780.c
> @@ -118,6 +118,8 @@ static int ad7780_read_raw(struct iio_dev *indio_dev,
>  	case IIO_CHAN_INFO_OFFSET:
>  		*val = -(1 << (chan->scan_type.realbits - 1));
>  		return IIO_VAL_INT;
> +	default:
> +		break;
>  	}
>  
>  	return -EINVAL;
diff mbox series

Patch

diff --git a/drivers/staging/iio/adc/ad7780.c b/drivers/staging/iio/adc/ad7780.c
index 07e5e35c92a3..f4cd7bc3e02f 100644
--- a/drivers/staging/iio/adc/ad7780.c
+++ b/drivers/staging/iio/adc/ad7780.c
@@ -118,6 +118,8 @@  static int ad7780_read_raw(struct iio_dev *indio_dev,
 	case IIO_CHAN_INFO_OFFSET:
 		*val = -(1 << (chan->scan_type.realbits - 1));
 		return IIO_VAL_INT;
+	default:
+		break;
 	}
 
 	return -EINVAL;