iio: sca3000: Fix missing return in switch
authorGustavo A. R. Silva <gustavo@embeddedor.com>
Sat, 7 Jul 2018 17:44:01 +0000 (12:44 -0500)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 9 Sep 2018 17:55:56 +0000 (19:55 +0200)
commitb86374912fee81fc266355b2a911cbbb92ffff54
tree63268e4664459604a64cbc590a61758d4a198c46
parent91b48a9ced0683d0f69385a2d08b70574603fb27
iio: sca3000: Fix missing return in switch

commit c5b974bee9d2ceae4c441ae5a01e498c2674e100 upstream.

The IIO_CHAN_INFO_LOW_PASS_FILTER_3DB_FREQUENCY case is missing a
return and will fall through to the default case and errorenously
return -EINVAL.

Fix this by adding in missing *return ret*.

Fixes: 626f971b5b07 ("staging:iio:accel:sca3000 Add write support to the low pass filter control")
Reported-by: Jonathan Cameron <jic23@kernel.org>
Signed-off-by: Gustavo A. R. Silva <gustavo@embeddedor.com>
Cc: <Stable@vger.kernel.org>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/iio/accel/sca3000.c