2008-10-14 00:07:44

by Jiri Kosina

[permalink] [raw]
Subject: [GIT] HID patches for 2.6.28

Linus,

could you please pull from 'for-linus' branch of

git://git.kernel.org/pub/scm/linux/kernel/git/jikos/hid.git for-linus

to receive 2.6.28 patches for the HID (the HIDeously slow devices, you
know) code.

The most notable change is a conversion of the whole HID core code into
bus, and conversion of all the quirks to specialized separate drivers.
Over past years, the quirks have been added in order to support broken
devices (not complying with HID standard) all over the code, and turned it
into total unmaintainable mess. The HID bus provides easy means for
drivers for quirky devices to use as much of the common code as possible,
and allows for re-implementing only the quirky part.


Documentation/feature-removal-schedule.txt | 7 +
drivers/hid/Kconfig | 195 +++++
drivers/hid/Makefile | 34 +-
drivers/hid/hid-a4tech.c | 162 ++++
drivers/hid/hid-apple.c | 484 +++++++++++
drivers/hid/hid-belkin.c | 105 +++
drivers/hid/hid-cherry.c | 87 ++
drivers/hid/hid-chicony.c | 80 ++
drivers/hid/hid-core.c | 1177 +++++++++++++++++++++------
drivers/hid/hid-cypress.c | 158 ++++
drivers/hid/hid-dell.c | 74 ++
drivers/hid/hid-dummy.c | 69 ++
drivers/hid/hid-ezkey.c | 95 +++
drivers/hid/hid-gyration.c | 96 +++
drivers/hid/hid-ids.h | 397 +++++++++
drivers/hid/hid-input-quirks.c | 484 -----------
drivers/hid/hid-input.c | 915 ++++++++--------------
drivers/hid/hid-lg.c | 342 ++++++++
drivers/hid/hid-lg.h | 18 +
drivers/hid/{usbhid => }/hid-lg2ff.c | 14 +-
drivers/hid/{usbhid => }/hid-lgff.c | 34 +-
drivers/hid/hid-microsoft.c | 219 +++++
drivers/hid/hid-monterey.c | 82 ++
drivers/hid/hid-petalynx.c | 122 +++
drivers/hid/{usbhid/hid-plff.c => hid-pl.c} | 83 ++-
drivers/hid/hid-samsung.c | 100 +++
drivers/hid/hid-sony.c | 110 +++
drivers/hid/hid-sunplus.c | 82 ++
drivers/hid/{usbhid => }/hid-tmff.c | 138 ++--
drivers/hid/{usbhid => }/hid-zpff.c | 71 ++-
drivers/hid/hidraw.c | 8 +-
drivers/hid/usbhid/Kconfig | 75 --
drivers/hid/usbhid/Makefile | 18 -
drivers/hid/usbhid/hid-core.c | 463 ++++++------
drivers/hid/usbhid/hid-ff.c | 95 ---
drivers/hid/usbhid/hid-pidff.c | 5 +-
drivers/hid/usbhid/hid-quirks.c | 934 +---------------------
drivers/hid/usbhid/hiddev.c | 20 +-
drivers/hid/usbhid/usbhid.h | 4 +-
drivers/hid/usbhid/usbkbd.c | 12 +-
drivers/hid/usbhid/usbmouse.c | 8 +-
include/linux/hid.h | 373 +++++++--
include/linux/hiddev.h | 46 +-
include/linux/mod_devicetable.h | 10 +
net/bluetooth/hidp/core.c | 214 +++--
net/bluetooth/hidp/hidp.h | 2 +
scripts/mod/file2alias.c | 18 +
47 files changed, 5390 insertions(+), 2949 deletions(-)

Alex Chiang (1):
HID: fix grammo in HID_COMPAT Kconfig help text

Anssi Hannula (1):
HID: fix a lockup regression when using force feedback on a PID device

Antonio Ospite (2):
HID: hiddev.h: Fix mixed space and tabs in example code.
HID: hiddev.h: Fix example code.

Greg Kroah-Hartman (2):
HID: remove info() macro from usb HID drivers
HID: remove warn() macro from usb hid drivers

Harvey Harrison (1):
HID: make compat functions static

Jiri Kosina (3):
HID: introduce list for hiddev creation forcing
HID: add support for Super Dual Box Pro USB PS2/PS2 adapter
HID: fix incorrent length condition in hidraw_write()

Jiri Slaby (35):
modpost: add support for hid
HID: make a bus from hid code
HID: hid, make parsing event driven
HID: move ids into separate file
HID: move usage input mapping to hid.h
HID: move logitech quirks
HID: move ignore quirks
HID: move apple quirks
HID: add compat support
HID: indent switches/cases
HID: move microsoft quirks
HID: move sunplus quirks
HID: move cypress quirks
HID: move a4tech quirks
HID: move cherry quirks
HID: move ezkey quirks
HID: move chicony quirks
HID: move belkin quirks
HID: move petalynx quirks
HID: move monterey quirks
HID: move gyration quirks
HID: move samsung quirks
HID: remove hid-input-quirks
HID: remove rdesc quirk support
HID: move sony quirks
HID: move dell quirks
HID: move connect quirks
HID: move reset leds quirk
HID: move logitech FF processing
HID: fix tty<->hid deadlock
HID: move pantherlord FF processing
HID: move thrustmaster FF processing
HID: move zeroplus FF processing
HID: remove hid-ff
HID: convert to dev_* prints

Peter Korsgaard (1):
HID: add appletv IR receiver quirk

Randy Dunlap (1):
HID: fix gyration build error

Remi Cattiau (1):
HID: ignore iBuddy devices

Richard Hughes (1):
HID: remove ignore quirk for MGE UPS devices

Sergey Belyashov (1):
HID: Autocentering support for Logitech MOMO Racing Wheel

Tomoya Adachi (1):
HID: report descriptor fix for remaining MacBook JIS keyboards


2008-10-14 19:41:58

by Linus Torvalds

[permalink] [raw]
Subject: Re: [GIT] HID patches for 2.6.28



On Tue, 14 Oct 2008, Jiri Kosina wrote:
>
> could you please pull from 'for-linus' branch of
>
> git://git.kernel.org/pub/scm/linux/kernel/git/jikos/hid.git for-linus
>
> to receive 2.6.28 patches for the HID (the HIDeously slow devices, you
> know) code.

This is really HIDeous. Disgusting.

The new Kconfig options are almost uselessly described, and very annoying
and this adds several new warnings of the type:

drivers/hid/hid-lg.c:342: warning: ?hid_compat_logitech? defined but not used

which is just unacceptable.

I have an entirely warningless build. I'm not going to break that over
something like this. Not pulled. Please fix.

As to the Kconfig options - do they really add so much space that you need
to ask for the quirks? You didn't use to. Can you make the questions
depend on EMBEDDED, or at least on the HID_COMPAT thing or whatever?

Linus

2008-10-14 20:12:22

by Jiri Kosina

[permalink] [raw]
Subject: Re: [GIT] HID patches for 2.6.28

On Tue, 14 Oct 2008, Linus Torvalds wrote:

> The new Kconfig options are almost uselessly described, and very
> annoying and this adds several new warnings of the type:
> drivers/hid/hid-lg.c:342: warning: ?hid_compat_logitech? defined but not used
> which is just unacceptable.

Hmm, this is because of Harvey Harrison's (CC added) patch that was used
to silence sparse warning, but it is wrong as Jiri correctly pointed out
on http://lkml.org/lkml/2008/9/4/495 but I somehow completely missed that
mail.

Will fix that up.

> As to the Kconfig options - do they really add so much space that you
> need to ask for the quirks? You didn't use to. Can you make the
> questions depend on EMBEDDED, or at least on the HID_COMPAT thing or
> whatever?

Probably makes sense, yes. I will send you a new pull request.

--
Jiri Kosina

2008-10-14 21:02:59

by Harvey Harrison

[permalink] [raw]
Subject: Re: [GIT] HID patches for 2.6.28

On Tue, 2008-10-14 at 22:12 +0200, Jiri Kosina wrote:
> On Tue, 14 Oct 2008, Linus Torvalds wrote:
>
> > The new Kconfig options are almost uselessly described, and very
> > annoying and this adds several new warnings of the type:
> > drivers/hid/hid-lg.c:342: warning: ?hid_compat_logitech? defined but not used
> > which is just unacceptable.
>
> Hmm, this is because of Harvey Harrison's (CC added) patch that was used
> to silence sparse warning, but it is wrong as Jiri correctly pointed out
> on http://lkml.org/lkml/2008/9/4/495 but I somehow completely missed that
> mail.
>
> Will fix that up.

I thought I sent a reply agreeing with Jiri's mail shortly afterwards as
well, but I can't seem to find it...sorry for this.

Harvey

2008-10-14 22:40:23

by Jiri Kosina

[permalink] [raw]
Subject: [GIT] HID patches for 2.6.28


[ this is v2 of the request, with these changes compared to the previous one:

- the compilation warning about unused _compat functions is gone
- all the quirk-drivers are now built automatically once generic driver is
selected (can be overridden for EMBEDDED kernels)
- three new patches from Mauro adding a few VID/PID ]


Linus,

could you please pull from 'for-linus' branch of

git://git.kernel.org/pub/scm/linux/kernel/git/jikos/hid.git for-linus

to receive 2.6.28 patches for the HID code.

The most notable change is a conversion of the whole HID core code into
bus, and conversion of all the quirks to specialized separate drivers.
Over past years, the quirks have been added in order to support broken
devices (not complying with HID standard) all over the code, and turned it
into total unmaintainable mess. The HID bus provides easy means for
drivers for quirky devices to use as much of the common code as possible,
and allows for re-implementing only the quirky part.

Thanks!

Documentation/feature-removal-schedule.txt | 7 +
drivers/hid/Kconfig | 221 +++++
drivers/hid/Makefile | 35 +-
drivers/hid/hid-a4tech.c | 162 ++++
drivers/hid/hid-apple.c | 484 +++++++++++
drivers/hid/hid-belkin.c | 105 +++
drivers/hid/hid-bright.c | 71 ++
drivers/hid/hid-cherry.c | 87 ++
drivers/hid/hid-chicony.c | 80 ++
drivers/hid/hid-core.c | 1181 +++++++++++++++++++++------
drivers/hid/hid-cypress.c | 158 ++++
drivers/hid/hid-dell.c | 75 ++
drivers/hid/hid-dummy.c | 72 ++
drivers/hid/hid-ezkey.c | 95 +++
drivers/hid/hid-gyration.c | 96 +++
drivers/hid/hid-ids.h | 404 +++++++++
drivers/hid/hid-input-quirks.c | 484 -----------
drivers/hid/hid-input.c | 915 ++++++++--------------
drivers/hid/hid-lg.c | 342 ++++++++
drivers/hid/hid-lg.h | 18 +
drivers/hid/{usbhid => }/hid-lg2ff.c | 14 +-
drivers/hid/{usbhid => }/hid-lgff.c | 34 +-
drivers/hid/hid-microsoft.c | 219 +++++
drivers/hid/hid-monterey.c | 82 ++
drivers/hid/hid-petalynx.c | 122 +++
drivers/hid/{usbhid/hid-plff.c => hid-pl.c} | 83 ++-
drivers/hid/hid-samsung.c | 100 +++
drivers/hid/hid-sony.c | 110 +++
drivers/hid/hid-sunplus.c | 82 ++
drivers/hid/{usbhid => }/hid-tmff.c | 138 ++--
drivers/hid/{usbhid => }/hid-zpff.c | 71 ++-
drivers/hid/hidraw.c | 8 +-
drivers/hid/usbhid/Kconfig | 75 --
drivers/hid/usbhid/Makefile | 18 -
drivers/hid/usbhid/hid-core.c | 463 ++++++------
drivers/hid/usbhid/hid-ff.c | 95 ---
drivers/hid/usbhid/hid-pidff.c | 5 +-
drivers/hid/usbhid/hid-quirks.c | 934 +---------------------
drivers/hid/usbhid/hiddev.c | 20 +-
drivers/hid/usbhid/usbhid.h | 4 +-
drivers/hid/usbhid/usbkbd.c | 12 +-
drivers/hid/usbhid/usbmouse.c | 8 +-
include/linux/hid.h | 373 +++++++--
include/linux/hiddev.h | 46 +-
include/linux/mod_devicetable.h | 10 +
net/bluetooth/hidp/core.c | 214 +++--
net/bluetooth/hidp/hidp.h | 2 +
scripts/mod/file2alias.c | 18 +
48 files changed, 5503 insertions(+), 2949 deletions(-)

Alex Chiang (1):
HID: fix grammo in HID_COMPAT Kconfig help text

Anssi Hannula (1):
HID: fix a lockup regression when using force feedback on a PID device

Antonio Ospite (2):
HID: hiddev.h: Fix mixed space and tabs in example code.
HID: hiddev.h: Fix example code.

Greg Kroah-Hartman (2):
HID: remove info() macro from usb HID drivers
HID: remove warn() macro from usb hid drivers

Jiri Kosina (5):
HID: introduce list for hiddev creation forcing
HID: add support for Super Dual Box Pro USB PS2/PS2 adapter
HID: fix incorrent length condition in hidraw_write()
HID: add missing blacklist entry for Apple ATV ircontrol
HID: build drivers for all quirky devices by default

Jiri Slaby (35):
modpost: add support for hid
HID: make a bus from hid code
HID: hid, make parsing event driven
HID: move ids into separate file
HID: move usage input mapping to hid.h
HID: move logitech quirks
HID: move ignore quirks
HID: move apple quirks
HID: add compat support
HID: indent switches/cases
HID: move microsoft quirks
HID: move sunplus quirks
HID: move cypress quirks
HID: move a4tech quirks
HID: move cherry quirks
HID: move ezkey quirks
HID: move chicony quirks
HID: move belkin quirks
HID: move petalynx quirks
HID: move monterey quirks
HID: move gyration quirks
HID: move samsung quirks
HID: remove hid-input-quirks
HID: remove rdesc quirk support
HID: move sony quirks
HID: move dell quirks
HID: move connect quirks
HID: move reset leds quirk
HID: move logitech FF processing
HID: fix tty<->hid deadlock
HID: move pantherlord FF processing
HID: move thrustmaster FF processing
HID: move zeroplus FF processing
HID: remove hid-ff
HID: convert to dev_* prints

Mauro Carvalho Chehab (3):
HID: fix numlock led on Dell device 0x413c/0x2105
HID: Don't let Avermedia Radio FM800 be handled by usb hid drivers
HID: add support for Bright ABNT2 brazilian device

Peter Korsgaard (1):
HID: add appletv IR receiver quirk

Randy Dunlap (1):
HID: fix gyration build error

Remi Cattiau (1):
HID: ignore iBuddy devices

Richard Hughes (1):
HID: remove ignore quirk for MGE UPS devices

Sergey Belyashov (1):
HID: Autocentering support for Logitech MOMO Racing Wheel

Tomoya Adachi (1):
HID: report descriptor fix for remaining MacBook JIS keyboards

2008-10-15 09:37:16

by Ingo Molnar

[permalink] [raw]
Subject: Re: [GIT] HID patches for 2.6.28


* Jiri Kosina <[email protected]> wrote:

> [ this is v2 of the request, with these changes compared to the
> previous one:
>
> - the compilation warning about unused _compat functions is gone
> - all the quirk-drivers are now built automatically once generic driver is
> selected (can be overridden for EMBEDDED kernels)
> - three new patches from Mauro adding a few VID/PID ]

this or the I2C updates cause widespread build failures in latest -git:

drivers/built-in.o: In function `wm8400_i2c_write':
wm8400-core.c:(.text+0xa9ce3): undefined reference to `i2c_master_send'
drivers/built-in.o: In function `wm8400_i2c_read':
wm8400-core.c:(.text+0xa9d6b): undefined reference to `i2c_transfer'
drivers/built-in.o: In function `bright_probe':
hid-bright.c:(.text+0x2ac875): undefined reference to `usbhid_set_leds'
drivers/built-in.o: In function `dell_probe':
hid-dell.c:(.text+0x2acfb5): undefined reference to `usbhid_set_leds'
drivers/built-in.o: In function `lg_probe':
hid-lg.c:(.text+0x2ae03d): undefined reference to `usbhid_set_leds'
drivers/built-in.o: In function `hid_lgff_set_autocenter':
hid-lgff.c:(.text+0x2ae1cf): undefined reference to `usbhid_submit_report'
drivers/built-in.o: In function `hid_lgff_play':
hid-lgff.c:(.text+0x2ae28b): undefined reference to `usbhid_submit_report'
drivers/built-in.o: In function `play_effect':
hid-lg2ff.c:(.text+0x2ae3c4): undefined reference to `usbhid_submit_report'
drivers/built-in.o: In function `lg2ff_init':
: undefined reference to `usbhid_submit_report'
drivers/built-in.o: In function `wm8400_module_init':
wm8400-core.c:(.init.text+0x817f): undefined reference to `i2c_register_driver'
drivers/built-in.o: In function `wm8400_module_exit':
wm8400-core.c:(.exit.text+0x60e): undefined reference to `i2c_del_driver'

Ingo

2008-10-15 09:42:31

by Jiri Kosina

[permalink] [raw]
Subject: Re: [GIT] HID patches for 2.6.28

On Wed, 15 Oct 2008, Ingo Molnar wrote:

> this or the I2C updates cause widespread build failures in latest -git:

For the usbhid_set_leds(), Adrian has already sent me a fix [1]. Still, I
would like to understand whether this failure is bug or feature in
select/depends handling in Kconfig, because it seems to behave differently
from what I was expecting.

But I have Adrian's patch in my tree and will be sending pull request to
Linus today, after I sort a few more pending things up.

[1] http://lkml.org/lkml/2008/10/15/24

Thanks,

--
Jiri Kosina

2008-10-15 10:04:21

by Ingo Molnar

[permalink] [raw]
Subject: Re: [GIT] HID patches for 2.6.28


* Jiri Kosina <[email protected]> wrote:

> On Wed, 15 Oct 2008, Ingo Molnar wrote:
>
> > this or the I2C updates cause widespread build failures in latest -git:
>
> For the usbhid_set_leds(), Adrian has already sent me a fix [1].
> Still, I would like to understand whether this failure is bug or
> feature in select/depends handling in Kconfig, because it seems to
> behave differently from what I was expecting.

yes, it's a kconfig bug: Kconfig must either not allow complex selects
(during its initial parsing pass of the Kconfig dependnecy tree) or
handle the dependencies correctly.

The current "allow them silently and pepper the kernel with build
errors" approach is obviously silly.

We already have over 100 bugfixes in the tree from the past 3 years due
to kconfig's inability to figure out the correct dependencies. (count:
rising steadily)

Changes to the Kconfig tool to address this design bug did not get
picked up. See for example this quick patch from Vegard half a year ago:

http://lkml.org/lkml/2008/5/4/13

that patch was not adopted and the config options in the warning log
were later on frequent participants in build failures and subsequent
stream of trivial fixes.

Ingo

2008-10-15 10:20:51

by Adrian Bunk

[permalink] [raw]
Subject: Re: [GIT] HID patches for 2.6.28

On Wed, Oct 15, 2008 at 12:02:52PM +0200, Ingo Molnar wrote:
>
> * Jiri Kosina <[email protected]> wrote:
>
> > On Wed, 15 Oct 2008, Ingo Molnar wrote:
> >
> > > this or the I2C updates cause widespread build failures in latest -git:
> >
> > For the usbhid_set_leds(), Adrian has already sent me a fix [1].
> > Still, I would like to understand whether this failure is bug or
> > feature in select/depends handling in Kconfig, because it seems to
> > behave differently from what I was expecting.
>
> yes, it's a kconfig bug: Kconfig must either not allow complex selects
> (during its initial parsing pass of the Kconfig dependnecy tree) or

Are we removing RCU only because people constantly get it wrong?

If you do RCU stuff without asking Paul for review it might be wrong,
and if you are doing complex stuff in kconfig without asking Roman or
me the same applies.

> handle the dependencies correctly.

When you claim that there was one "correct" way to handle them
that's FUD, and shows that you don't understand the problem.

> The current "allow them silently and pepper the kernel with build
> errors" approach is obviously silly.
>
> We already have over 100 bugfixes in the tree from the past 3 years due
> to kconfig's inability to figure out the correct dependencies. (count:
> rising steadily)

Again, there are no "correct dependencies".

Continously repeating the same FUD doesn't make it true.

I have yet to see someone giving a semantics for select that would solve
as many problems as the FUD claims without introducing new problems.

> Changes to the Kconfig tool to address this design bug did not get
> picked up. See for example this quick patch from Vegard half a year ago:
>
> http://lkml.org/lkml/2008/5/4/13
>
> that patch was not adopted and the config options in the warning log

I remember that patch, Vegard himself admitted it was wrong:
http://lkml.org/lkml/2008/5/4/48

Not sure why you whine about a broken patch not being applied...

> were later on frequent participants in build failures and subsequent
> stream of trivial fixes.

The assumption that kconfig was trivial or all kconfig fixes were
trivial is completely wrong.

I might just remind you of http://lkml.org/lkml/2008/4/30/446 where you
tried to push a broken kconfig patch of yours through the Input
maintainer (who had correctly rejected it), and the actual bug was
in the x86 code you maintain.

Something isn't trivial only because you don't understand it.

> Ingo

cu
Adrian

--

"Is there not promise of rain?" Ling Tan asked suddenly out
of the darkness. There had been need of rain for many days.
"Only a promise," Lao Er said.
Pearl S. Buck - Dragon Seed