summaryrefslogtreecommitdiff
path: root/drivers/staging/iio
diff options
context:
space:
mode:
authorAlan <gnomes@lxorguk.ukuu.org.uk>2015-04-08 22:24:43 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2015-04-30 17:57:32 +0300
commitaeda3b2d4a6760bda799feeaac391a7bdcdbbdb5 (patch)
tree337d4142077d7339c13191b90aa9996628b29ab5 /drivers/staging/iio
parent94361655442effc78904039cb051228b3228e4cb (diff)
downloadlinux-aeda3b2d4a6760bda799feeaac391a7bdcdbbdb5.tar.xz
iio: example code is buggy
Shock horror, example template code that has never been used in reality is in fact a hazard. This fixes the obvious bug, probably these kind of "examples" should be deleted so real (working) examples are followed. Signed-off-by: Alan Cox <alan@linux.intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/staging/iio')
-rw-r--r--drivers/staging/iio/iio_simple_dummy_events.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/staging/iio/iio_simple_dummy_events.c b/drivers/staging/iio/iio_simple_dummy_events.c
index a5cd3bb219fe..c32ef78d8e5f 100644
--- a/drivers/staging/iio/iio_simple_dummy_events.c
+++ b/drivers/staging/iio/iio_simple_dummy_events.c
@@ -84,6 +84,7 @@ int iio_simple_dummy_write_event_config(struct iio_dev *indio_dev,
default:
return -EINVAL;
}
+ break;
case IIO_STEPS:
switch (type) {
case IIO_EV_TYPE_CHANGE:
@@ -92,6 +93,7 @@ int iio_simple_dummy_write_event_config(struct iio_dev *indio_dev,
default:
return -EINVAL;
}
+ break;
default:
return -EINVAL;
}