HID: split Numlock emulation quirk from HID_QUIRK_APPLE_HAS_FN.
authorDiego 'Flameeyes' Petteno <flameeyes@gmail.com>
Mon, 5 May 2008 14:20:50 +0000 (16:20 +0200)
committerJiri Kosina <jkosina@suse.cz>
Tue, 20 May 2008 14:44:43 +0000 (16:44 +0200)
commit6e7045990f35ef9250804b3fd85e855b8c2aaeb6
tree4742656cd49a86e204ad521178462f695a5aa3cf
parentb8291ad07a7f3b5b990900f0001198ac23ba893e
HID: split Numlock emulation quirk from HID_QUIRK_APPLE_HAS_FN.

Since 2.6.25 the HID_QUIRK_APPLE_HAS_FN quirk is enabled even for
non-laptop Apple keyboards of the Aluminium series. The USB version of
these don't need Numlock emulation, like the laptop (and Aluminium
Wireless) do, as they have a proper keypad.

This patch splits the Numlock emulation for Apple keyboards in a
different quirk flag, so that it can be enabled for all the keyboards
but the Aluminium USB ones.

If the Numlock emulation is enabled for Aluminium USB keyboards, the
JKL and UIO keys become the numeric pad, and the rest of the keyboard
is disabled, included the key used to disable Numlock.

Additionally, these keyboard should not have a Numlock at all, as the
Numlock key is instead replaced by the 'Clear' key as usual for Apple
USB keyboards.

Signed-off-by: Diego 'Flameeyes' Petteno <flameeyes@gmail.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
drivers/hid/hid-input.c
drivers/hid/usbhid/hid-quirks.c
include/linux/hid.h