aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/macintosh
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@woody.linux-foundation.org>2007-05-23 11:11:43 -0400
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-05-23 11:11:43 -0400
commit31f6e1bd3b58c9a67e5ea0c2d372fbf5fc9e326d (patch)
treeb0f75a9353f2e9a82c6839a4f507eeb40ffc5fc5 /drivers/macintosh
parentad9ddd66c6e8a79630a975ff0bb8d45a11abe630 (diff)
parent230ffc8e348e7841b79fd7c659d16aa5d7ec8a69 (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: Input: ads7846 - SPI_CPHA mode bugfix Input: ads7846 - document that it handles tsc2046 too Input: input-polldev - add module info Input: ucb1x00-ts - remove commented out code Input: ucb1400_ts - use sched_setscheduler() Input: ALPS - force stream mode Input: iforce - minor clean-ups Input: iforce - fix force feedback not working Input: adbhid - do not access input_dev->private directly Input: logips2pp - add type 72 (PS/2 TrackMan Marble)
Diffstat (limited to 'drivers/macintosh')
-rw-r--r--drivers/macintosh/adbhid.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/drivers/macintosh/adbhid.c b/drivers/macintosh/adbhid.c
index b77ef5187d6d..b46817f699f1 100644
--- a/drivers/macintosh/adbhid.c
+++ b/drivers/macintosh/adbhid.c
@@ -628,16 +628,16 @@ static void real_leds(unsigned char leds, int device)
628 */ 628 */
629static int adbhid_kbd_event(struct input_dev *dev, unsigned int type, unsigned int code, int value) 629static int adbhid_kbd_event(struct input_dev *dev, unsigned int type, unsigned int code, int value)
630{ 630{
631 struct adbhid *adbhid = dev->private; 631 struct adbhid *adbhid = input_get_drvdata(dev);
632 unsigned char leds; 632 unsigned char leds;
633 633
634 switch (type) { 634 switch (type) {
635 case EV_LED: 635 case EV_LED:
636 leds = (test_bit(LED_SCROLLL, dev->led) ? 4 : 0) 636 leds = (test_bit(LED_SCROLLL, dev->led) ? 4 : 0) |
637 | (test_bit(LED_NUML, dev->led) ? 1 : 0) 637 (test_bit(LED_NUML, dev->led) ? 1 : 0) |
638 | (test_bit(LED_CAPSL, dev->led) ? 2 : 0); 638 (test_bit(LED_CAPSL, dev->led) ? 2 : 0);
639 real_leds(leds, adbhid->id); 639 real_leds(leds, adbhid->id);
640 return 0; 640 return 0;
641 } 641 }
642 642
643 return -1; 643 return -1;
@@ -649,7 +649,7 @@ adb_message_handler(struct notifier_block *this, unsigned long code, void *x)
649 switch (code) { 649 switch (code) {
650 case ADB_MSG_PRE_RESET: 650 case ADB_MSG_PRE_RESET:
651 case ADB_MSG_POWERDOWN: 651 case ADB_MSG_POWERDOWN:
652 /* Stop the repeat timer. Autopoll is already off at this point */ 652 /* Stop the repeat timer. Autopoll is already off at this point */
653 { 653 {
654 int i; 654 int i;
655 for (i = 1; i < 16; i++) { 655 for (i = 1; i < 16; i++) {
@@ -699,7 +699,7 @@ adbhid_input_register(int id, int default_id, int original_handler_id,
699 hid->current_handler_id = current_handler_id; 699 hid->current_handler_id = current_handler_id;
700 hid->mouse_kind = mouse_kind; 700 hid->mouse_kind = mouse_kind;
701 hid->flags = 0; 701 hid->flags = 0;
702 input_dev->private = hid; 702 input_set_drvdata(input_dev, hid);
703 input_dev->name = hid->name; 703 input_dev->name = hid->name;
704 input_dev->phys = hid->phys; 704 input_dev->phys = hid->phys;
705 input_dev->id.bustype = BUS_ADB; 705 input_dev->id.bustype = BUS_ADB;