[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20080324032510.GB3321@khazad-dum.debian.net>
Date: Mon, 24 Mar 2008 00:25:10 -0300
From: Henrique de Moraes Holschuh <hmh@....eng.br>
To: Dmitry Torokhov <dtor@...ightbb.com>
Cc: linux-kernel@...r.kernel.org, Richard Purdie <rpurdie@...ys.net>
Subject: Re: [PATCH] Input: add flags bitfield
On Sun, 23 Mar 2008, Dmitry Torokhov wrote:
> On Saturday 22 March 2008, Henrique de Moraes Holschuh wrote:
> > On Fri, 21 Mar 2008, Henrique de Moraes Holschuh wrote:
> > > But I'd prefer if joydev and mousedev did not bind to
> > > unknown+capabilities, just in case. Looks like bad form to me, and
> > > might bite us back later on. We can properly fix all drivers in-tree
> > > to have suitable types for joydev and/or mousedev binds, rfkill binds,
> > > and so on after all.
>
> Ohne word - HID.
Bleh. In that case, it will be too ugly to have it called a type, most
of the input devices will have a type of "generic", which is at the very
least damn ugly.
> That's why I thinkg unmarked should really be default and only few selected
> devices should set their type.
I do think unmarked should be the default, and if it is so hard to have
the emulation (and other handlers) ignore unmarked, we can leave that
active by default as well. No problems here.
What I don't like is to call it a "input device type", and have bits on
it for joystick and mouse, which almost every mouse and joystick will
NOT set.
At that point, the difference between the bitfield with a handler
whitelist (with blacklist all others implied, "Cisco ACL-style"), and a
type bitfield is just in the name. The difference from what I already
sent you would be the name, and inverted logic (I sent you a blacklist
patch, not a whitelist patch).
IMO, it doesn't make sense to leave people wondering why their HID
devices (and most other input devices) have a type of "generic", when
they indeed are mouses, joysticks, or whatever.
Another approach would be to call the flags bitfield "emulation type",
set it to "any" as default (all bits zeroed), add one bit for every
emulation-style handler we add (e.g. mousedev and joydev, but not
rfkill), and never bind a handler to a device which has that bitfield
nonzero, unless it has the emulation bit for that handler set.
Do you *really* want a device type bitfield?
--
"One disk to rule them all, One disk to find them. One disk to bring
them all and in the darkness grind them. In the Land of Redmond
where the shadows lie." -- The Silicon Valley Tarot
Henrique Holschuh
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists