aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/hid.h
diff options
context:
space:
mode:
authorMichal Marek <mmarek@suse.cz>2010-10-27 18:15:57 -0400
committerMichal Marek <mmarek@suse.cz>2010-10-27 18:15:57 -0400
commitb74b953b998bcc2db91b694446f3a2619ec32de6 (patch)
tree6ce24caabd730f6ae9287ed0676ec32e6ff31e9d /include/linux/hid.h
parentabb438526201c6a79949ad45375c051b6681c253 (diff)
parentf6f94e2ab1b33f0082ac22d71f66385a60d8157f (diff)
Merge commit 'v2.6.36' into kbuild/misc
Update to be able to fix a recent change to scripts/basic/docproc.c (commit eda603f).
Diffstat (limited to 'include/linux/hid.h')
-rw-r--r--include/linux/hid.h16
1 files changed, 14 insertions, 2 deletions
diff --git a/include/linux/hid.h b/include/linux/hid.h
index 87093652dda8..42a0f1d11365 100644
--- a/include/linux/hid.h
+++ b/include/linux/hid.h
@@ -308,11 +308,14 @@ struct hid_item {
308#define HID_QUIRK_NOTOUCH 0x00000002 308#define HID_QUIRK_NOTOUCH 0x00000002
309#define HID_QUIRK_IGNORE 0x00000004 309#define HID_QUIRK_IGNORE 0x00000004
310#define HID_QUIRK_NOGET 0x00000008 310#define HID_QUIRK_NOGET 0x00000008
311#define HID_QUIRK_HIDDEV_FORCE 0x00000010
311#define HID_QUIRK_BADPAD 0x00000020 312#define HID_QUIRK_BADPAD 0x00000020
312#define HID_QUIRK_MULTI_INPUT 0x00000040 313#define HID_QUIRK_MULTI_INPUT 0x00000040
314#define HID_QUIRK_HIDINPUT_FORCE 0x00000080
313#define HID_QUIRK_SKIP_OUTPUT_REPORTS 0x00010000 315#define HID_QUIRK_SKIP_OUTPUT_REPORTS 0x00010000
314#define HID_QUIRK_FULLSPEED_INTERVAL 0x10000000 316#define HID_QUIRK_FULLSPEED_INTERVAL 0x10000000
315#define HID_QUIRK_NO_INIT_REPORTS 0x20000000 317#define HID_QUIRK_NO_INIT_REPORTS 0x20000000
318#define HID_QUIRK_NO_IGNORE 0x40000000
316 319
317/* 320/*
318 * This is the global environment of the parser. This information is 321 * This is the global environment of the parser. This information is
@@ -501,7 +504,7 @@ struct hid_device { /* device report descriptor */
501 void (*hiddev_report_event) (struct hid_device *, struct hid_report *); 504 void (*hiddev_report_event) (struct hid_device *, struct hid_report *);
502 505
503 /* handler for raw output data, used by hidraw */ 506 /* handler for raw output data, used by hidraw */
504 int (*hid_output_raw_report) (struct hid_device *, __u8 *, size_t); 507 int (*hid_output_raw_report) (struct hid_device *, __u8 *, size_t, unsigned char);
505 508
506 /* debugging support via debugfs */ 509 /* debugging support via debugfs */
507 unsigned short debug; 510 unsigned short debug;
@@ -589,6 +592,9 @@ struct hid_usage_id {
589 * @report_fixup: called before report descriptor parsing (NULL means nop) 592 * @report_fixup: called before report descriptor parsing (NULL means nop)
590 * @input_mapping: invoked on input registering before mapping an usage 593 * @input_mapping: invoked on input registering before mapping an usage
591 * @input_mapped: invoked on input registering after mapping an usage 594 * @input_mapped: invoked on input registering after mapping an usage
595 * @suspend: invoked on suspend (NULL means nop)
596 * @resume: invoked on resume if device was not reset (NULL means nop)
597 * @reset_resume: invoked on resume if device was reset (NULL means nop)
592 * 598 *
593 * raw_event and event should return 0 on no action performed, 1 when no 599 * raw_event and event should return 0 on no action performed, 1 when no
594 * further processing should be done and negative on error 600 * further processing should be done and negative on error
@@ -629,6 +635,11 @@ struct hid_driver {
629 int (*input_mapped)(struct hid_device *hdev, 635 int (*input_mapped)(struct hid_device *hdev,
630 struct hid_input *hidinput, struct hid_field *field, 636 struct hid_input *hidinput, struct hid_field *field,
631 struct hid_usage *usage, unsigned long **bit, int *max); 637 struct hid_usage *usage, unsigned long **bit, int *max);
638#ifdef CONFIG_PM
639 int (*suspend)(struct hid_device *hdev, pm_message_t message);
640 int (*resume)(struct hid_device *hdev);
641 int (*reset_resume)(struct hid_device *hdev);
642#endif
632/* private: */ 643/* private: */
633 struct device_driver driver; 644 struct device_driver driver;
634}; 645};
@@ -663,7 +674,7 @@ struct hid_ll_driver {
663 674
664/* Applications from HID Usage Tables 4/8/99 Version 1.1 */ 675/* Applications from HID Usage Tables 4/8/99 Version 1.1 */
665/* We ignore a few input applications that are not widely used */ 676/* We ignore a few input applications that are not widely used */
666#define IS_INPUT_APPLICATION(a) (((a >= 0x00010000) && (a <= 0x00010008)) || (a == 0x00010080) || (a == 0x000c0001) || (a == 0x000d0002)) 677#define IS_INPUT_APPLICATION(a) (((a >= 0x00010000) && (a <= 0x00010008)) || (a == 0x00010080) || (a == 0x000c0001) || ((a >= 0x000d0002) && (a <= 0x000d0006)))
667 678
668/* HID core API */ 679/* HID core API */
669 680
@@ -690,6 +701,7 @@ int hid_input_report(struct hid_device *, int type, u8 *, int, int);
690int hidinput_find_field(struct hid_device *hid, unsigned int type, unsigned int code, struct hid_field **field); 701int hidinput_find_field(struct hid_device *hid, unsigned int type, unsigned int code, struct hid_field **field);
691void hid_output_report(struct hid_report *report, __u8 *data); 702void hid_output_report(struct hid_report *report, __u8 *data);
692struct hid_device *hid_allocate_device(void); 703struct hid_device *hid_allocate_device(void);
704struct hid_report *hid_register_report(struct hid_device *device, unsigned type, unsigned id);
693int hid_parse_report(struct hid_device *hid, __u8 *start, unsigned size); 705int hid_parse_report(struct hid_device *hid, __u8 *start, unsigned size);
694int hid_check_keys_pressed(struct hid_device *hid); 706int hid_check_keys_pressed(struct hid_device *hid);
695int hid_connect(struct hid_device *hid, unsigned int connect_mask); 707int hid_connect(struct hid_device *hid, unsigned int connect_mask);