lis3: use input_polled_device
[sfrench/cifs-2.6.git] / drivers / hwmon / lis3lv02d.h
index 745ec96806d485a0f93f33932e2a588e6a8ab546..5a5a196e6a66870eca4fbc6d06d95ae01f99a1d9 100644 (file)
@@ -18,6 +18,8 @@
  *  along with this program; if not, write to the Free Software
  *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
  */
+#include <linux/platform_device.h>
+#include <linux/input-polldev.h>
 
 /*
  * The actual chip is STMicroelectronics LIS3LV02DL or LIS3LV02DQ that seems to
@@ -169,16 +171,12 @@ struct lis3lv02d {
        s16 (*read_data) (struct lis3lv02d *lis3, int reg);
        int                     mdps_max_val;
 
-       struct input_dev        *idev;     /* input device */
-       struct task_struct      *kthread;  /* kthread for input */
-       struct mutex            lock;
+       struct input_polled_dev *idev;     /* input device */
        struct platform_device  *pdev;     /* platform device */
        atomic_t                count;     /* interrupt count after last read */
        int                     xcalib;    /* calibrated null value for x */
        int                     ycalib;    /* calibrated null value for y */
        int                     zcalib;    /* calibrated null value for z */
-       unsigned char           is_on;     /* whether the device is on or off */
-       unsigned char           usage;     /* usage counter */
        struct axis_conversion  ac;        /* hw -> logical axis */
 
        u32                     irq;       /* IRQ number */
@@ -192,6 +190,6 @@ int lis3lv02d_joystick_enable(void);
 void lis3lv02d_joystick_disable(void);
 void lis3lv02d_poweroff(struct lis3lv02d *lis3);
 void lis3lv02d_poweron(struct lis3lv02d *lis3);
-int lis3lv02d_remove_fs(void);
+int lis3lv02d_remove_fs(struct lis3lv02d *lis3);
 
 extern struct lis3lv02d lis3_dev;