diff options
author | Jonathan Cameron <jic23@cam.ac.uk> | 2011-02-11 14:07:43 (GMT) |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2011-02-18 21:23:50 (GMT) |
commit | 3faa4d3f88d85cdf5de26bd6e52073071cc24b07 (patch) | |
tree | b4ec89b96d9521507b9c90829498ed62bc8da76e /drivers/staging/iio/meter/ade7854.h | |
parent | 3859faca5e6a79bcef54bd2233efe970323e3631 (diff) | |
download | linux-3faa4d3f88d85cdf5de26bd6e52073071cc24b07.tar.xz |
staging:iio:meter remove stubs from ade7854.
General cleanup and use of standard functions to simplfy some spi reads
as well.
Also added a device id table to the spi version.
Signed-off-by: Jonathan Cameron <jic23@cam.ac.uk>
Acked-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/staging/iio/meter/ade7854.h')
-rw-r--r-- | drivers/staging/iio/meter/ade7854.h | 69 |
1 files changed, 0 insertions, 69 deletions
diff --git a/drivers/staging/iio/meter/ade7854.h b/drivers/staging/iio/meter/ade7854.h index 47690e5..4ad84a3 100644 --- a/drivers/staging/iio/meter/ade7854.h +++ b/drivers/staging/iio/meter/ade7854.h @@ -147,11 +147,7 @@ /** * struct ade7854_state - device instance specific data * @spi: actual spi_device - * @work_trigger_to_ring: bh for triggered event handling - * @inter: used to check if new interrupt has been triggered - * @last_timestamp: passing timestamp from th to bh of interrupt handler * @indio_dev: industrial I/O device structure - * @trig: data ready trigger registered with iio * @tx: transmit buffer * @rx: recieve buffer * @buf_lock: mutex to protect tx and rx @@ -159,10 +155,7 @@ struct ade7854_state { struct spi_device *spi; struct i2c_client *i2c; - struct work_struct work_trigger_to_ring; - s64 last_timestamp; struct iio_dev *indio_dev; - struct iio_trigger *trig; u8 *tx; u8 *rx; int (*read_reg_8) (struct device *, u16, u8 *); @@ -180,66 +173,4 @@ struct ade7854_state { extern int ade7854_probe(struct ade7854_state *st, struct device *dev); extern int ade7854_remove(struct ade7854_state *st); -#if defined(CONFIG_IIO_RING_BUFFER) && defined(THIS_HAS_RING_BUFFER_SUPPORT) -/* At the moment triggers are only used for ring buffer - * filling. This may change! - */ - -enum ade7854_scan { - ADE7854_SCAN_PHA_V, - ADE7854_SCAN_PHB_V, - ADE7854_SCAN_PHC_V, - ADE7854_SCAN_PHA_I, - ADE7854_SCAN_PHB_I, - ADE7854_SCAN_PHC_I, -}; - -void ade7854_remove_trigger(struct iio_dev *indio_dev); -int ade7854_probe_trigger(struct iio_dev *indio_dev); - -ssize_t ade7854_read_data_from_ring(struct device *dev, - struct device_attribute *attr, - char *buf); - - -int ade7854_configure_ring(struct iio_dev *indio_dev); -void ade7854_unconfigure_ring(struct iio_dev *indio_dev); - -int ade7854_initialize_ring(struct iio_ring_buffer *ring); -void ade7854_uninitialize_ring(struct iio_ring_buffer *ring); -#else /* CONFIG_IIO_RING_BUFFER */ - -static inline void ade7854_remove_trigger(struct iio_dev *indio_dev) -{ -} -static inline int ade7854_probe_trigger(struct iio_dev *indio_dev) -{ - return 0; -} - -static inline ssize_t -ade7854_read_data_from_ring(struct device *dev, - struct device_attribute *attr, - char *buf) -{ - return 0; -} - -static inline int ade7854_configure_ring(struct iio_dev *indio_dev) -{ - return 0; -} - -static inline void ade7854_unconfigure_ring(struct iio_dev *indio_dev) -{ -} -static inline int ade7854_initialize_ring(struct iio_ring_buffer *ring) -{ - return 0; -} -static inline void ade7854_uninitialize_ring(struct iio_ring_buffer *ring) -{ -} -#endif /* CONFIG_IIO_RING_BUFFER */ - #endif |