diff options
author | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2011-02-01 00:16:22 -0500 |
---|---|---|
committer | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2011-02-01 00:16:22 -0500 |
commit | a1f3d4bba8ea395a39d34ade6017afee8be16031 (patch) | |
tree | 874d843d35622f17aa6c3e048e42cf0d679bcb75 /drivers/input/touchscreen | |
parent | 723d928417bffff6467da155d8ebbbe016464012 (diff) | |
parent | ebf53826e105f488f4f628703a108e98940d1dc5 (diff) |
Merge commit 'v2.6.38-rc3' into next
Diffstat (limited to 'drivers/input/touchscreen')
-rw-r--r-- | drivers/input/touchscreen/Kconfig | 30 | ||||
-rw-r--r-- | drivers/input/touchscreen/bu21013_ts.c | 39 | ||||
-rw-r--r-- | drivers/input/touchscreen/tnetv107x-ts.c | 5 | ||||
-rw-r--r-- | drivers/input/touchscreen/usbtouchscreen.c | 1 |
4 files changed, 55 insertions, 20 deletions
diff --git a/drivers/input/touchscreen/Kconfig b/drivers/input/touchscreen/Kconfig index ec5ee98fa6f6..258e43e98ec3 100644 --- a/drivers/input/touchscreen/Kconfig +++ b/drivers/input/touchscreen/Kconfig | |||
@@ -550,62 +550,62 @@ config TOUCHSCREEN_MC13783 | |||
550 | 550 | ||
551 | config TOUCHSCREEN_USB_EGALAX | 551 | config TOUCHSCREEN_USB_EGALAX |
552 | default y | 552 | default y |
553 | bool "eGalax, eTurboTouch CT-410/510/700 device support" if EMBEDDED | 553 | bool "eGalax, eTurboTouch CT-410/510/700 device support" if EXPERT |
554 | depends on TOUCHSCREEN_USB_COMPOSITE | 554 | depends on TOUCHSCREEN_USB_COMPOSITE |
555 | 555 | ||
556 | config TOUCHSCREEN_USB_PANJIT | 556 | config TOUCHSCREEN_USB_PANJIT |
557 | default y | 557 | default y |
558 | bool "PanJit device support" if EMBEDDED | 558 | bool "PanJit device support" if EXPERT |
559 | depends on TOUCHSCREEN_USB_COMPOSITE | 559 | depends on TOUCHSCREEN_USB_COMPOSITE |
560 | 560 | ||
561 | config TOUCHSCREEN_USB_3M | 561 | config TOUCHSCREEN_USB_3M |
562 | default y | 562 | default y |
563 | bool "3M/Microtouch EX II series device support" if EMBEDDED | 563 | bool "3M/Microtouch EX II series device support" if EXPERT |
564 | depends on TOUCHSCREEN_USB_COMPOSITE | 564 | depends on TOUCHSCREEN_USB_COMPOSITE |
565 | 565 | ||
566 | config TOUCHSCREEN_USB_ITM | 566 | config TOUCHSCREEN_USB_ITM |
567 | default y | 567 | default y |
568 | bool "ITM device support" if EMBEDDED | 568 | bool "ITM device support" if EXPERT |
569 | depends on TOUCHSCREEN_USB_COMPOSITE | 569 | depends on TOUCHSCREEN_USB_COMPOSITE |
570 | 570 | ||
571 | config TOUCHSCREEN_USB_ETURBO | 571 | config TOUCHSCREEN_USB_ETURBO |
572 | default y | 572 | default y |
573 | bool "eTurboTouch (non-eGalax compatible) device support" if EMBEDDED | 573 | bool "eTurboTouch (non-eGalax compatible) device support" if EXPERT |
574 | depends on TOUCHSCREEN_USB_COMPOSITE | 574 | depends on TOUCHSCREEN_USB_COMPOSITE |
575 | 575 | ||
576 | config TOUCHSCREEN_USB_GUNZE | 576 | config TOUCHSCREEN_USB_GUNZE |
577 | default y | 577 | default y |
578 | bool "Gunze AHL61 device support" if EMBEDDED | 578 | bool "Gunze AHL61 device support" if EXPERT |
579 | depends on TOUCHSCREEN_USB_COMPOSITE | 579 | depends on TOUCHSCREEN_USB_COMPOSITE |
580 | 580 | ||
581 | config TOUCHSCREEN_USB_DMC_TSC10 | 581 | config TOUCHSCREEN_USB_DMC_TSC10 |
582 | default y | 582 | default y |
583 | bool "DMC TSC-10/25 device support" if EMBEDDED | 583 | bool "DMC TSC-10/25 device support" if EXPERT |
584 | depends on TOUCHSCREEN_USB_COMPOSITE | 584 | depends on TOUCHSCREEN_USB_COMPOSITE |
585 | 585 | ||
586 | config TOUCHSCREEN_USB_IRTOUCH | 586 | config TOUCHSCREEN_USB_IRTOUCH |
587 | default y | 587 | default y |
588 | bool "IRTOUCHSYSTEMS/UNITOP device support" if EMBEDDED | 588 | bool "IRTOUCHSYSTEMS/UNITOP device support" if EXPERT |
589 | depends on TOUCHSCREEN_USB_COMPOSITE | 589 | depends on TOUCHSCREEN_USB_COMPOSITE |
590 | 590 | ||
591 | config TOUCHSCREEN_USB_IDEALTEK | 591 | config TOUCHSCREEN_USB_IDEALTEK |
592 | default y | 592 | default y |
593 | bool "IdealTEK URTC1000 device support" if EMBEDDED | 593 | bool "IdealTEK URTC1000 device support" if EXPERT |
594 | depends on TOUCHSCREEN_USB_COMPOSITE | 594 | depends on TOUCHSCREEN_USB_COMPOSITE |
595 | 595 | ||
596 | config TOUCHSCREEN_USB_GENERAL_TOUCH | 596 | config TOUCHSCREEN_USB_GENERAL_TOUCH |
597 | default y | 597 | default y |
598 | bool "GeneralTouch Touchscreen device support" if EMBEDDED | 598 | bool "GeneralTouch Touchscreen device support" if EXPERT |
599 | depends on TOUCHSCREEN_USB_COMPOSITE | 599 | depends on TOUCHSCREEN_USB_COMPOSITE |
600 | 600 | ||
601 | config TOUCHSCREEN_USB_GOTOP | 601 | config TOUCHSCREEN_USB_GOTOP |
602 | default y | 602 | default y |
603 | bool "GoTop Super_Q2/GogoPen/PenPower tablet device support" if EMBEDDED | 603 | bool "GoTop Super_Q2/GogoPen/PenPower tablet device support" if EXPERT |
604 | depends on TOUCHSCREEN_USB_COMPOSITE | 604 | depends on TOUCHSCREEN_USB_COMPOSITE |
605 | 605 | ||
606 | config TOUCHSCREEN_USB_JASTEC | 606 | config TOUCHSCREEN_USB_JASTEC |
607 | default y | 607 | default y |
608 | bool "JASTEC/DigiTech DTR-02U USB touch controller device support" if EMBEDDED | 608 | bool "JASTEC/DigiTech DTR-02U USB touch controller device support" if EXPERT |
609 | depends on TOUCHSCREEN_USB_COMPOSITE | 609 | depends on TOUCHSCREEN_USB_COMPOSITE |
610 | 610 | ||
611 | config TOUCHSCREEN_USB_E2I | 611 | config TOUCHSCREEN_USB_E2I |
@@ -615,17 +615,17 @@ config TOUCHSCREEN_USB_E2I | |||
615 | 615 | ||
616 | config TOUCHSCREEN_USB_ZYTRONIC | 616 | config TOUCHSCREEN_USB_ZYTRONIC |
617 | default y | 617 | default y |
618 | bool "Zytronic controller" if EMBEDDED | 618 | bool "Zytronic controller" if EXPERT |
619 | depends on TOUCHSCREEN_USB_COMPOSITE | 619 | depends on TOUCHSCREEN_USB_COMPOSITE |
620 | 620 | ||
621 | config TOUCHSCREEN_USB_ETT_TC45USB | 621 | config TOUCHSCREEN_USB_ETT_TC45USB |
622 | default y | 622 | default y |
623 | bool "ET&T USB series TC4UM/TC5UH touchscreen controler support" if EMBEDDED | 623 | bool "ET&T USB series TC4UM/TC5UH touchscreen controller support" if EXPERT |
624 | depends on TOUCHSCREEN_USB_COMPOSITE | 624 | depends on TOUCHSCREEN_USB_COMPOSITE |
625 | 625 | ||
626 | config TOUCHSCREEN_USB_NEXIO | 626 | config TOUCHSCREEN_USB_NEXIO |
627 | default y | 627 | default y |
628 | bool "NEXIO/iNexio device support" if EMBEDDED | 628 | bool "NEXIO/iNexio device support" if EXPERT |
629 | depends on TOUCHSCREEN_USB_COMPOSITE | 629 | depends on TOUCHSCREEN_USB_COMPOSITE |
630 | 630 | ||
631 | config TOUCHSCREEN_TOUCHIT213 | 631 | config TOUCHSCREEN_TOUCHIT213 |
diff --git a/drivers/input/touchscreen/bu21013_ts.c b/drivers/input/touchscreen/bu21013_ts.c index f7fa9ef4cd65..1507ce108d5b 100644 --- a/drivers/input/touchscreen/bu21013_ts.c +++ b/drivers/input/touchscreen/bu21013_ts.c | |||
@@ -12,6 +12,7 @@ | |||
12 | #include <linux/input.h> | 12 | #include <linux/input.h> |
13 | #include <linux/input/bu21013.h> | 13 | #include <linux/input/bu21013.h> |
14 | #include <linux/slab.h> | 14 | #include <linux/slab.h> |
15 | #include <linux/regulator/consumer.h> | ||
15 | 16 | ||
16 | #define PEN_DOWN_INTR 0 | 17 | #define PEN_DOWN_INTR 0 |
17 | #define MAX_FINGERS 2 | 18 | #define MAX_FINGERS 2 |
@@ -139,6 +140,7 @@ | |||
139 | * @chip: pointer to the touch panel controller | 140 | * @chip: pointer to the touch panel controller |
140 | * @in_dev: pointer to the input device structure | 141 | * @in_dev: pointer to the input device structure |
141 | * @intr_pin: interrupt pin value | 142 | * @intr_pin: interrupt pin value |
143 | * @regulator: pointer to the Regulator used for touch screen | ||
142 | * | 144 | * |
143 | * Touch panel device data structure | 145 | * Touch panel device data structure |
144 | */ | 146 | */ |
@@ -149,6 +151,7 @@ struct bu21013_ts_data { | |||
149 | const struct bu21013_platform_device *chip; | 151 | const struct bu21013_platform_device *chip; |
150 | struct input_dev *in_dev; | 152 | struct input_dev *in_dev; |
151 | unsigned int intr_pin; | 153 | unsigned int intr_pin; |
154 | struct regulator *regulator; | ||
152 | }; | 155 | }; |
153 | 156 | ||
154 | /** | 157 | /** |
@@ -456,6 +459,20 @@ static int __devinit bu21013_probe(struct i2c_client *client, | |||
456 | bu21013_data->in_dev = in_dev; | 459 | bu21013_data->in_dev = in_dev; |
457 | bu21013_data->chip = pdata; | 460 | bu21013_data->chip = pdata; |
458 | bu21013_data->client = client; | 461 | bu21013_data->client = client; |
462 | |||
463 | bu21013_data->regulator = regulator_get(&client->dev, "V-TOUCH"); | ||
464 | if (IS_ERR(bu21013_data->regulator)) { | ||
465 | dev_err(&client->dev, "regulator_get failed\n"); | ||
466 | error = PTR_ERR(bu21013_data->regulator); | ||
467 | goto err_free_mem; | ||
468 | } | ||
469 | |||
470 | error = regulator_enable(bu21013_data->regulator); | ||
471 | if (error < 0) { | ||
472 | dev_err(&client->dev, "regulator enable failed\n"); | ||
473 | goto err_put_regulator; | ||
474 | } | ||
475 | |||
459 | bu21013_data->touch_stopped = false; | 476 | bu21013_data->touch_stopped = false; |
460 | init_waitqueue_head(&bu21013_data->wait); | 477 | init_waitqueue_head(&bu21013_data->wait); |
461 | 478 | ||
@@ -464,7 +481,7 @@ static int __devinit bu21013_probe(struct i2c_client *client, | |||
464 | error = pdata->cs_en(pdata->cs_pin); | 481 | error = pdata->cs_en(pdata->cs_pin); |
465 | if (error < 0) { | 482 | if (error < 0) { |
466 | dev_err(&client->dev, "chip init failed\n"); | 483 | dev_err(&client->dev, "chip init failed\n"); |
467 | goto err_free_mem; | 484 | goto err_disable_regulator; |
468 | } | 485 | } |
469 | } | 486 | } |
470 | 487 | ||
@@ -485,9 +502,9 @@ static int __devinit bu21013_probe(struct i2c_client *client, | |||
485 | __set_bit(EV_ABS, in_dev->evbit); | 502 | __set_bit(EV_ABS, in_dev->evbit); |
486 | 503 | ||
487 | input_set_abs_params(in_dev, ABS_MT_POSITION_X, 0, | 504 | input_set_abs_params(in_dev, ABS_MT_POSITION_X, 0, |
488 | pdata->x_max_res, 0, 0); | 505 | pdata->touch_x_max, 0, 0); |
489 | input_set_abs_params(in_dev, ABS_MT_POSITION_Y, 0, | 506 | input_set_abs_params(in_dev, ABS_MT_POSITION_Y, 0, |
490 | pdata->y_max_res, 0, 0); | 507 | pdata->touch_y_max, 0, 0); |
491 | input_set_drvdata(in_dev, bu21013_data); | 508 | input_set_drvdata(in_dev, bu21013_data); |
492 | 509 | ||
493 | error = request_threaded_irq(pdata->irq, NULL, bu21013_gpio_irq, | 510 | error = request_threaded_irq(pdata->irq, NULL, bu21013_gpio_irq, |
@@ -513,6 +530,10 @@ err_free_irq: | |||
513 | bu21013_free_irq(bu21013_data); | 530 | bu21013_free_irq(bu21013_data); |
514 | err_cs_disable: | 531 | err_cs_disable: |
515 | pdata->cs_dis(pdata->cs_pin); | 532 | pdata->cs_dis(pdata->cs_pin); |
533 | err_disable_regulator: | ||
534 | regulator_disable(bu21013_data->regulator); | ||
535 | err_put_regulator: | ||
536 | regulator_put(bu21013_data->regulator); | ||
516 | err_free_mem: | 537 | err_free_mem: |
517 | input_free_device(in_dev); | 538 | input_free_device(in_dev); |
518 | kfree(bu21013_data); | 539 | kfree(bu21013_data); |
@@ -535,6 +556,10 @@ static int __devexit bu21013_remove(struct i2c_client *client) | |||
535 | bu21013_data->chip->cs_dis(bu21013_data->chip->cs_pin); | 556 | bu21013_data->chip->cs_dis(bu21013_data->chip->cs_pin); |
536 | 557 | ||
537 | input_unregister_device(bu21013_data->in_dev); | 558 | input_unregister_device(bu21013_data->in_dev); |
559 | |||
560 | regulator_disable(bu21013_data->regulator); | ||
561 | regulator_put(bu21013_data->regulator); | ||
562 | |||
538 | kfree(bu21013_data); | 563 | kfree(bu21013_data); |
539 | 564 | ||
540 | device_init_wakeup(&client->dev, false); | 565 | device_init_wakeup(&client->dev, false); |
@@ -561,6 +586,8 @@ static int bu21013_suspend(struct device *dev) | |||
561 | else | 586 | else |
562 | disable_irq(bu21013_data->chip->irq); | 587 | disable_irq(bu21013_data->chip->irq); |
563 | 588 | ||
589 | regulator_disable(bu21013_data->regulator); | ||
590 | |||
564 | return 0; | 591 | return 0; |
565 | } | 592 | } |
566 | 593 | ||
@@ -577,6 +604,12 @@ static int bu21013_resume(struct device *dev) | |||
577 | struct i2c_client *client = bu21013_data->client; | 604 | struct i2c_client *client = bu21013_data->client; |
578 | int retval; | 605 | int retval; |
579 | 606 | ||
607 | retval = regulator_enable(bu21013_data->regulator); | ||
608 | if (retval < 0) { | ||
609 | dev_err(&client->dev, "bu21013 regulator enable failed\n"); | ||
610 | return retval; | ||
611 | } | ||
612 | |||
580 | retval = bu21013_init_chip(bu21013_data); | 613 | retval = bu21013_init_chip(bu21013_data); |
581 | if (retval < 0) { | 614 | if (retval < 0) { |
582 | dev_err(&client->dev, "bu21013 controller config failed\n"); | 615 | dev_err(&client->dev, "bu21013 controller config failed\n"); |
diff --git a/drivers/input/touchscreen/tnetv107x-ts.c b/drivers/input/touchscreen/tnetv107x-ts.c index cf1dba2e267c..22a3411e93c5 100644 --- a/drivers/input/touchscreen/tnetv107x-ts.c +++ b/drivers/input/touchscreen/tnetv107x-ts.c | |||
@@ -14,6 +14,7 @@ | |||
14 | */ | 14 | */ |
15 | 15 | ||
16 | #include <linux/kernel.h> | 16 | #include <linux/kernel.h> |
17 | #include <linux/err.h> | ||
17 | #include <linux/errno.h> | 18 | #include <linux/errno.h> |
18 | #include <linux/input.h> | 19 | #include <linux/input.h> |
19 | #include <linux/platform_device.h> | 20 | #include <linux/platform_device.h> |
@@ -289,9 +290,9 @@ static int __devinit tsc_probe(struct platform_device *pdev) | |||
289 | } | 290 | } |
290 | 291 | ||
291 | ts->clk = clk_get(dev, NULL); | 292 | ts->clk = clk_get(dev, NULL); |
292 | if (!ts->clk) { | 293 | if (IS_ERR(ts->clk)) { |
293 | dev_err(dev, "cannot claim device clock\n"); | 294 | dev_err(dev, "cannot claim device clock\n"); |
294 | error = -EINVAL; | 295 | error = PTR_ERR(ts->clk); |
295 | goto error_clk; | 296 | goto error_clk; |
296 | } | 297 | } |
297 | 298 | ||
diff --git a/drivers/input/touchscreen/usbtouchscreen.c b/drivers/input/touchscreen/usbtouchscreen.c index f45f80f6d336..73fd6642b681 100644 --- a/drivers/input/touchscreen/usbtouchscreen.c +++ b/drivers/input/touchscreen/usbtouchscreen.c | |||
@@ -178,6 +178,7 @@ static const struct usb_device_id usbtouch_devices[] = { | |||
178 | 178 | ||
179 | #ifdef CONFIG_TOUCHSCREEN_USB_ITM | 179 | #ifdef CONFIG_TOUCHSCREEN_USB_ITM |
180 | {USB_DEVICE(0x0403, 0xf9e9), .driver_info = DEVTYPE_ITM}, | 180 | {USB_DEVICE(0x0403, 0xf9e9), .driver_info = DEVTYPE_ITM}, |
181 | {USB_DEVICE(0x16e3, 0xf9e9), .driver_info = DEVTYPE_ITM}, | ||
181 | #endif | 182 | #endif |
182 | 183 | ||
183 | #ifdef CONFIG_TOUCHSCREEN_USB_ETURBO | 184 | #ifdef CONFIG_TOUCHSCREEN_USB_ETURBO |