From: Jason Gerecke <killertofu@gmail.com>
To: Dan Carpenter <dan.carpenter@oracle.com>, Jiri Kosina <jikos@kernel.org>
Cc: Benjamin Tissoires <benjamin.tissoires@redhat.com>,
Henrik Rydberg <rydberg@bitmath.org>,
linux-input@vger.kernel.org, linux-kernel@vger.kernel.org,
kernel-janitors@vger.kernel.org
Subject: Re: [patch] HID: wacom: Don't clear bits unintentionally
Date: Mon, 14 Nov 2016 18:31:52 +0000 [thread overview]
Message-ID: <56caefcd-93d6-201d-f597-2d651cbe68ba@gmail.com> (raw)
In-Reply-To: <20161110192539.GA32533@mwanda>
On 11/10/2016 11:25 AM, Dan Carpenter wrote:
> This is trying to clear the lower 32 bits but the type is wrong so it
> clears everything.
>
> Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
>
Reviewed-by: Jason Gerecke <jason.gerecke@wacom.com>
Jason
---
Now instead of four in the eights place /
you’ve got three, ‘Cause you added one /
(That is to say, eight) to the two, /
But you can’t take seven from three, /
So you look at the sixty-fours....
> diff --git a/drivers/hid/wacom_wac.c b/drivers/hid/wacom_wac.c
> index 0723ba8..1cf4608 100644
> --- a/drivers/hid/wacom_wac.c
> +++ b/drivers/hid/wacom_wac.c
> @@ -1765,7 +1765,7 @@ static int wacom_wac_pen_event(struct hid_device *hdev, struct hid_field *field,
> wacom_wac->hid_data.tipswitch |= value;
> return 0;
> case HID_DG_TOOLSERIALNUMBER:
> - wacom_wac->serial[0] = (wacom_wac->serial[0] & ~0xFFFFFFFF);
> + wacom_wac->serial[0] = (wacom_wac->serial[0] & ~0xFFFFFFFFULL);
> wacom_wac->serial[0] |= value;
> return 0;
> case WACOM_HID_WD_SENSE:
> --
--
To unsubscribe from this list: send the line "unsubscribe kernel-janitors" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
next prev parent reply other threads:[~2016-11-14 18:31 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-11-10 19:25 [patch] HID: wacom: Don't clear bits unintentionally Dan Carpenter
2016-11-14 18:31 ` Jason Gerecke [this message]
2016-11-15 11:13 ` Jiri Kosina
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=56caefcd-93d6-201d-f597-2d651cbe68ba@gmail.com \
--to=killertofu@gmail.com \
--cc=benjamin.tissoires@redhat.com \
--cc=dan.carpenter@oracle.com \
--cc=jikos@kernel.org \
--cc=kernel-janitors@vger.kernel.org \
--cc=linux-input@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=rydberg@bitmath.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