linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Benjamin Tissoires <benjamin.tissoires@gmail.com>
To: Henrik Rydberg <rydberg@euromail.se>
Cc: Jiri Kosina <jkosina@suse.cz>,
	Dmitry Torokhov <dmitry.torokhov@gmail.com>,
	Stephane Chatty <chatty@enac.fr>,
	linux-input@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [RFC 0/5] hid: Extending the device-driver matching mechanism
Date: Tue, 3 Apr 2012 10:38:32 +0200	[thread overview]
Message-ID: <CAN+gG=EvmTFKmKGaC6T-RKYhUy8U0NqWxqz-k_Gr_w5_rm57Bg@mail.gmail.com> (raw)
In-Reply-To: <1333436730-13008-1-git-send-email-rydberg@euromail.se>

Hi Henrik,

well, I'm giving you my answer here as it will be more convenient than
in the previous thread.

So, I made a few tests yesterday, and I have now a clearer idea about
this solution:

generally, I like it. Furthermore, it should help us build new classes
of devices without involving hid-core, which is great.
However, I have a few minors concerns, and a major one.

The major one comes with patch 3: introducing the hid_parse function
in usbhid is great but it interferes with report_fixup mechanism. That
means that several drivers won't work with this solution.

Now the minors:
- as mentioned, the patches do not apply on Jiri's tree, which means
that we are missing the detection of the serial protocol (see comment
in patch 4).
- shouldn't we introduce the same behavior for bluetooth (hidp)
devices -> to be able to separate the handling of the magicmouse for
instance)?
- as the hid_parse function is already called, shouldn't we remove the
calls in the other drivers?

Cheers,
Benjamin

On Tue, Apr 3, 2012 at 09:05, Henrik Rydberg <rydberg@euromail.se> wrote:
> Hi Jiri,
>
> These patches were first sent out as a reply to Benjamin's autoloading
> patch (http://www.spinics.net/lists/linux-input/msg20001.html), but it
> seems more appropriate as an RFC.
>
> The idea is to parse the hid descriptors before adding the device,
> such that the device identifier, in particular the device/modalias,
> can be augmented by the report information. This approach solves the
> generic auto-loading problem we face today, here exemplified by a
> solution for hid-multitouch.
>
> The patches apply cleanly to 3.3 for easy testing.
>
> Thanks,
> Henrik
>
> Henrik Rydberg (5):
>  hid: Remove multitouch quirk
>  hid-multitouch: Prepare driver for new device ids
>  hid: Parse the device before adding it
>  hid: Add idtags to modalias
>  hid: Remove multitouch devices from blacklist
>
>  drivers/hid/hid-core.c          |   88 ++++++++-------------------
>  drivers/hid/hid-input.c         |   11 ----
>  drivers/hid/hid-multitouch.c    |  124 +++++++++++++++++++++------------------
>  drivers/hid/usbhid/hid-core.c   |    5 ++
>  include/linux/hid.h             |    8 ++-
>  include/linux/mod_devicetable.h |    2 +-
>  scripts/mod/file2alias.c        |    2 +
>  7 files changed, 107 insertions(+), 133 deletions(-)
>
> --
> 1.7.9.5
>

  parent reply	other threads:[~2012-04-03  8:38 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-04-03  7:05 [RFC 0/5] hid: Extending the device-driver matching mechanism Henrik Rydberg
2012-04-03  7:05 ` [RFC 1/5] hid: Remove multitouch quirk Henrik Rydberg
2012-04-08 23:56   ` Jiri Kosina
2012-04-03  7:05 ` [RFC 2/5] hid-multitouch: Prepare driver for new device ids Henrik Rydberg
2012-04-03  7:05 ` [RFC 3/5] hid: Parse the device before adding it Henrik Rydberg
2012-04-03  8:41   ` Benjamin Tissoires
2012-04-03 13:06     ` Jiri Kosina
2012-04-03  7:05 ` [RFC 4/5] hid: Add idtags to modalias Henrik Rydberg
2012-04-03  8:45   ` Benjamin Tissoires
2012-04-03 10:57     ` Henrik Rydberg
2012-04-03  7:05 ` [RFC 5/5] hid: Remove multitouch devices from blacklist Henrik Rydberg
2012-04-03  8:46   ` Benjamin Tissoires
2012-04-03  8:38 ` Benjamin Tissoires [this message]
2012-04-03 10:55   ` [RFC 0/5] hid: Extending the device-driver matching mechanism Henrik Rydberg
2012-04-08 23:53     ` 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='CAN+gG=EvmTFKmKGaC6T-RKYhUy8U0NqWxqz-k_Gr_w5_rm57Bg@mail.gmail.com' \
    --to=benjamin.tissoires@gmail.com \
    --cc=chatty@enac.fr \
    --cc=dmitry.torokhov@gmail.com \
    --cc=jkosina@suse.cz \
    --cc=linux-input@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=rydberg@euromail.se \
    /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).