Diff
Modified: trunk/drivers/staging/iio/addac/adt7316.c (9301 => 9302)
--- trunk/drivers/staging/iio/addac/adt7316.c 2010-10-23 20:20:21 UTC (rev 9301)
+++ trunk/drivers/staging/iio/addac/adt7316.c 2010-10-23 20:20:46 UTC (rev 9302)
@@ -176,7 +176,7 @@
struct adt7316_chip_info {
const char *name;
struct iio_dev *indio_dev;
- struct iio_work_cont work_cont_thresh;
+ struct work_struct thresh_work;
s64 last_timestamp;
struct adt7316_bus bus;
u16 ldac_pin;
@@ -1797,8 +1797,8 @@
static void adt7316_interrupt_bh(struct work_struct *work_s)
{
- struct iio_work_cont *wc = to_iio_work_cont_no_check(work_s);
- struct adt7316_chip_info *chip = wc->st;
+ struct adt7316_chip_info *chip =
+ container_of(work_s, struct adt7316_chip_info, thresh_work);
u8 stat1, stat2;
int i, ret, count;
@@ -1836,7 +1836,7 @@
struct adt7316_chip_info *chip = dev_info->dev_data;
chip->last_timestamp = timestamp;
- schedule_work(&chip->work_cont_thresh.ws_nocheck);
+ schedule_work(&chip->thresh_work);
return 0;
}
@@ -2323,13 +2323,6 @@
goto error_free_dev;
if (chip->bus.irq > 0) {
- iio_init_work_cont(&chip->work_cont_thresh,
- adt7316_interrupt_bh,
- adt7316_interrupt_bh,
- 0,
- 0,
- chip);
-
if (adt7316_platform_data[0])
chip->bus.irq_flags = adt7316_platform_data[0];
@@ -2349,6 +2342,8 @@
iio_add_event_to_list(&iio_event_adt7316,
&chip->indio_dev->interrupts[0]->ev_list);
+ INIT_WORK(&chip->thresh_work, adt7316_interrupt_bh);
+
if (chip->bus.irq_flags & IRQF_TRIGGER_HIGH)
chip->config1 |= ADT7316_INT_POLARITY;
}
Modified: trunk/drivers/staging/iio/gyro/adis16060.h (9301 => 9302)
--- trunk/drivers/staging/iio/gyro/adis16060.h 2010-10-23 20:20:21 UTC (rev 9301)
+++ trunk/drivers/staging/iio/gyro/adis16060.h 2010-10-23 20:20:46 UTC (rev 9302)
@@ -15,7 +15,6 @@
* struct adis16060_state - device instance specific data
* @us_w: actual spi_device to write data
* @work_trigger_to_ring: bh for triggered event handling
- * @work_cont_thresh: CLEAN
* @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
@@ -28,7 +27,6 @@
struct spi_device *us_w;
struct spi_device *us_r;
struct work_struct work_trigger_to_ring;
- struct iio_work_cont work_cont_thresh;
s64 last_timestamp;
struct iio_dev *indio_dev;
struct iio_trigger *trig;
Modified: trunk/drivers/staging/iio/gyro/adis16060_core.c (9301 => 9302)
--- trunk/drivers/staging/iio/gyro/adis16060_core.c 2010-10-23 20:20:21 UTC (rev 9301)
+++ trunk/drivers/staging/iio/gyro/adis16060_core.c 2010-10-23 20:20:46 UTC (rev 9302)
@@ -190,14 +190,6 @@
}
if (spi->irq && gpio_is_valid(irq_to_gpio(spi->irq)) > 0) {
-#if 0 /* fixme: here we should support */
- iio_init_work_cont(&st->work_cont_thresh,
- NULL,
- adis16060_thresh_handler_bh_no_check,
- 0,
- 0,
- st);
-#endif
ret = iio_register_interrupt_line(spi->irq,
st->indio_dev,
0,
Modified: trunk/drivers/staging/iio/gyro/adis16080.h (9301 => 9302)
--- trunk/drivers/staging/iio/gyro/adis16080.h 2010-10-23 20:20:21 UTC (rev 9301)
+++ trunk/drivers/staging/iio/gyro/adis16080.h 2010-10-23 20:20:46 UTC (rev 9302)
@@ -17,7 +17,6 @@
* struct adis16080_state - device instance specific data
* @us: actual spi_device to write data
* @work_trigger_to_ring: bh for triggered event handling
- * @work_cont_thresh: CLEAN
* @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
@@ -29,7 +28,6 @@
struct adis16080_state {
struct spi_device *us;
struct work_struct work_trigger_to_ring;
- struct iio_work_cont work_cont_thresh;
s64 last_timestamp;
struct iio_dev *indio_dev;
struct iio_trigger *trig;
Modified: trunk/drivers/staging/iio/gyro/adis16080_core.c (9301 => 9302)
--- trunk/drivers/staging/iio/gyro/adis16080_core.c 2010-10-23 20:20:21 UTC (rev 9301)
+++ trunk/drivers/staging/iio/gyro/adis16080_core.c 2010-10-23 20:20:46 UTC (rev 9302)
@@ -185,14 +185,6 @@
}
if (spi->irq && gpio_is_valid(irq_to_gpio(spi->irq)) > 0) {
-#if 0 /* fixme: here we should support */
- iio_init_work_cont(&st->work_cont_thresh,
- NULL,
- adis16080_thresh_handler_bh_no_check,
- 0,
- 0,
- st);
-#endif
ret = iio_register_interrupt_line(spi->irq,
st->indio_dev,
0,
Modified: trunk/drivers/staging/iio/gyro/adis16130.h (9301 => 9302)
--- trunk/drivers/staging/iio/gyro/adis16130.h 2010-10-23 20:20:21 UTC (rev 9301)
+++ trunk/drivers/staging/iio/gyro/adis16130.h 2010-10-23 20:20:46 UTC (rev 9302)
@@ -24,7 +24,6 @@
* struct adis16130_state - device instance specific data
* @us: actual spi_device to write data
* @work_trigger_to_ring: bh for triggered event handling
- * @work_cont_thresh: CLEAN
* @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
@@ -36,7 +35,6 @@
struct adis16130_state {
struct spi_device *us;
struct work_struct work_trigger_to_ring;
- struct iio_work_cont work_cont_thresh;
s64 last_timestamp;
struct iio_dev *indio_dev;
struct iio_trigger *trig;
Modified: trunk/drivers/staging/iio/gyro/adis16130_core.c (9301 => 9302)
--- trunk/drivers/staging/iio/gyro/adis16130_core.c 2010-10-23 20:20:21 UTC (rev 9301)
+++ trunk/drivers/staging/iio/gyro/adis16130_core.c 2010-10-23 20:20:46 UTC (rev 9302)
@@ -227,14 +227,6 @@
}
if (spi->irq && gpio_is_valid(irq_to_gpio(spi->irq)) > 0) {
-#if 0 /* fixme: here we should support */
- iio_init_work_cont(&st->work_cont_thresh,
- NULL,
- adis16130_thresh_handler_bh_no_check,
- 0,
- 0,
- st);
-#endif
ret = iio_register_interrupt_line(spi->irq,
st->indio_dev,
0,
Modified: trunk/drivers/staging/iio/gyro/adis16261.h (9301 => 9302)
--- trunk/drivers/staging/iio/gyro/adis16261.h 2010-10-23 20:20:21 UTC (rev 9301)
+++ trunk/drivers/staging/iio/gyro/adis16261.h 2010-10-23 20:20:46 UTC (rev 9302)
@@ -74,7 +74,6 @@
* struct adis16261_state - device instance specific data
* @us: actual spi_device
* @work_trigger_to_ring: bh for triggered event handling
- * @work_cont_thresh: CLEAN
* @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
@@ -86,7 +85,6 @@
struct adis16261_state {
struct spi_device *us;
struct work_struct work_trigger_to_ring;
- struct iio_work_cont work_cont_thresh;
s64 last_timestamp;
struct iio_dev *indio_dev;
struct iio_trigger *trig;
Modified: trunk/drivers/staging/iio/gyro/adis16261_core.c (9301 => 9302)
--- trunk/drivers/staging/iio/gyro/adis16261_core.c 2010-10-23 20:20:21 UTC (rev 9301)
+++ trunk/drivers/staging/iio/gyro/adis16261_core.c 2010-10-23 20:20:46 UTC (rev 9302)
@@ -670,14 +670,6 @@
}
if (spi->irq && gpio_is_valid(irq_to_gpio(spi->irq)) > 0) {
-#if 0 /* fixme: here we should support */
- iio_init_work_cont(&st->work_cont_thresh,
- NULL,
- adis16261_thresh_handler_bh_no_check,
- 0,
- 0,
- st);
-#endif
ret = iio_register_interrupt_line(spi->irq,
st->indio_dev,
0,
Modified: trunk/drivers/staging/iio/meter/ade7753.c (9301 => 9302)
--- trunk/drivers/staging/iio/meter/ade7753.c 2010-10-23 20:20:21 UTC (rev 9301)
+++ trunk/drivers/staging/iio/meter/ade7753.c 2010-10-23 20:20:46 UTC (rev 9302)
@@ -630,14 +630,6 @@
}
if (spi->irq) {
-#if 0 /* fixme: here we should support */
- iio_init_work_cont(&st->work_cont_thresh,
- NULL,
- ade7753_thresh_handler_bh_no_check,
- 0,
- 0,
- st);
-#endif
ret = iio_register_interrupt_line(spi->irq,
st->indio_dev,
0,
Modified: trunk/drivers/staging/iio/meter/ade7753.h (9301 => 9302)
--- trunk/drivers/staging/iio/meter/ade7753.h 2010-10-23 20:20:21 UTC (rev 9301)
+++ trunk/drivers/staging/iio/meter/ade7753.h 2010-10-23 20:20:46 UTC (rev 9302)
@@ -61,7 +61,6 @@
* struct ade7753_state - device instance specific data
* @us: actual spi_device
* @work_trigger_to_ring: bh for triggered event handling
- * @work_cont_thresh: CLEAN
* @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
@@ -73,7 +72,6 @@
struct ade7753_state {
struct spi_device *us;
struct work_struct work_trigger_to_ring;
- struct iio_work_cont work_cont_thresh;
s64 last_timestamp;
struct iio_dev *indio_dev;
struct iio_trigger *trig;
Modified: trunk/drivers/staging/iio/meter/ade7754.c (9301 => 9302)
--- trunk/drivers/staging/iio/meter/ade7754.c 2010-10-23 20:20:21 UTC (rev 9301)
+++ trunk/drivers/staging/iio/meter/ade7754.c 2010-10-23 20:20:46 UTC (rev 9302)
@@ -656,14 +656,6 @@
}
if (spi->irq) {
-#if 0 /* fixme: here we should support */
- iio_init_work_cont(&st->work_cont_thresh,
- NULL,
- ade7754_thresh_handler_bh_no_check,
- 0,
- 0,
- st);
-#endif
ret = iio_register_interrupt_line(spi->irq,
st->indio_dev,
0,
Modified: trunk/drivers/staging/iio/meter/ade7754.h (9301 => 9302)
--- trunk/drivers/staging/iio/meter/ade7754.h 2010-10-23 20:20:21 UTC (rev 9301)
+++ trunk/drivers/staging/iio/meter/ade7754.h 2010-10-23 20:20:46 UTC (rev 9302)
@@ -79,7 +79,6 @@
* struct ade7754_state - device instance specific data
* @us: actual spi_device
* @work_trigger_to_ring: bh for triggered event handling
- * @work_cont_thresh: CLEAN
* @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
@@ -91,7 +90,6 @@
struct ade7754_state {
struct spi_device *us;
struct work_struct work_trigger_to_ring;
- struct iio_work_cont work_cont_thresh;
s64 last_timestamp;
struct iio_dev *indio_dev;
struct iio_trigger *trig;
Modified: trunk/drivers/staging/iio/meter/ade7759.c (9301 => 9302)
--- trunk/drivers/staging/iio/meter/ade7759.c 2010-10-23 20:20:21 UTC (rev 9301)
+++ trunk/drivers/staging/iio/meter/ade7759.c 2010-10-23 20:20:46 UTC (rev 9302)
@@ -570,14 +570,6 @@
}
if (spi->irq) {
-#if 0 /* fixme: here we should support */
- iio_init_work_cont(&st->work_cont_thresh,
- NULL,
- ade7759_thresh_handler_bh_no_check,
- 0,
- 0,
- st);
-#endif
ret = iio_register_interrupt_line(spi->irq,
st->indio_dev,
0,
Modified: trunk/drivers/staging/iio/meter/ade7759.h (9301 => 9302)
--- trunk/drivers/staging/iio/meter/ade7759.h 2010-10-23 20:20:21 UTC (rev 9301)
+++ trunk/drivers/staging/iio/meter/ade7759.h 2010-10-23 20:20:46 UTC (rev 9302)
@@ -42,7 +42,6 @@
* struct ade7759_state - device instance specific data
* @us: actual spi_device
* @work_trigger_to_ring: bh for triggered event handling
- * @work_cont_thresh: CLEAN
* @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
@@ -54,7 +53,6 @@
struct ade7759_state {
struct spi_device *us;
struct work_struct work_trigger_to_ring;
- struct iio_work_cont work_cont_thresh;
s64 last_timestamp;
struct iio_dev *indio_dev;
struct iio_trigger *trig;
Modified: trunk/drivers/staging/iio/meter/ade7854.c (9301 => 9302)
--- trunk/drivers/staging/iio/meter/ade7854.c 2010-10-23 20:20:21 UTC (rev 9301)
+++ trunk/drivers/staging/iio/meter/ade7854.c 2010-10-23 20:20:46 UTC (rev 9302)
@@ -609,14 +609,6 @@
}
if (st->irq) {
-#if 0 /* fixme: here we should support */
- iio_init_work_cont(&st->work_cont_thresh,
- NULL,
- ade7854_thresh_handler_bh_no_check,
- 0,
- 0,
- st);
-#endif
ret = iio_register_interrupt_line(st->irq,
st->indio_dev,
0,
Modified: trunk/drivers/staging/iio/meter/ade7854.h (9301 => 9302)
--- trunk/drivers/staging/iio/meter/ade7854.h 2010-10-23 20:20:21 UTC (rev 9301)
+++ trunk/drivers/staging/iio/meter/ade7854.h 2010-10-23 20:20:46 UTC (rev 9302)
@@ -148,7 +148,6 @@
* struct ade7854_state - device instance specific data
* @spi: actual spi_device
* @work_trigger_to_ring: bh for triggered event handling
- * @work_cont_thresh: CLEAN
* @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
@@ -161,7 +160,6 @@
struct spi_device *spi;
struct i2c_client *i2c;
struct work_struct work_trigger_to_ring;
- struct iio_work_cont work_cont_thresh;
s64 last_timestamp;
struct iio_dev *indio_dev;
struct iio_trigger *trig;