All of lore.kernel.org
 help / color / mirror / Atom feed
From: Nikolai Kondrashov <spbnick@gmail.com>
To: David Herrmann <dh.herrmann@googlemail.com>
Cc: Jiri Kosina <jkosina@suse.cz>, linux-input <linux-input@vger.kernel.org>
Subject: Re: [PATCH 1/1] HID: add have_special_driver hid module parameter
Date: Sun, 01 Apr 2012 23:22:32 +0300	[thread overview]
Message-ID: <4F78B908.10707@gmail.com> (raw)
In-Reply-To: <CANq1E4RTrqwn5-5VXMJYw4Ye55Am7bT3VsAgr6U4GkDjGV2U_Q@mail.gmail.com>

Hi David,

On 04/01/2012 11:10 PM, David Herrmann wrote:
> On Sun, Apr 1, 2012 at 9:44 PM, Nikolai Kondrashov<spbnick@gmail.com>  wrote:
>> Thanks, but this doesn't suit me currently. I don't implement report parsing
>> in my drivers, but rather describe every device protocol separately with a
>> report descriptor and rely on the generic driver for parsing. Thus, I save
>> in code complexity and maintenance, but loose in portability.
>
> I think you don't understand me correctly.

Yes, I didn't, sorry :)

> I meant instead of using some static global table in the module you could
> instead implement something like the
> "new_id"/store_new_id()/dyn_list/dyn_lock mechanism but for the
> special_driver-id-array. So one could use "echo vid:pid
>> /sys/bus/hid/new_special_driver_id" and it would be added to a linked
> list which is checked additionally to the static array.
>
> Such a mechanism is already used by all kinds of buses, hid, usb,
> pci... but only for the id-lists of drivers, not a global module list.
> At least this would look less hackish than a fixed-length-array module
> parameter ;)

Yes, it could be done like this. However, I think Jiri would reject it. It
basically has the same hackishness WRT the overall design, while having more
complicated implementation.

Then, at least for my purpose, it would be worse. Because it would be harder
to configure it permanently. With a module parameter you could just modify
modprobe configuration, but with a sysfs node, you would need to have some
sort of a script. Then cold-plugged devices won't work unless you care to
unbind the existing devices when adding an ID.

Sincerely,
Nick

  reply	other threads:[~2012-04-01 20:22 UTC|newest]

Thread overview: 25+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-02-20 21:29 [PATCH 1/1] HID: add have_special_driver hid module parameter Nikolai Kondrashov
2012-02-27 14:15 ` Nikolai Kondrashov
2012-02-28 14:30   ` Jiri Kosina
2012-02-28 15:12     ` Nikolai Kondrashov
2012-02-29 21:23     ` Nikolai Kondrashov
2012-03-29  8:00     ` Nikolai Kondrashov
2012-03-30 13:49 ` Jiri Kosina
2012-03-30 15:22   ` Nikolai Kondrashov
2012-03-30 23:03     ` David Herrmann
2012-04-01 19:44       ` Nikolai Kondrashov
2012-04-01 19:49         ` Jiri Kosina
2012-04-01 20:11           ` Nikolai Kondrashov
2012-04-01 20:10         ` David Herrmann
2012-04-01 20:22           ` Nikolai Kondrashov [this message]
2012-04-01 19:33   ` Nikolai Kondrashov
2012-04-01 19:46     ` Jiri Kosina
2012-04-01 20:50       ` Nikolai Kondrashov
2012-04-02 23:41         ` Jiri Kosina
2012-04-04  8:27           ` Nikolai Kondrashov
2012-04-08 10:48           ` Nikolai Kondrashov
2012-04-03 14:46         ` Henrik Rydberg
2012-04-03 15:09           ` Jiri Kosina
2012-04-03 16:37             ` Henrik Rydberg
2012-04-03 17:01               ` Jiri Kosina
2012-04-03 17:11                 ` Henrik Rydberg

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=4F78B908.10707@gmail.com \
    --to=spbnick@gmail.com \
    --cc=dh.herrmann@googlemail.com \
    --cc=jkosina@suse.cz \
    --cc=linux-input@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.