aboutsummaryrefslogtreecommitdiff
path: root/include/hw/usb
diff options
context:
space:
mode:
authorCésar Belley <cesar.belley@lse.epita.fr>2020-08-12 11:41:23 +0200
committerGerd Hoffmann <kraxel@redhat.com>2020-08-31 08:10:47 +0200
commit84b6c23629df888f1c11cace155704a97a239f7c (patch)
treebc291ed486754b010fe53ed4813b2b8f8d6eab62 /include/hw/usb
parent10b2d90c947e557a2ec5c58919d2b5ad3c400c50 (diff)
hw/usb: Regroup USB HID protocol values
Group some HID values that are used pretty much everywhere when dealing with HID devices. Signed-off-by: César Belley <cesar.belley@lse.epita.fr> Message-id: 20200812094135.20550-2-cesar.belley@lse.epita.fr Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Diffstat (limited to 'include/hw/usb')
-rw-r--r--include/hw/usb/hid.h17
1 files changed, 17 insertions, 0 deletions
diff --git a/include/hw/usb/hid.h b/include/hw/usb/hid.h
new file mode 100644
index 0000000000..1c142584ff
--- /dev/null
+++ b/include/hw/usb/hid.h
@@ -0,0 +1,17 @@
+#ifndef HW_USB_HID_H
+#define HW_USB_HID_H
+
+/* HID interface requests */
+#define HID_GET_REPORT 0xa101
+#define HID_GET_IDLE 0xa102
+#define HID_GET_PROTOCOL 0xa103
+#define HID_SET_REPORT 0x2109
+#define HID_SET_IDLE 0x210a
+#define HID_SET_PROTOCOL 0x210b
+
+/* HID descriptor types */
+#define USB_DT_HID 0x21
+#define USB_DT_REPORT 0x22
+#define USB_DT_PHY 0x23
+
+#endif