From: Dmitry Torokhov <dmitry.torokhov@gmail.com>
To: "Mylène Josserand" <mylene.josserand@bootlin.com>
Cc: robh+dt@kernel.org, mark.rutland@arm.com,
maxime.ripard@bootlin.com, wens@csie.org,
linux-input@vger.kernel.org, devicetree@vger.kernel.org,
linux-kernel@vger.kernel.org,
linux-arm-kernel@lists.infradead.org,
thomas.petazzoni@bootlin.com
Subject: Re: [PATCH v4 2/3] Input: edt-ft5x06 - Set wake/reset values on resume/suspend
Date: Wed, 25 Jul 2018 17:52:12 -0700 [thread overview]
Message-ID: <20180726005212.GE80336@dtor-ws> (raw)
In-Reply-To: <20180725073410.730-3-mylene.josserand@bootlin.com>
Hi Mylène,
On Wed, Jul 25, 2018 at 09:34:09AM +0200, Mylène Josserand wrote:
> On resume and suspend, set the value of wake and reset gpios
> to be sure that we are in a know state after suspending/resuming.
>
> Signed-off-by: Mylène Josserand <mylene.josserand@bootlin.com>
> ---
> drivers/input/touchscreen/edt-ft5x06.c | 12 ++++++++++++
> 1 file changed, 12 insertions(+)
>
> diff --git a/drivers/input/touchscreen/edt-ft5x06.c b/drivers/input/touchscreen/edt-ft5x06.c
> index dcde719094f7..dad2f1f8bf89 100644
> --- a/drivers/input/touchscreen/edt-ft5x06.c
> +++ b/drivers/input/touchscreen/edt-ft5x06.c
> @@ -1158,6 +1158,12 @@ static int __maybe_unused edt_ft5x06_ts_suspend(struct device *dev)
> else
> regulator_disable(tsdata->vcc);
>
> + if (tsdata->wake_gpio)
> + gpiod_set_value(tsdata->wake_gpio, 0);
> +
> + if (tsdata->reset_gpio)
> + gpiod_set_value(tsdata->reset_gpio, 1);
Ondřej mentioned in previous review that if you power off the controller
it will not be able to wake up the system, and you had to move call to
regulator_disable() into "else" branch of check whether the controller
is a wakeup device. Guess what happens if you unconditionally put the
device into reset state?
Thanks.
--
Dmitry
next prev parent reply other threads:[~2018-07-26 0:52 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-07-25 7:34 [PATCH v4 0/3] sun8i-a83t: Add touchscreen support on TBS A711 Mylène Josserand
2018-07-25 7:34 ` [PATCH v4 1/3] Input: edt-ft5x06 - Add support for regulator Mylène Josserand
2018-07-26 0:47 ` Dmitry Torokhov
2018-08-07 6:59 ` Mylène Josserand
2018-08-23 0:48 ` Dmitry Torokhov
2018-07-25 7:34 ` [PATCH v4 2/3] Input: edt-ft5x06 - Set wake/reset values on resume/suspend Mylène Josserand
2018-07-26 0:52 ` Dmitry Torokhov [this message]
2018-07-25 7:34 ` [PATCH v4 3/3] arm: dts: sun8i: a83t: a711: Add touchscreen node Mylène Josserand
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=20180726005212.GE80336@dtor-ws \
--to=dmitry.torokhov@gmail.com \
--cc=devicetree@vger.kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-input@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=mark.rutland@arm.com \
--cc=maxime.ripard@bootlin.com \
--cc=mylene.josserand@bootlin.com \
--cc=robh+dt@kernel.org \
--cc=thomas.petazzoni@bootlin.com \
--cc=wens@csie.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).