From: Benjamin Tissoires <benjamin.tissoires@redhat.com>
To: Jason Gerecke <killertofu@gmail.com>
Cc: "linux-input@vger.kernel.org" <linux-input@vger.kernel.org>,
"jkosina@suse.cz" <jkosina@suse.cz>,
"pinglinux@gmail.com" <pinglinux@gmail.com>,
Jason Gerecke <jason.gerecke@wacom.com>
Subject: Re: [PATCH] HID: input: Fix TransducerSerialNumber implementation
Date: Tue, 28 Oct 2014 15:58:19 -0400 [thread overview]
Message-ID: <20141028195819.GF14393@mail.corp.redhat.com> (raw)
In-Reply-To: <CANRwn3QbH-Jt4L7W-qOikX_JaeKs-vu_5XeK8TgzowyXLh_=qg@mail.gmail.com>
On Oct 28 2014 or thereabouts, Jason Gerecke wrote:
> On Tue, Sep 23, 2014 at 11:09 AM, Jason Gerecke <killertofu@gmail.com> wrote:
> > The commit which introduced TransducerSerialNumber (368c966) is missing
> > two crucial implementation details. Firstly, the commit does not set the
> > type/code/bit/max fields as expected later down the code which can cause
> > the driver to crash when a tablet with this usage is connected. Secondly,
> > the call to 'set_bit' causes MSC_PULSELED to be sent instead of the
> > expected MSC_SERIAL. This commit addreses both issues.
> >
> > Signed-off-by: Jason Gerecke <jason.gerecke@wacom.com>
> > ---
> > drivers/hid/hid-input.c | 5 ++++-
> > 1 file changed, 4 insertions(+), 1 deletion(-)
> >
> > diff --git a/drivers/hid/hid-input.c b/drivers/hid/hid-input.c
> > index 2619f7f..cb1b3fa 100644
> > --- a/drivers/hid/hid-input.c
> > +++ b/drivers/hid/hid-input.c
> > @@ -689,7 +689,10 @@ static void hidinput_configure_usage(struct hid_input *hidinput, struct hid_fiel
> > break;
> >
> > case 0x5b: /* TransducerSerialNumber */
> > - set_bit(MSC_SERIAL, input->mscbit);
> > + usage->type = EV_MSC;
> > + usage->code = MSC_SERIAL;
> > + bit = input->mscbit;
> > + max = MSC_MAX;
> > break;
> >
> > default: goto unknown;
> > --
> > 2.1.0
> >
>
> This patch still seems to be in limbo. Anyone (Ping? Benjamin?) care
> to provide an ACK or review?
>
Sorry for that, I was persuaded I already have answered to this one.
The patch makes sense, but I think it will be better to extend
hid_map_usage() with MSC bits and define map_msc_clear(). The code will
be more consistent with the rest this way.
Anyway, if Jiri does not find this to be mandatory, then this code is:
Reviewed-by: Benjamin Tissoires <benjamin.tissoires@redhat.com>
Cheers,
Benjamin
next prev parent reply other threads:[~2014-10-28 19:58 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <Message-ID: <6B3C86448604A642A31AAD3F8C07EA7724F0B8CD@Exchange1.wacom.com>
2014-09-23 18:09 ` [PATCH] HID: input: Fix TransducerSerialNumber implementation Jason Gerecke
2014-10-28 18:31 ` Jason Gerecke
2014-10-28 19:58 ` Benjamin Tissoires [this message]
[not found] ` <CAF8JNhKYmBpgp4yRvQbxuaAPSk5dG3YW7qqZnrBAB22bRXPEJg@mail.gmail.com>
2014-10-28 19:33 ` Fwd: " Ping Cheng
2014-10-29 10:00 ` Jiri Kosina
2014-09-22 16:58 [PATCH] HID: input: Finish " Jason Gerecke
2014-09-23 15:12 ` Benjamin Tissoires
2014-09-23 17:59 ` Jason Gerecke
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=20141028195819.GF14393@mail.corp.redhat.com \
--to=benjamin.tissoires@redhat.com \
--cc=jason.gerecke@wacom.com \
--cc=jkosina@suse.cz \
--cc=killertofu@gmail.com \
--cc=linux-input@vger.kernel.org \
--cc=pinglinux@gmail.com \
/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).