diff options
author | Daniel Mack <daniel@caiaq.de> | 2010-08-02 23:15:17 -0400 |
---|---|---|
committer | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2010-08-02 23:29:56 -0400 |
commit | 987a6c0298260b7aa40702b349282554d6180e4b (patch) | |
tree | 29d0873435221a6d731267efc2412814440e4a28 /drivers/input/mouse | |
parent | 7957e9c4d175cc065f4277211fcb7d784fcee860 (diff) |
Input: switch to input_abs_*() access functions
Change all call sites in drivers/input to not access the ABS axis
information directly anymore. Make them use the access helpers instead.
Also use input_set_abs_params() when possible.
Did some code refactoring as I was on it.
Signed-off-by: Daniel Mack <daniel@caiaq.de>
Cc: Dmitry Torokhov <dtor@mail.ru>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Diffstat (limited to 'drivers/input/mouse')
-rw-r--r-- | drivers/input/mouse/pc110pad.c | 4 | ||||
-rw-r--r-- | drivers/input/mouse/synaptics.c | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/drivers/input/mouse/pc110pad.c b/drivers/input/mouse/pc110pad.c index 3941f97cfa60..7b02b652e267 100644 --- a/drivers/input/mouse/pc110pad.c +++ b/drivers/input/mouse/pc110pad.c | |||
@@ -145,8 +145,8 @@ static int __init pc110pad_init(void) | |||
145 | pc110pad_dev->absbit[0] = BIT_MASK(ABS_X) | BIT_MASK(ABS_Y); | 145 | pc110pad_dev->absbit[0] = BIT_MASK(ABS_X) | BIT_MASK(ABS_Y); |
146 | pc110pad_dev->keybit[BIT_WORD(BTN_TOUCH)] = BIT_MASK(BTN_TOUCH); | 146 | pc110pad_dev->keybit[BIT_WORD(BTN_TOUCH)] = BIT_MASK(BTN_TOUCH); |
147 | 147 | ||
148 | pc110pad_dev->absmax[ABS_X] = 0x1ff; | 148 | input_abs_set_max(pc110pad_dev, ABS_X, 0x1ff); |
149 | pc110pad_dev->absmax[ABS_Y] = 0x0ff; | 149 | input_abs_set_max(pc110pad_dev, ABS_Y, 0x0ff); |
150 | 150 | ||
151 | pc110pad_dev->open = pc110pad_open; | 151 | pc110pad_dev->open = pc110pad_open; |
152 | pc110pad_dev->close = pc110pad_close; | 152 | pc110pad_dev->close = pc110pad_close; |
diff --git a/drivers/input/mouse/synaptics.c b/drivers/input/mouse/synaptics.c index 85a1e1460996..2bf93432b8c0 100644 --- a/drivers/input/mouse/synaptics.c +++ b/drivers/input/mouse/synaptics.c | |||
@@ -629,8 +629,8 @@ static void set_input_params(struct input_dev *dev, struct synaptics_data *priv) | |||
629 | __clear_bit(REL_X, dev->relbit); | 629 | __clear_bit(REL_X, dev->relbit); |
630 | __clear_bit(REL_Y, dev->relbit); | 630 | __clear_bit(REL_Y, dev->relbit); |
631 | 631 | ||
632 | dev->absres[ABS_X] = priv->x_res; | 632 | input_abs_set_res(dev, ABS_X, priv->x_res); |
633 | dev->absres[ABS_Y] = priv->y_res; | 633 | input_abs_set_res(dev, ABS_Y, priv->y_res); |
634 | 634 | ||
635 | if (SYN_CAP_CLICKPAD(priv->ext_cap_0c)) { | 635 | if (SYN_CAP_CLICKPAD(priv->ext_cap_0c)) { |
636 | /* Clickpads report only left button */ | 636 | /* Clickpads report only left button */ |