| #include <linux/input-polldev.h> |
| #include <linux/kthread.h> |
| #include <linux/spinlock.h> |
| #include <asm/of_device.h> |
| struct device_node *of_node; |
| struct of_device *of_dev; |
| struct work_struct worker; |
| * Only call these functions with the main lock held. |
| void (*get_xyz)(s8 *x, s8 *y, s8 *z); |
| void (*clear_irq)(enum ams_irq reg); |
| #ifdef CONFIG_SENSORS_AMS_I2C |
| struct i2c_client i2c_client; |
| struct input_polled_dev *idev; |
| /* calibrated null values */ |
| int xcalib, ycalib, zcalib; |
| extern struct ams ams_info; |
| extern void ams_sensors(s8 *x, s8 *y, s8 *z); |
| extern int ams_sensor_attach(void); |
| extern int ams_pmu_init(struct device_node *np); |
| extern int ams_i2c_init(struct device_node *np); |
| extern int ams_input_init(void); |
| extern void ams_input_exit(void); |