From 55e0c07757deebc0c6094915fae19fc0959849e4 Mon Sep 17 00:00:00 2001 From: Andrey Konovalov Date: Mon, 22 Jul 2019 19:25:54 +0200 Subject: sys/linux: extract USB HID ids (#1294) * sys/linux: extract USB HID ids As it turns out the HID kernel subsystem registers only one USB driver that checks that the interface of the connected device has HID class and then looks up its own list of vendor/device ids to find a matching driver. This means that we currently don't generate proper vendor/device ids for USB HID devices. This patch updates the syz-usbgen tool to also extract USB HID vendor/device ids from a running kernel and makes the generated descriptions for HID devices to be patched using the extracted ids. This patch also contains some minor improvements to USB descriptions (better HID descriptions and more replies for some USB classes/drivers). * sys/linux: run make generate --- sys/linux/vusb_amd64.const | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) (limited to 'sys/linux/vusb_amd64.const') diff --git a/sys/linux/vusb_amd64.const b/sys/linux/vusb_amd64.const index d3835583c..21ff42280 100644 --- a/sys/linux/vusb_amd64.const +++ b/sys/linux/vusb_amd64.const @@ -1,4 +1,15 @@ # AUTOGENERATED FILE +AX88172_CMD_READ_NODE_ID = 23 +AX_CMD_READ_EEPROM = 11 +AX_CMD_READ_GPIOS = 30 +AX_CMD_READ_MEDIUM_STATUS = 26 +AX_CMD_READ_MII_REG = 7 +AX_CMD_READ_MONITOR_MODE = 28 +AX_CMD_READ_NODE_ID = 19 +AX_CMD_READ_PHY_ID = 25 +AX_CMD_READ_RX_CTL = 15 +AX_CMD_STATMNGSTS_REG = 9 +AX_CMD_SW_PHY_STATUS = 33 CONTAINER_ID_TYPE = 4 HID_DT_HID = 33 HID_DT_PHYSICAL = 35 @@ -51,6 +62,15 @@ HUB_CHAR_PORTIND = 128 HUB_CHAR_TTTT = 96 HUB_STATUS_LOCAL_POWER = 1 HUB_STATUS_OVERCURRENT = 2 +UAC_GET_CUR = 129 +UAC_GET_MAX = 131 +UAC_GET_MEM = 133 +UAC_GET_MIN = 130 +UAC_GET_RES = 132 +USBLP_REQ_GET_ID = 0 +USBLP_REQ_GET_STATUS = 1 +USBLP_REQ_HP_CHANNEL_CHANGE_REQUEST = 0 +USBLP_REQ_RESET = 2 USB_5GBPS_OPERATION = 8 USB_BESL_BASELINE_VALID = 8 USB_BESL_DEEP_VALID = 16 @@ -141,6 +161,7 @@ USB_FULL_SPEED_OPERATION = 2 USB_HIGH_SPEED_OPERATION = 4 USB_HUB_PORTS_BITS = 4 USB_INTERFACE_PROTOCOL_KEYBOARD = 1 +USB_INTERFACE_PROTOCOL_MOUSE = 2 USB_INTERFACE_SUBCLASS_BOOT = 1 USB_LOW_SPEED_OPERATION = 1 USB_LPM_SUPPORT = 2 -- cgit mrf-deployment