LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
From: Dmitry Torokhov <dmitry.torokhov@gmail.com>
To: phoenix <phoenix@emc.com.tw>
Cc: linux-kernel@vger.kernel.org, linux-input@vger.kernel.org,
jingle.wu@emc.com.tw, josh.chen@emc.com.tw, dave.wang@emc.com.tw
Subject: Re: [PATCH] Input: elantench - Fix the firmware misreport coordinates for trackpoint occasionally.
Date: Mon, 30 Aug 2021 13:23:41 -0700 [thread overview]
Message-ID: <YS0+TU21/nok6Ge9@google.com> (raw)
In-Reply-To: <000001d79d99$53762dd0$fa628970$@emc.com.tw>
Hi Phoenix,
On Mon, Aug 30, 2021 at 08:19:48PM +0800, phoenix wrote:
> Hi Dmitry,
>
> Would you review this patch, thanks
>
> Best regards,
> Phoenix Huang
>
> -----Original Message-----
> From: Phoenix Huang [mailto:phoenix@emc.com.tw]
> Sent: Thursday, July 29, 2021 9:10 AM
> To: linux-kernel@vger.kernel.org; linux-input@vger.kernel.org;
> dmitry.torokhov@gmail.com
> Cc: jingle.wu@emc.com.tw; josh.chen@emc.com.tw; dave.wang@emc.com.tw;
> Phoenix Huang <phoenix@emc.com.tw>
> Subject: [PATCH] Input: elantench - Fix the firmware misreport coordinates
> for trackpoint occasionally.
>
> Signed-off-by: Phoenix Huang <phoenix@emc.com.tw>
> ---
> drivers/input/mouse/elantech.c | 11 +++++++++++
> 1 file changed, 11 insertions(+)
>
> diff --git a/drivers/input/mouse/elantech.c b/drivers/input/mouse/elantech.c
> index 2d0bc029619f..07e1098f2d31 100644
> --- a/drivers/input/mouse/elantech.c
> +++ b/drivers/input/mouse/elantech.c
> @@ -517,6 +517,17 @@ static void elantech_report_trackpoint(struct psmouse
> *psmouse,
> case 0x16008020U:
> case 0x26800010U:
> case 0x36808000U:
> +
> + /* This firmware misreport coordinates for trackpoint
> occasionally.
> + * So we discard these packets by pattern to prevent cursor
> jumps.
> + */
> + if (packet[4] == 0x80 || packet[5] == 0x80 ||
> + packet[1] >> 7 == packet[4] >> 7 ||
I think this will reject X coordinates in range [0, 127]. Is this really
what is needed? What kind of patterns are you observing when firmware
misreports coordinates?
Thanks.
--
Dmitry
next prev parent reply other threads:[~2021-08-30 20:23 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-07-29 1:09 Phoenix Huang
2021-08-30 12:19 ` phoenix
2021-08-30 20:23 ` Dmitry Torokhov [this message]
2021-09-10 2:18 ` phoenix
2021-11-07 20:02 ` Yufei Du
2021-11-08 6:06 ` Dmitry Torokhov
2021-11-08 6:14 ` Yufei Du
2021-11-10 6:24 ` Dmitry Torokhov
-- strict thread matches above, loose matches on Subject: below --
2021-07-29 1:03 Phoenix Huang
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=YS0+TU21/nok6Ge9@google.com \
--to=dmitry.torokhov@gmail.com \
--cc=dave.wang@emc.com.tw \
--cc=jingle.wu@emc.com.tw \
--cc=josh.chen@emc.com.tw \
--cc=linux-input@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=phoenix@emc.com.tw \
--subject='Re: [PATCH] Input: elantench - Fix the firmware misreport coordinates for trackpoint occasionally.' \
/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
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).