diff options
| author | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2013-04-15 14:01:21 -0400 |
|---|---|---|
| committer | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2013-06-25 12:47:02 -0400 |
| commit | 02a71600df7805d80e4269684a75a0efc689657d (patch) | |
| tree | 7e0d20c87eb90cb674ded737d563f7be93c93b7b | |
| parent | 04848ba829b3b740c7c9ae0c5916f90efaed0f5d (diff) | |
Input: tps6507x-ts - use bool for booleans
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
| -rw-r--r-- | drivers/input/touchscreen/tps6507x-ts.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/drivers/input/touchscreen/tps6507x-ts.c b/drivers/input/touchscreen/tps6507x-ts.c index 1fb397c42aa3..c981ccf8cf15 100644 --- a/drivers/input/touchscreen/tps6507x-ts.c +++ b/drivers/input/touchscreen/tps6507x-ts.c | |||
| @@ -45,12 +45,12 @@ struct tps6507x_ts { | |||
| 45 | struct ts_event tc; | 45 | struct ts_event tc; |
| 46 | struct tps6507x_dev *mfd; | 46 | struct tps6507x_dev *mfd; |
| 47 | u16 model; | 47 | u16 model; |
| 48 | unsigned pendown; | 48 | u16 min_pressure; |
| 49 | int irq; | 49 | int irq; |
| 50 | void (*clear_penirq)(void); | 50 | void (*clear_penirq)(void); |
| 51 | unsigned long poll_period; /* ms */ | 51 | unsigned long poll_period; /* ms */ |
| 52 | u16 min_pressure; | ||
| 53 | int vref; /* non-zero to leave vref on */ | 52 | int vref; /* non-zero to leave vref on */ |
| 53 | bool pendown; | ||
| 54 | }; | 54 | }; |
| 55 | 55 | ||
| 56 | static int tps6507x_read_u8(struct tps6507x_ts *tsc, u8 reg, u8 *data) | 56 | static int tps6507x_read_u8(struct tps6507x_ts *tsc, u8 reg, u8 *data) |
| @@ -165,12 +165,12 @@ static void tps6507x_ts_handler(struct work_struct *work) | |||
| 165 | struct tps6507x_ts *tsc = container_of(work, | 165 | struct tps6507x_ts *tsc = container_of(work, |
| 166 | struct tps6507x_ts, work.work); | 166 | struct tps6507x_ts, work.work); |
| 167 | struct input_dev *input_dev = tsc->input_dev; | 167 | struct input_dev *input_dev = tsc->input_dev; |
| 168 | int pendown; | 168 | bool pendown; |
| 169 | int schd; | 169 | int schd; |
| 170 | s32 ret; | 170 | s32 ret; |
| 171 | 171 | ||
| 172 | ret = tps6507x_adc_conversion(tsc, TPS6507X_TSCMODE_PRESSURE, | 172 | ret = tps6507x_adc_conversion(tsc, TPS6507X_TSCMODE_PRESSURE, |
| 173 | &tsc->tc.pressure); | 173 | &tsc->tc.pressure); |
| 174 | if (ret) | 174 | if (ret) |
| 175 | goto done; | 175 | goto done; |
| 176 | 176 | ||
| @@ -181,7 +181,7 @@ static void tps6507x_ts_handler(struct work_struct *work) | |||
| 181 | input_report_key(input_dev, BTN_TOUCH, 0); | 181 | input_report_key(input_dev, BTN_TOUCH, 0); |
| 182 | input_report_abs(input_dev, ABS_PRESSURE, 0); | 182 | input_report_abs(input_dev, ABS_PRESSURE, 0); |
| 183 | input_sync(input_dev); | 183 | input_sync(input_dev); |
| 184 | tsc->pendown = 0; | 184 | tsc->pendown = false; |
| 185 | } | 185 | } |
| 186 | 186 | ||
| 187 | if (pendown) { | 187 | if (pendown) { |
| @@ -206,7 +206,7 @@ static void tps6507x_ts_handler(struct work_struct *work) | |||
| 206 | input_report_abs(input_dev, ABS_Y, tsc->tc.y); | 206 | input_report_abs(input_dev, ABS_Y, tsc->tc.y); |
| 207 | input_report_abs(input_dev, ABS_PRESSURE, tsc->tc.pressure); | 207 | input_report_abs(input_dev, ABS_PRESSURE, tsc->tc.pressure); |
| 208 | input_sync(input_dev); | 208 | input_sync(input_dev); |
| 209 | tsc->pendown = 1; | 209 | tsc->pendown = true; |
| 210 | } | 210 | } |
| 211 | 211 | ||
| 212 | done: | 212 | done: |
