projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
ebcaaad
)
Input: ads7846 - fix gpio_pendown configuration
author
Igor Grinberg
<
[email protected]
>
Wed, 11 May 2011 22:45:05 +0000
(15:45 -0700)
committer
Dmitry Torokhov
<
[email protected]
>
Thu, 12 May 2011 15:28:57 +0000
(08:28 -0700)
The pendown gpio was requested but not configured for input.
Configure it for input.
Signed-off-by: Igor Grinberg <
[email protected]
>
Signed-off-by: Dmitry Torokhov <
[email protected]
>
drivers/input/touchscreen/ads7846.c
patch
|
blob
|
history
diff --git
a/drivers/input/touchscreen/ads7846.c
b/drivers/input/touchscreen/ads7846.c
index e4ee43e159d2d0b761e0ec61038281cd4043a540..beb754ff931b2abc114a89ec2fd939510132e77b 100644
(file)
--- a/
drivers/input/touchscreen/ads7846.c
+++ b/
drivers/input/touchscreen/ads7846.c
@@
-966,6
+966,13
@@
static int __devinit ads7846_setup_pendown(struct spi_device *spi, struct ads784
pdata->gpio_pendown);
return err;
}
+ err = gpio_direction_input(pdata->gpio_pendown);
+ if (err) {
+ dev_err(&spi->dev, "failed to setup pendown GPIO%d\n",
+ pdata->gpio_pendown);
+ gpio_free(pdata->gpio_pendown);
+ return err;
+ }
ts->gpio_pendown = pdata->gpio_pendown;