diff options
author | Henrik Rydberg <rydberg@euromail.se> | 2012-08-11 16:07:55 -0400 |
---|---|---|
committer | Henrik Rydberg <rydberg@euromail.se> | 2012-09-19 13:50:18 -0400 |
commit | b4adbbefc2099476a4f1020041c99f52cf3cd67d (patch) | |
tree | ba9ca0069c7375a99fa0a9f2728b445f3ae5a096 /drivers/input/touchscreen | |
parent | a274ac15ed069bae4118e3251359240379b6801b (diff) |
Input: MT - Add flags to input_mt_init_slots()
Preparing to move more repeated code into the mt core, add a flags
argument to the input_mt_slots_init() function.
Reviewed-and-tested-by: Benjamin Tissoires <benjamin.tissoires@enac.fr>
Tested-by: Ping Cheng <pingc@wacom.com>
Acked-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Signed-off-by: Henrik Rydberg <rydberg@euromail.se>
Diffstat (limited to 'drivers/input/touchscreen')
-rw-r--r-- | drivers/input/touchscreen/atmel_mxt_ts.c | 2 | ||||
-rw-r--r-- | drivers/input/touchscreen/cyttsp_core.c | 2 | ||||
-rw-r--r-- | drivers/input/touchscreen/edt-ft5x06.c | 2 | ||||
-rw-r--r-- | drivers/input/touchscreen/egalax_ts.c | 2 | ||||
-rw-r--r-- | drivers/input/touchscreen/ili210x.c | 2 | ||||
-rw-r--r-- | drivers/input/touchscreen/mms114.c | 2 | ||||
-rw-r--r-- | drivers/input/touchscreen/penmount.c | 2 | ||||
-rw-r--r-- | drivers/input/touchscreen/wacom_w8001.c | 2 |
8 files changed, 8 insertions, 8 deletions
diff --git a/drivers/input/touchscreen/atmel_mxt_ts.c b/drivers/input/touchscreen/atmel_mxt_ts.c index 4623cc69fc60..e92615d0b1b0 100644 --- a/drivers/input/touchscreen/atmel_mxt_ts.c +++ b/drivers/input/touchscreen/atmel_mxt_ts.c | |||
@@ -1152,7 +1152,7 @@ static int __devinit mxt_probe(struct i2c_client *client, | |||
1152 | 1152 | ||
1153 | /* For multi touch */ | 1153 | /* For multi touch */ |
1154 | num_mt_slots = data->T9_reportid_max - data->T9_reportid_min + 1; | 1154 | num_mt_slots = data->T9_reportid_max - data->T9_reportid_min + 1; |
1155 | error = input_mt_init_slots(input_dev, num_mt_slots); | 1155 | error = input_mt_init_slots(input_dev, num_mt_slots, 0); |
1156 | if (error) | 1156 | if (error) |
1157 | goto err_free_object; | 1157 | goto err_free_object; |
1158 | input_set_abs_params(input_dev, ABS_MT_TOUCH_MAJOR, | 1158 | input_set_abs_params(input_dev, ABS_MT_TOUCH_MAJOR, |
diff --git a/drivers/input/touchscreen/cyttsp_core.c b/drivers/input/touchscreen/cyttsp_core.c index f030d9ec795d..8e60437ac85b 100644 --- a/drivers/input/touchscreen/cyttsp_core.c +++ b/drivers/input/touchscreen/cyttsp_core.c | |||
@@ -571,7 +571,7 @@ struct cyttsp *cyttsp_probe(const struct cyttsp_bus_ops *bus_ops, | |||
571 | input_set_abs_params(input_dev, ABS_MT_TOUCH_MAJOR, | 571 | input_set_abs_params(input_dev, ABS_MT_TOUCH_MAJOR, |
572 | 0, CY_MAXZ, 0, 0); | 572 | 0, CY_MAXZ, 0, 0); |
573 | 573 | ||
574 | input_mt_init_slots(input_dev, CY_MAX_ID); | 574 | input_mt_init_slots(input_dev, CY_MAX_ID, 0); |
575 | 575 | ||
576 | error = request_threaded_irq(ts->irq, NULL, cyttsp_irq, | 576 | error = request_threaded_irq(ts->irq, NULL, cyttsp_irq, |
577 | IRQF_TRIGGER_FALLING | IRQF_ONESHOT, | 577 | IRQF_TRIGGER_FALLING | IRQF_ONESHOT, |
diff --git a/drivers/input/touchscreen/edt-ft5x06.c b/drivers/input/touchscreen/edt-ft5x06.c index 9afc777a40a7..7b786e757ba2 100644 --- a/drivers/input/touchscreen/edt-ft5x06.c +++ b/drivers/input/touchscreen/edt-ft5x06.c | |||
@@ -778,7 +778,7 @@ static int __devinit edt_ft5x06_ts_probe(struct i2c_client *client, | |||
778 | 0, tsdata->num_x * 64 - 1, 0, 0); | 778 | 0, tsdata->num_x * 64 - 1, 0, 0); |
779 | input_set_abs_params(input, ABS_MT_POSITION_Y, | 779 | input_set_abs_params(input, ABS_MT_POSITION_Y, |
780 | 0, tsdata->num_y * 64 - 1, 0, 0); | 780 | 0, tsdata->num_y * 64 - 1, 0, 0); |
781 | error = input_mt_init_slots(input, MAX_SUPPORT_POINTS); | 781 | error = input_mt_init_slots(input, MAX_SUPPORT_POINTS, 0); |
782 | if (error) { | 782 | if (error) { |
783 | dev_err(&client->dev, "Unable to init MT slots.\n"); | 783 | dev_err(&client->dev, "Unable to init MT slots.\n"); |
784 | goto err_free_mem; | 784 | goto err_free_mem; |
diff --git a/drivers/input/touchscreen/egalax_ts.c b/drivers/input/touchscreen/egalax_ts.c index 70524dd34f42..c1e3460f1195 100644 --- a/drivers/input/touchscreen/egalax_ts.c +++ b/drivers/input/touchscreen/egalax_ts.c | |||
@@ -204,7 +204,7 @@ static int __devinit egalax_ts_probe(struct i2c_client *client, | |||
204 | ABS_MT_POSITION_X, 0, EGALAX_MAX_X, 0, 0); | 204 | ABS_MT_POSITION_X, 0, EGALAX_MAX_X, 0, 0); |
205 | input_set_abs_params(input_dev, | 205 | input_set_abs_params(input_dev, |
206 | ABS_MT_POSITION_X, 0, EGALAX_MAX_Y, 0, 0); | 206 | ABS_MT_POSITION_X, 0, EGALAX_MAX_Y, 0, 0); |
207 | input_mt_init_slots(input_dev, MAX_SUPPORT_POINTS); | 207 | input_mt_init_slots(input_dev, MAX_SUPPORT_POINTS, 0); |
208 | 208 | ||
209 | input_set_drvdata(input_dev, ts); | 209 | input_set_drvdata(input_dev, ts); |
210 | 210 | ||
diff --git a/drivers/input/touchscreen/ili210x.c b/drivers/input/touchscreen/ili210x.c index c0044175a921..4ac69760ec08 100644 --- a/drivers/input/touchscreen/ili210x.c +++ b/drivers/input/touchscreen/ili210x.c | |||
@@ -252,7 +252,7 @@ static int __devinit ili210x_i2c_probe(struct i2c_client *client, | |||
252 | input_set_abs_params(input, ABS_Y, 0, ymax, 0, 0); | 252 | input_set_abs_params(input, ABS_Y, 0, ymax, 0, 0); |
253 | 253 | ||
254 | /* Multi touch */ | 254 | /* Multi touch */ |
255 | input_mt_init_slots(input, MAX_TOUCHES); | 255 | input_mt_init_slots(input, MAX_TOUCHES, 0); |
256 | input_set_abs_params(input, ABS_MT_POSITION_X, 0, xmax, 0, 0); | 256 | input_set_abs_params(input, ABS_MT_POSITION_X, 0, xmax, 0, 0); |
257 | input_set_abs_params(input, ABS_MT_POSITION_Y, 0, ymax, 0, 0); | 257 | input_set_abs_params(input, ABS_MT_POSITION_Y, 0, ymax, 0, 0); |
258 | 258 | ||
diff --git a/drivers/input/touchscreen/mms114.c b/drivers/input/touchscreen/mms114.c index 49c44bbf548d..560cf09d1c5a 100644 --- a/drivers/input/touchscreen/mms114.c +++ b/drivers/input/touchscreen/mms114.c | |||
@@ -404,7 +404,7 @@ static int __devinit mms114_probe(struct i2c_client *client, | |||
404 | input_set_abs_params(input_dev, ABS_Y, 0, data->pdata->y_size, 0, 0); | 404 | input_set_abs_params(input_dev, ABS_Y, 0, data->pdata->y_size, 0, 0); |
405 | 405 | ||
406 | /* For multi touch */ | 406 | /* For multi touch */ |
407 | input_mt_init_slots(input_dev, MMS114_MAX_TOUCH); | 407 | input_mt_init_slots(input_dev, MMS114_MAX_TOUCH, 0); |
408 | input_set_abs_params(input_dev, ABS_MT_TOUCH_MAJOR, | 408 | input_set_abs_params(input_dev, ABS_MT_TOUCH_MAJOR, |
409 | 0, MMS114_MAX_AREA, 0, 0); | 409 | 0, MMS114_MAX_AREA, 0, 0); |
410 | input_set_abs_params(input_dev, ABS_MT_POSITION_X, | 410 | input_set_abs_params(input_dev, ABS_MT_POSITION_X, |
diff --git a/drivers/input/touchscreen/penmount.c b/drivers/input/touchscreen/penmount.c index 4ccde45b9da2..b49f0b836925 100644 --- a/drivers/input/touchscreen/penmount.c +++ b/drivers/input/touchscreen/penmount.c | |||
@@ -264,7 +264,7 @@ static int pm_connect(struct serio *serio, struct serio_driver *drv) | |||
264 | input_set_abs_params(pm->dev, ABS_Y, 0, max_y, 0, 0); | 264 | input_set_abs_params(pm->dev, ABS_Y, 0, max_y, 0, 0); |
265 | 265 | ||
266 | if (pm->maxcontacts > 1) { | 266 | if (pm->maxcontacts > 1) { |
267 | input_mt_init_slots(pm->dev, pm->maxcontacts); | 267 | input_mt_init_slots(pm->dev, pm->maxcontacts, 0); |
268 | input_set_abs_params(pm->dev, | 268 | input_set_abs_params(pm->dev, |
269 | ABS_MT_POSITION_X, 0, max_x, 0, 0); | 269 | ABS_MT_POSITION_X, 0, max_x, 0, 0); |
270 | input_set_abs_params(pm->dev, | 270 | input_set_abs_params(pm->dev, |
diff --git a/drivers/input/touchscreen/wacom_w8001.c b/drivers/input/touchscreen/wacom_w8001.c index 8f9ad2f893b8..9a83be6b6584 100644 --- a/drivers/input/touchscreen/wacom_w8001.c +++ b/drivers/input/touchscreen/wacom_w8001.c | |||
@@ -471,7 +471,7 @@ static int w8001_setup(struct w8001 *w8001) | |||
471 | case 5: | 471 | case 5: |
472 | w8001->pktlen = W8001_PKTLEN_TOUCH2FG; | 472 | w8001->pktlen = W8001_PKTLEN_TOUCH2FG; |
473 | 473 | ||
474 | input_mt_init_slots(dev, 2); | 474 | input_mt_init_slots(dev, 2, 0); |
475 | input_set_abs_params(dev, ABS_MT_POSITION_X, | 475 | input_set_abs_params(dev, ABS_MT_POSITION_X, |
476 | 0, touch.x, 0, 0); | 476 | 0, touch.x, 0, 0); |
477 | input_set_abs_params(dev, ABS_MT_POSITION_Y, | 477 | input_set_abs_params(dev, ABS_MT_POSITION_Y, |