diff options
| author | Linus Torvalds <torvalds@linux-foundation.org> | 2010-03-01 13:38:09 -0500 |
|---|---|---|
| committer | Linus Torvalds <torvalds@linux-foundation.org> | 2010-03-01 13:38:09 -0500 |
| commit | 8724fdb53d27d7b59b60c8a399cc67f9abfabb33 (patch) | |
| tree | da2de791ed4845780376a5e6f844ab69957d565f /drivers | |
| parent | bc535154137601400ffe44c2a7be047ca041fe06 (diff) | |
| parent | 35858adbfca13678af99fb31618ef4428d6dedb0 (diff) | |
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input: (62 commits)
Input: atkbd - release previously reserved keycodes 248 - 254
Input: add KEY_WPS_BUTTON definition
Input: ads7846 - add regulator support
Input: winbond-cir - fix suspend/resume
Input: gamecon - use pr_err() and friends
Input: gamecon - constify some of the setup structures
Input: gamecon - simplify pad type handling
Input: gamecon - simplify coordinate calculation for PSX
Input: gamecon - fix some formatting issues
Input: gamecon - add rumble support for N64 pads
Input: wacom - add device type to device name string
Input: s3c24xx_ts - report touch only when stylus is down
Input: s3c24xx_ts - re-enable IRQ on resume
Input: wacom - constify product features data
Input: wacom - use per-device instance of wacom_features
Input: sh_keysc - enable building on SH-Mobile ARM
Input: wacom - get features from driver info
Input: rotary-encoder - set gpio direction for each requested gpio
Input: sh_keysc - update the driver with mode 6
Input: sh_keysc - switch to using bitmaps
...
Diffstat (limited to 'drivers')
44 files changed, 3092 insertions, 1301 deletions
diff --git a/drivers/char/keyboard.c b/drivers/char/keyboard.c index f706b1dffdb3..ada25bb8941e 100644 --- a/drivers/char/keyboard.c +++ b/drivers/char/keyboard.c | |||
| @@ -1185,11 +1185,6 @@ static void kbd_keycode(unsigned int keycode, int down, int hw_raw) | |||
| 1185 | 1185 | ||
| 1186 | rep = (down == 2); | 1186 | rep = (down == 2); |
| 1187 | 1187 | ||
| 1188 | #ifdef CONFIG_MAC_EMUMOUSEBTN | ||
| 1189 | if (mac_hid_mouse_emulate_buttons(1, keycode, down)) | ||
| 1190 | return; | ||
| 1191 | #endif /* CONFIG_MAC_EMUMOUSEBTN */ | ||
| 1192 | |||
| 1193 | if ((raw_mode = (kbd->kbdmode == VC_RAW)) && !hw_raw) | 1188 | if ((raw_mode = (kbd->kbdmode == VC_RAW)) && !hw_raw) |
| 1194 | if (emulate_raw(vc, keycode, !down << 7)) | 1189 | if (emulate_raw(vc, keycode, !down << 7)) |
| 1195 | if (keycode < BTN_MISC && printk_ratelimit()) | 1190 | if (keycode < BTN_MISC && printk_ratelimit()) |
| @@ -1328,6 +1323,21 @@ static void kbd_event(struct input_handle *handle, unsigned int event_type, | |||
| 1328 | schedule_console_callback(); | 1323 | schedule_console_callback(); |
| 1329 | } | 1324 | } |
| 1330 | 1325 | ||
| 1326 | static bool kbd_match(struct input_handler *handler, struct input_dev *dev) | ||
| 1327 | { | ||
| 1328 | int i; | ||
| 1329 | |||
| 1330 | if (test_bit(EV_SND, dev->evbit)) | ||
| 1331 | return true; | ||
| 1332 | |||
| 1333 | if (test_bit(EV_KEY, dev->evbit)) | ||
| 1334 | for (i = KEY_RESERVED; i < BTN_MISC; i++) | ||
| 1335 | if (test_bit(i, dev->keybit)) | ||
| 1336 | return true; | ||
| 1337 | |||
| 1338 | return false; | ||
| 1339 | } | ||
| 1340 | |||
| 1331 | /* | 1341 | /* |
| 1332 | * When a keyboard (or other input device) is found, the kbd_connect | 1342 | * When a keyboard (or other input device) is found, the kbd_connect |
| 1333 | * function is called. The function then looks at the device, and if it | 1343 | * function is called. The function then looks at the device, and if it |
| @@ -1339,14 +1349,6 @@ static int kbd_connect(struct input_handler *handler, struct input_dev *dev, | |||
| 1339 | { | 1349 | { |
| 1340 | struct input_handle *handle; | 1350 | struct input_handle *handle; |
| 1341 | int error; | 1351 | int error; |
| 1342 | int i; | ||
| 1343 | |||
| 1344 | for (i = KEY_RESERVED; i < BTN_MISC; i++) | ||
| 1345 | if (test_bit(i, dev->keybit)) | ||
| 1346 | break; | ||
| 1347 | |||
| 1348 | if (i == BTN_MISC && !test_bit(EV_SND, dev->evbit)) | ||
| 1349 | return -ENODEV; | ||
| 1350 | 1352 | ||
| 1351 | handle = kzalloc(sizeof(struct input_handle), GFP_KERNEL); | 1353 | handle = kzalloc(sizeof(struct input_handle), GFP_KERNEL); |
| 1352 | if (!handle) | 1354 | if (!handle) |
| @@ -1412,6 +1414,7 @@ MODULE_DEVICE_TABLE(input, kbd_ids); | |||
| 1412 | 1414 | ||
| 1413 | static struct input_handler kbd_handler = { | 1415 | static struct input_handler kbd_handler = { |
| 1414 | .event = kbd_event, | 1416 | .event = kbd_event, |
| 1417 | .match = kbd_match, | ||
| 1415 | .connect = kbd_connect, | 1418 | .connect = kbd_connect, |
| 1416 | .disconnect = kbd_disconnect, | 1419 | .disconnect = kbd_disconnect, |
| 1417 | .start = kbd_start, | 1420 | .start = kbd_start, |
diff --git a/drivers/input/evdev.c b/drivers/input/evdev.c index 258c639571b5..9f9816baeb97 100644 --- a/drivers/input/evdev.c +++ b/drivers/input/evdev.c | |||
| @@ -278,6 +278,8 @@ static int evdev_open(struct inode *inode, struct file *file) | |||
| 278 | goto err_free_client; | 278 | goto err_free_client; |
| 279 | 279 | ||
| 280 | file->private_data = client; | 280 | file->private_data = client; |
| 281 | nonseekable_open(inode, file); | ||
| 282 | |||
| 281 | return 0; | 283 | return 0; |
| 282 | 284 | ||
| 283 | err_free_client: | 285 | err_free_client: |
diff --git a/drivers/input/gameport/emu10k1-gp.c b/drivers/input/gameport/emu10k1-gp.c index b04930f7ea7d..7392992da424 100644 --- a/drivers/input/gameport/emu10k1-gp.c +++ b/drivers/input/gameport/emu10k1-gp.c | |||
| @@ -46,7 +46,7 @@ struct emu { | |||
| 46 | int size; | 46 | int size; |
| 47 | }; | 47 | }; |
| 48 | 48 | ||
| 49 | static struct pci_device_id emu_tbl[] = { | 49 | static const struct pci_device_id emu_tbl[] = { |
| 50 | 50 | ||
| 51 | { 0x1102, 0x7002, PCI_ANY_ID, PCI_ANY_ID }, /* SB Live gameport */ | 51 | { 0x1102, 0x7002, PCI_ANY_ID, PCI_ANY_ID }, /* SB Live gameport */ |
| 52 | { 0x1102, 0x7003, PCI_ANY_ID, PCI_ANY_ID }, /* Audigy gameport */ | 52 | { 0x1102, 0x7003, PCI_ANY_ID, PCI_ANY_ID }, /* Audigy gameport */ |
diff --git a/drivers/input/gameport/fm801-gp.c b/drivers/input/gameport/fm801-gp.c index 8a1810f88b9e..14d3f3e208a2 100644 --- a/drivers/input/gameport/fm801-gp.c +++ b/drivers/input/gameport/fm801-gp.c | |||
| @@ -140,7 +140,7 @@ static void __devexit fm801_gp_remove(struct pci_dev *pci) | |||
| 140 | } | 140 | } |
| 141 | } | 141 | } |
| 142 | 142 | ||
| 143 | static struct pci_device_id fm801_gp_id_table[] = { | 143 | static const struct pci_device_id fm801_gp_id_table[] = { |
| 144 | { PCI_VENDOR_ID_FORTEMEDIA, PCI_DEVICE_ID_FM801_GP, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0 }, | 144 | { PCI_VENDOR_ID_FORTEMEDIA, PCI_DEVICE_ID_FM801_GP, PCI_ANY_ID, PCI_ANY_ID, 0, 0, 0 }, |
| 145 | { 0 } | 145 | { 0 } |
| 146 | }; | 146 | }; |
diff --git a/drivers/input/gameport/gameport.c b/drivers/input/gameport/gameport.c index ac11be08585e..7e18bcf05a66 100644 --- a/drivers/input/gameport/gameport.c +++ b/drivers/input/gameport/gameport.c | |||
| @@ -11,6 +11,8 @@ | |||
| 11 | * the Free Software Foundation. | 11 | * the Free Software Foundation. |
| 12 | */ | 12 | */ |
| 13 | 13 | ||
| 14 | #define pr_fmt(fmt) KBUILD_MODNAME ": " fmt | ||
| 15 | |||
| 14 | #include <linux/stddef.h> | ||
