Merge branches 'debug-module-param' and 'upstream' into for-linus
authorJiri Kosina <jkosina@suse.cz>
Mon, 9 Jul 2007 12:23:37 +0000 (14:23 +0200)
committerJiri Kosina <jkosina@suse.cz>
Mon, 9 Jul 2007 12:23:37 +0000 (14:23 +0200)
1  2 
drivers/hid/Kconfig
drivers/hid/hid-input.c
drivers/hid/usbhid/hid-core.c
drivers/hid/usbhid/hid-quirks.c
include/linux/hid.h

Simple merge
index 38595d3935cee15111104e5fb507a31d4c024a3c,bf7e307503cc9b9f992f1e8eaf245d4eb4e151f6..8edbd30cf7955bcb54e80d2ce42fe6f2f545b8e2
@@@ -814,10 -882,20 +878,20 @@@ static void hidinput_configure_usage(st
                        field->dpad = usage->code;
        }
  
+       /* for those devices which produce Consumer volume usage as relative,
+        * we emulate pressing volumeup/volumedown appropriate number of times
+        * in hidinput_hid_event()
+        */
+       if ((usage->type == EV_ABS) && (field->flags & HID_MAIN_ITEM_RELATIVE) &&
+                       (usage->code == ABS_VOLUME)) {
+               set_bit(KEY_VOLUMEUP, input->keybit);
+               set_bit(KEY_VOLUMEDOWN, input->keybit);
+       }
        hid_resolv_event(usage->type, usage->code);
 -#ifdef CONFIG_HID_DEBUG
 -      printk("\n");
 -#endif
 +
 +      dbg_hid_line("\n");
 +
        return;
  
  ignore:
index 1eb2c64bc44adebc6425f14f7e1840617e892bd0,3efc3734cec2881cb942ff40258de3d759a569f1..3afa4a5035b7128b6e84fdc835637bdb9c690b74
@@@ -772,22 -724,19 +724,17 @@@ static struct hid_device *usb_hid_confi
                return NULL;
        }
  
-       if ((quirks & HID_QUIRK_CYMOTION))
-               hid_fixup_cymotion_descriptor(rdesc, rsize);
-       if (quirks & HID_QUIRK_LOGITECH_DESCRIPTOR)
-               hid_fixup_logitech_descriptor(rdesc, rsize);
-       if (quirks & HID_QUIRK_SWAPPED_MIN_MAX)
-               hid_fixup_cypress_descriptor(rdesc, rsize);
+       usbhid_fixup_report_descriptor(le16_to_cpu(dev->descriptor.idVendor),
+                       le16_to_cpu(dev->descriptor.idProduct), rdesc,
+                       rsize, rdesc_quirks_param);
  
 -#ifdef CONFIG_HID_DEBUG
 -      printk(KERN_DEBUG __FILE__ ": report descriptor (size %u, read %d) = ", rsize, n);
 +      dbg_hid("report descriptor (size %u, read %d) = ", rsize, n);
        for (n = 0; n < rsize; n++)
 -              printk(" %02x", (unsigned char) rdesc[n]);
 -      printk("\n");
 -#endif
 +              dbg_hid_line(" %02x", (unsigned char) rdesc[n]);
 +      dbg_hid_line("\n");
  
        if (!(hid = hid_parse_report(rdesc, n))) {
 -              dbg("parsing report descriptor failed");
 +              dbg_hid("parsing report descriptor failed\n");
                kfree(rdesc);
                return NULL;
        }
Simple merge
Simple merge