aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/input
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/input')
-rw-r--r--drivers/input/touchscreen/wm97xx-core.c22
1 files changed, 11 insertions, 11 deletions
diff --git a/drivers/input/touchscreen/wm97xx-core.c b/drivers/input/touchscreen/wm97xx-core.c
index 8a00918cfa46..cdc24ad314e0 100644
--- a/drivers/input/touchscreen/wm97xx-core.c
+++ b/drivers/input/touchscreen/wm97xx-core.c
@@ -608,6 +608,17 @@ static int wm97xx_probe(struct device *dev)
608 goto alloc_err; 608 goto alloc_err;
609 } 609 }
610 610
611 /* set up physical characteristics */
612 wm->codec->phy_init(wm);
613
614 /* load gpio cache */
615 wm->gpio[0] = wm97xx_reg_read(wm, AC97_GPIO_CFG);
616 wm->gpio[1] = wm97xx_reg_read(wm, AC97_GPIO_POLARITY);
617 wm->gpio[2] = wm97xx_reg_read(wm, AC97_GPIO_STICKY);
618 wm->gpio[3] = wm97xx_reg_read(wm, AC97_GPIO_WAKEUP);
619 wm->gpio[4] = wm97xx_reg_read(wm, AC97_GPIO_STATUS);
620 wm->gpio[5] = wm97xx_reg_read(wm, AC97_MISC_AFE);
621
611 wm->input_dev = input_allocate_device(); 622 wm->input_dev = input_allocate_device();
612 if (wm->input_dev == NULL) { 623 if (wm->input_dev == NULL) {
613 ret = -ENOMEM; 624 ret = -ENOMEM;
@@ -635,17 +646,6 @@ static int wm97xx_probe(struct device *dev)
635 if (ret < 0) 646 if (ret < 0)
636 goto dev_alloc_err; 647 goto dev_alloc_err;
637 648
638 /* set up physical characteristics */
639 wm->codec->phy_init(wm);
640
641 /* load gpio cache */
642 wm->gpio[0] = wm97xx_reg_read(wm, AC97_GPIO_CFG);
643 wm->gpio[1] = wm97xx_reg_read(wm, AC97_GPIO_POLARITY);
644 wm->gpio[2] = wm97xx_reg_read(wm, AC97_GPIO_STICKY);
645 wm->gpio[3] = wm97xx_reg_read(wm, AC97_GPIO_WAKEUP);
646 wm->gpio[4] = wm97xx_reg_read(wm, AC97_GPIO_STATUS);
647 wm->gpio[5] = wm97xx_reg_read(wm, AC97_MISC_AFE);
648
649 /* register our battery device */ 649 /* register our battery device */
650 wm->battery_dev = platform_device_alloc("wm97xx-battery", -1); 650 wm->battery_dev = platform_device_alloc("wm97xx-battery", -1);
651 if (!wm->battery_dev) { 651 if (!wm->battery_dev) {