linux-input.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: simon.budig@kernelconcepts.de
To: linux-input@vger.kernel.org
Cc: dmitry.torokhov@gmail.com, Simon Budig <simon.budig@kernelconcepts.de>
Subject: [PATCH 1/3] edt-ft5x06: fix reset pin behaviour
Date: Thu,  5 Oct 2017 17:35:06 +0200	[thread overview]
Message-ID: <20171005153508.32127-1-simon.budig@kernelconcepts.de> (raw)
In-Reply-To: <1507217501.7345.9.camel@kernelconcepts.de>

From: Simon Budig <simon.budig@kernelconcepts.de>

For some reason the reset pin no longer gets toggeled when initializing
the touch. Fix that and restore the old behaviour.

Signed-off-by: Simon Budig <simon.budig@kernelconcepts.de>
---
 drivers/input/touchscreen/edt-ft5x06.c | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/drivers/input/touchscreen/edt-ft5x06.c b/drivers/input/touchscreen/edt-ft5x06.c
index 5bf63f7..867a61e 100644
--- a/drivers/input/touchscreen/edt-ft5x06.c
+++ b/drivers/input/touchscreen/edt-ft5x06.c
@@ -936,8 +936,12 @@ static int edt_ft5x06_ts_probe(struct i2c_client *client,
 
 	if (tsdata->reset_gpio) {
 		usleep_range(5000, 6000);
-		gpiod_set_value_cansleep(tsdata->reset_gpio, 0);
+		/* note that the reset pin needs to be registered as
+		 * active low in the devicetree.
+		 */
+		gpiod_set_value_cansleep(tsdata->reset_gpio, 1);
 		msleep(300);
+		gpiod_set_value_cansleep(tsdata->reset_gpio, 0);
 	}
 
 	input = devm_input_allocate_device(&client->dev);
-- 
2.1.4


  reply	other threads:[~2017-10-05 15:40 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-10-05 15:31 [Patch 0/3] Some updates to the edt-ft5x06 driver Simon Budig
2017-10-05 15:35 ` simon.budig [this message]
2017-10-05 15:35   ` [PATCH 2/3] input: edt-ft5x06: make distinction between m06/m09/generic more clear simon.budig
2017-10-05 15:35   ` [PATCH 3/3] input: edt-ft5x06: implement support for the EDT-M12 series simon.budig
2017-10-10  3:58   ` [PATCH 1/3] edt-ft5x06: fix reset pin behaviour Dmitry Torokhov
2017-10-10 10:25     ` Simon Budig
2017-10-10 10:39       ` Simon Budig
  -- strict thread matches above, loose matches on Subject: below --
2017-10-05 15:19 simon.budig
2017-10-05 15:22 ` Simon Budig

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20171005153508.32127-1-simon.budig@kernelconcepts.de \
    --to=simon.budig@kernelconcepts.de \
    --cc=dmitry.torokhov@gmail.com \
    --cc=linux-input@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).