aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/input
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/input')
-rw-r--r--drivers/input/touchscreen/sx8654.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/drivers/input/touchscreen/sx8654.c b/drivers/input/touchscreen/sx8654.c
index de83ed1da36e..477533cd40ab 100644
--- a/drivers/input/touchscreen/sx8654.c
+++ b/drivers/input/touchscreen/sx8654.c
@@ -27,6 +27,7 @@
27 * published by the Free Software Foundation. 27 * published by the Free Software Foundation.
28 */ 28 */
29 29
30#include <linux/bitops.h>
30#include <linux/delay.h> 31#include <linux/delay.h>
31#include <linux/gpio/consumer.h> 32#include <linux/gpio/consumer.h>
32#include <linux/i2c.h> 33#include <linux/i2c.h>
@@ -46,7 +47,7 @@
46#define I2C_REG_SOFTRESET 0x3f 47#define I2C_REG_SOFTRESET 0x3f
47 48
48#define I2C_REG_SX8650_STAT 0x05 49#define I2C_REG_SX8650_STAT 0x05
49#define SX8650_STAT_CONVIRQ 0x80 50#define SX8650_STAT_CONVIRQ BIT(7)
50 51
51/* commands */ 52/* commands */
52#define CMD_READ_REGISTER 0x40 53#define CMD_READ_REGISTER 0x40
@@ -56,8 +57,8 @@
56#define SOFTRESET_VALUE 0xde 57#define SOFTRESET_VALUE 0xde
57 58
58/* bits for I2C_REG_IRQSRC */ 59/* bits for I2C_REG_IRQSRC */
59#define IRQ_PENTOUCH_TOUCHCONVDONE 0x08 60#define IRQ_PENTOUCH_TOUCHCONVDONE BIT(3)
60#define IRQ_PENRELEASE 0x04 61#define IRQ_PENRELEASE BIT(2)
61 62
62/* bits for RegTouch1 */ 63/* bits for RegTouch1 */
63#define CONDIRQ 0x20 64#define CONDIRQ 0x20
@@ -65,8 +66,8 @@
65#define FILT_7SA 0x03 66#define FILT_7SA 0x03
66 67
67/* bits for I2C_REG_CHANMASK */ 68/* bits for I2C_REG_CHANMASK */
68#define CONV_X 0x80 69#define CONV_X BIT(7)
69#define CONV_Y 0x40 70#define CONV_Y BIT(6)
70 71
71/* coordinates rate: higher nibble of CTRL0 register */ 72/* coordinates rate: higher nibble of CTRL0 register */
72#define RATE_MANUAL 0x00 73#define RATE_MANUAL 0x00