From: Dmitry Torokhov <dmitry.torokhov@gmail.com>
To: Benson Leung <bleung@google.com>
Cc: Dudley Du <dudl@cypress.com>,
"linux-input@vger.kernel.org" <linux-input@vger.kernel.org>,
"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] input: cyapa: fix update suspend scanrate set to max 1000 issue
Date: Mon, 20 Apr 2015 10:04:15 -0700 [thread overview]
Message-ID: <20150420170415.GA21614@dtor-ws> (raw)
In-Reply-To: <CANLzEkuuQZ4MNT0tZLkU8sx3u8FGxm6ZBK46tRGczzP=LiPr4w@mail.gmail.com>
On Mon, Apr 20, 2015 at 10:00:42AM -0700, Benson Leung wrote:
> Hi Dudley.
>
> Just a minor commit message nit. Thanks!
>
> On Sun, Apr 19, 2015 at 10:43 PM, Dudley Du <dudl@cypress.com> wrote:
> > Fix update suspend scareate always set to max 1000 issue, the root cause is
> s/scareate/scanrate
> > the missed using max_t as min_t.
> > TEST=test on Chromebook.
> >
> > Signed-off-by: Dudley Du <dudl@cypress.com>
>
> Reviewed-by: Benson Leung <bleung@chromium.org>
Applied, thank you.
>
> > ---
> > drivers/input/mouse/cyapa.c | 4 ++--
> > 1 file changed, 2 insertions(+), 2 deletions(-)
> >
> > diff --git a/drivers/input/mouse/cyapa.c b/drivers/input/mouse/cyapa.c
> > index 58f4f6f..efe1484 100644
> > --- a/drivers/input/mouse/cyapa.c
> > +++ b/drivers/input/mouse/cyapa.c
> > @@ -723,7 +723,7 @@ static ssize_t cyapa_update_suspend_scanrate(struct device *dev,
> > } else if (sysfs_streq(buf, OFF_MODE_NAME)) {
> > cyapa->suspend_power_mode = PWR_MODE_OFF;
> > } else if (!kstrtou16(buf, 10, &sleep_time)) {
> > - cyapa->suspend_sleep_time = max_t(u16, sleep_time, 1000);
> > + cyapa->suspend_sleep_time = min_t(u16, sleep_time, 1000);
> > cyapa->suspend_power_mode =
> > cyapa_sleep_time_to_pwr_cmd(cyapa->suspend_sleep_time);
> > } else {
> > @@ -840,7 +840,7 @@ static ssize_t cyapa_update_rt_suspend_scanrate(struct device *dev,
> > if (error)
> > return error;
> >
> > - cyapa->runtime_suspend_sleep_time = max_t(u16, time, 1000);
> > + cyapa->runtime_suspend_sleep_time = min_t(u16, time, 1000);
> > cyapa->runtime_suspend_power_mode =
> > cyapa_sleep_time_to_pwr_cmd(cyapa->runtime_suspend_sleep_time);
> >
> > --
> > 1.9.1
> >
>
>
>
> --
> Benson Leung
> Software Engineer, Chrome OS
> Google Inc.
> bleung@google.com
--
Dmitry
prev parent reply other threads:[~2015-04-20 17:04 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-04-20 5:43 [PATCH] input: cyapa: fix update suspend scanrate set to max 1000 issue Dudley Du
2015-04-20 17:00 ` Benson Leung
2015-04-20 17:04 ` Dmitry Torokhov [this message]
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=20150420170415.GA21614@dtor-ws \
--to=dmitry.torokhov@gmail.com \
--cc=bleung@google.com \
--cc=dudl@cypress.com \
--cc=linux-input@vger.kernel.org \
--cc=linux-kernel@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).