aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/iio/industrialio-event.c
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>2013-11-25 21:42:40 -0500
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2013-11-25 21:42:40 -0500
commit3ce5ae8d46eed6cdaf38f5c8276f8c66f403d0d6 (patch)
tree91e35051672245d46c20196e4fce7669d91e6f85 /drivers/iio/industrialio-event.c
parentfa590c222fbaa428edb2ce2194638906cea1400a (diff)
parent794a870e776717ccbd27676a551250613de9c40c (diff)
Merge tag 'iio-for-3.14a' of git://git.kernel.org/pub/scm/linux/kernel/git/jic23/iio into staging-next
Jonathan writes: First set of new features, drivers and cleanups for IIO in the 3.14 cycle. This mostly consists of patches that didn't quite make the last cycle. Lots of interesting things under review currently. Core: - Add devm_iio_device_register/unregister. I took some convincing on whether there would be many devices that really were simple enough to need no explicit actions on removal. Turns out there are some. - Move some stray docs to above the relevant implemenation. - Drop a redundant repeated check on the fact the trigger has actually changed when there is a userspace attempt change it. Drivers: New drivers - Freescale MPL3115A2 Pressure / temperature sensor New functionality - hid_sensors: add sensitivity support. DT bindings - tsl2563 - hmc5843 Cleanups - Drop unused scan_type from viperboard adc driver. - devm_iio_device_register used in viperboard, ad5421, ad5755, adis16130, adxrs450, vcnl4000, adis16220, ad7816, lpc32xx, adt7316, adis16060, isl29018 and ad2s1200. Note that this was proposed in a number of other drivers and this revealed a number of missorderings in remove functions. Also for now I have blocked this on any device that any hardware suspend suport on the basis that we probably want to power down devices if they have no driver support loaded.
Diffstat (limited to 'drivers/iio/industrialio-event.c')
-rw-r--r--drivers/iio/industrialio-event.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/iio/industrialio-event.c b/drivers/iio/industrialio-event.c
index c10eab64bc05..bc043fab4cd1 100644
--- a/drivers/iio/industrialio-event.c
+++ b/drivers/iio/industrialio-event.c
@@ -42,6 +42,12 @@ struct iio_event_interface {
42 struct attribute_group group; 42 struct attribute_group group;
43}; 43};
44 44
45/**
46 * iio_push_event() - try to add event to the list for userspace reading
47 * @indio_dev: IIO device structure
48 * @ev_code: What event
49 * @timestamp: When the event occurred
50 **/
45int iio_push_event(struct iio_dev *indio_dev, u64 ev_code, s64 timestamp) 51int iio_push_event(struct iio_dev *indio_dev, u64 ev_code, s64 timestamp)
46{ 52{
47 struct iio_event_interface *ev_int = indio_dev->event_interface; 53 struct iio_event_interface *ev_int = indio_dev->event_interface;