From: Loic Poulain <loic.poulain@linaro.org>
To: dmitry.torokhov@gmail.com
Cc: aduggan@synaptics.com, linux-input@vger.kernel.org,
Loic Poulain <loic.poulain@linaro.org>
Subject: [PATCH] Input: synaptics-rmi4 - Fix doze-holdoff value
Date: Thu, 28 Oct 2021 11:33:37 +0200 [thread overview]
Message-ID: <1635413617-2869-1-git-send-email-loic.poulain@linaro.org> (raw)
doze-holdoff is in 100ms unit not 10us.
Fixes: d8a8b3edfd92 ("Input: synaptics-rmi4 - add device tree support for RMI4 I2C devices")
Signed-off-by: Loic Poulain <loic.poulain@linaro.org>
---
drivers/input/rmi4/rmi_f01.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/drivers/input/rmi4/rmi_f01.c b/drivers/input/rmi4/rmi_f01.c
index d7603c5..e90c618 100644
--- a/drivers/input/rmi4/rmi_f01.c
+++ b/drivers/input/rmi4/rmi_f01.c
@@ -362,13 +362,15 @@ static int rmi_f01_of_probe(struct device *dev,
if (retval)
return retval;
- pdata->power_management.doze_holdoff = val * 100;
+ /* Doze holdoff is in 100ms unit */
+ pdata->power_management.doze_holdoff = val / 100;
retval = rmi_of_property_read_u32(dev, &val,
"syna,doze-interval-ms", 1);
if (retval)
return retval;
+ /* Doze interval is in 10ms unit */
pdata->power_management.doze_interval = val / 10;
return 0;
--
2.7.4
reply other threads:[~2021-10-28 9:22 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=1635413617-2869-1-git-send-email-loic.poulain@linaro.org \
--to=loic.poulain@linaro.org \
--cc=aduggan@synaptics.com \
--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).