aboutsummaryrefslogtreecommitdiffstats
path: root/sys/linux
diff options
context:
space:
mode:
authorAndrey Konovalov <andreyknvl@google.com>2019-06-24 16:41:54 +0200
committerAndrey Konovalov <andreyknvl@gmail.com>2019-06-24 17:24:44 +0200
commit82c13b6b49369ae3f3846e867fe1b8e0c21eefc0 (patch)
tree8ae5d78653e8c1c6872fbb9877fbbe24c1e09f6a /sys/linux
parentfa26c3cf35b4c8849e53da15351f1941aee227e1 (diff)
sys/linux, executor: run make extract and generate
Diffstat (limited to 'sys/linux')
-rw-r--r--sys/linux/gen/386.go139
-rw-r--r--sys/linux/gen/amd64.go139
-rw-r--r--sys/linux/gen/arm.go139
-rw-r--r--sys/linux/gen/arm64.go139
-rw-r--r--sys/linux/gen/ppc64le.go139
-rw-r--r--sys/linux/vusb_386.const11
-rw-r--r--sys/linux/vusb_amd64.const11
-rw-r--r--sys/linux/vusb_arm.const11
-rw-r--r--sys/linux/vusb_arm64.const11
-rw-r--r--sys/linux/vusb_ppc64le.const11
10 files changed, 700 insertions, 50 deletions
diff --git a/sys/linux/gen/386.go b/sys/linux/gen/386.go
index 5633efc18..1a19c1325 100644
--- a/sys/linux/gen/386.go
+++ b/sys/linux/gen/386.go
@@ -112,6 +112,7 @@ var resources_386 = []*ResourceDesc{
{Name: "fd_uhid", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd", "fd_uhid"}, Values: []uint64{18446744073709551615, 18446744073709551516}},
{Name: "fd_uinput", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd", "fd_uinput"}, Values: []uint64{18446744073709551615, 18446744073709551516}},
{Name: "fd_usb", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd_usb"}, Values: []uint64{18446744073709551615}},
+ {Name: "fd_usb_hid", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd_usb", "fd_usb_hid"}, Values: []uint64{18446744073709551615}},
{Name: "fd_userio", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd", "fd_userio"}, Values: []uint64{18446744073709551615, 18446744073709551516}},
{Name: "fd_v4l2_buffer", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd", "fd_v4l2_buffer"}, Values: []uint64{18446744073709551615, 18446744073709551516}},
{Name: "fd_vhci", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd", "fd_vhci"}, Values: []uint64{18446744073709551615, 18446744073709551516}},
@@ -25397,9 +25398,23 @@ var structDescs_386 = []*KeyedStruct{
&BufferType{TypeCommon: TypeCommon{TypeName: "array", FldName: "slave_interfaces", IsVarlen: true}, Kind: 1, RangeEnd: 6},
}}},
{Key: StructKey{Name: "usb_config_descriptor"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_config_descriptor", IsVarlen: true}, Fields: []Type{
- &StructType{Key: StructKey{Name: "usb_config_descriptor_t[array[usb_interface_descriptor, 1]]"}, FldName: "inner"},
+ &StructType{Key: StructKey{Name: "usb_config_descriptor_t[flags[usb_config_attributes, int8], array[usb_interface_descriptor, 1]]"}, FldName: "inner"},
}}},
- {Key: StructKey{Name: "usb_config_descriptor_t[array[usb_interface_descriptor, 1]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_config_descriptor_t[array[usb_interface_descriptor, 1]]", IsVarlen: true}, Fields: []Type{
+ {Key: StructKey{Name: "usb_config_descriptor_hid"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_config_descriptor_hid", IsVarlen: true}, Fields: []Type{
+ &StructType{Key: StructKey{Name: "usb_config_descriptor_t[const[USB_CONFIG_HID_ATTRIBUTES, int8], array[usb_interface_descriptor_hid, 1]]"}, FldName: "inner"},
+ }}},
+ {Key: StructKey{Name: "usb_config_descriptor_t[const[USB_CONFIG_HID_ATTRIBUTES, int8], array[usb_interface_descriptor_hid, 1]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_config_descriptor_t[const[USB_CONFIG_HID_ATTRIBUTES, int8], array[usb_interface_descriptor_hid, 1]]", IsVarlen: true}, Fields: []Type{
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 9},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 2},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "wTotalLength", TypeSize: 2}}, Path: []string{"parent"}},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "bNumInterfaces", TypeSize: 1}}, Path: []string{"interfaces"}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bConfigurationValue", TypeSize: 1}}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "iConfiguration", TypeSize: 1}}},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bmAttributes", TypeSize: 1}}, Val: 160},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bMaxPower", TypeSize: 1}}},
+ &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "interfaces", IsVarlen: true}, Type: &StructType{Key: StructKey{Name: "usb_interface_descriptor_hid"}}, Kind: 1, RangeBegin: 1, RangeEnd: 1},
+ }}},
+ {Key: StructKey{Name: "usb_config_descriptor_t[flags[usb_config_attributes, int8], array[usb_interface_descriptor, 1]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_config_descriptor_t[flags[usb_config_attributes, int8], array[usb_interface_descriptor, 1]]", IsVarlen: true}, Fields: []Type{
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 9},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 2},
&LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "wTotalLength", TypeSize: 2}}, Path: []string{"parent"}},
@@ -25422,14 +25437,17 @@ var structDescs_386 = []*KeyedStruct{
{Key: StructKey{Name: "usb_device_descriptor"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_device_descriptor", IsVarlen: true}, Fields: []Type{
&StructType{Key: StructKey{Name: "usb_device_descriptor_t[0, 0, 0, 0, 0, 0, array[usb_config_descriptor, 1]]"}, FldName: "inner"},
}}},
+ {Key: StructKey{Name: "usb_device_descriptor_hid"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_device_descriptor_hid", IsVarlen: true}, Fields: []Type{
+ &StructType{Key: StructKey{Name: "usb_device_descriptor_t[0, 0, 0, 0x46d, 0xc31c, 64, array[usb_config_descriptor_hid, 1]]"}, FldName: "inner"},
+ }}},
{Key: StructKey{Name: "usb_device_descriptor_t[0, 0, 0, 0, 0, 0, array[usb_config_descriptor, 1]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_device_descriptor_t[0, 0, 0, 0, 0, 0, array[usb_config_descriptor, 1]]", IsVarlen: true}, Fields: []Type{
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 18},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 1},
- &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "bcdUSB", TypeSize: 2}}},
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_versions", FldName: "bcdUSB", TypeSize: 2}}, Vals: []uint64{272, 512, 513, 592, 768, 784}},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDeviceClass", TypeSize: 1}}},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDeviceSubClass", TypeSize: 1}}},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDeviceProtocol", TypeSize: 1}}},
- &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bMaxPacketSize0", TypeSize: 1}}},
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_max_packet_sizes", FldName: "bMaxPacketSize0", TypeSize: 1}}, Vals: []uint64{8, 16, 32, 64}, BitMask: true},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "idVendor", TypeSize: 2}}},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "idProduct", TypeSize: 2}}},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bcdDevice", TypeSize: 2}}},
@@ -25439,13 +25457,44 @@ var structDescs_386 = []*KeyedStruct{
&LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "bNumConfigurations", TypeSize: 1}}, Path: []string{"configs"}},
&ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "configs", IsVarlen: true}, Type: &StructType{Key: StructKey{Name: "usb_config_descriptor"}}, Kind: 1, RangeBegin: 1, RangeEnd: 1},
}}},
+ {Key: StructKey{Name: "usb_device_descriptor_t[0, 0, 0, 0x46d, 0xc31c, 64, array[usb_config_descriptor_hid, 1]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_device_descriptor_t[0, 0, 0, 0x46d, 0xc31c, 64, array[usb_config_descriptor_hid, 1]]", IsVarlen: true}, Fields: []Type{
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 18},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 1},
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_versions", FldName: "bcdUSB", TypeSize: 2}}, Vals: []uint64{272, 512, 513, 592, 768, 784}},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDeviceClass", TypeSize: 1}}},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDeviceSubClass", TypeSize: 1}}},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDeviceProtocol", TypeSize: 1}}},
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_max_packet_sizes", FldName: "bMaxPacketSize0", TypeSize: 1}}, Vals: []uint64{8, 16, 32, 64}, BitMask: true},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "idVendor", TypeSize: 2}}, Val: 1133},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "idProduct", TypeSize: 2}}, Val: 49948},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bcdDevice", TypeSize: 2}}, Val: 64},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "iManufacturer", TypeSize: 1}}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "iProduct", TypeSize: 1}}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "iSerialNumber", TypeSize: 1}}},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "bNumConfigurations", TypeSize: 1}}, Path: []string{"configs"}},
+ &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "configs", IsVarlen: true}, Type: &StructType{Key: StructKey{Name: "usb_config_descriptor_hid"}}, Kind: 1, RangeBegin: 1, RangeEnd: 1},
+ }}},
{Key: StructKey{Name: "usb_endpoint_descriptor"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_endpoint_descriptor", IsVarlen: true}, Fields: []Type{
- &StructType{Key: StructKey{Name: "usb_endpoint_descriptor_t[array[usb_endpoint_extra_descriptor, 0:2]]"}, FldName: "inner"},
+ &StructType{Key: StructKey{Name: "usb_endpoint_descriptor_t[flags[usb_endpoint_addresses, int8], flags[usb_endpoint_attributes, int8], array[usb_endpoint_extra_descriptor, 0:2]]"}, FldName: "inner"},
+ }}},
+ {Key: StructKey{Name: "usb_endpoint_descriptor_hid"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_endpoint_descriptor_hid", IsVarlen: true}, Fields: []Type{
+ &StructType{Key: StructKey{Name: "usb_endpoint_descriptor_t[const[USB_ENDPOINT_HID_ADDRESS, int8], const[USB_ENDPOINT_HID_ATTRIBUTES, int8], array[usb_endpoint_extra_descriptor, 0:2]]"}, FldName: "inner"},
+ }}},
+ {Key: StructKey{Name: "usb_endpoint_descriptor_t[const[USB_ENDPOINT_HID_ADDRESS, int8], const[USB_ENDPOINT_HID_ATTRIBUTES, int8], array[usb_endpoint_extra_descriptor, 0:2]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_endpoint_descriptor_t[const[USB_ENDPOINT_HID_ADDRESS, int8], const[USB_ENDPOINT_HID_ATTRIBUTES, int8], array[usb_endpoint_extra_descriptor, 0:2]]", IsVarlen: true}, Fields: []Type{
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 7},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 5},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bEndpointAddress", TypeSize: 1}}, Val: 129},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bmAttributes", TypeSize: 1}}, Val: 3},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "wMaxPacketSize", TypeSize: 2}}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bInterval", TypeSize: 1}}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bRefresh", TypeSize: 1}}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bSynchAddress", TypeSize: 1}}},
+ &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "extra", IsVarlen: true}, Type: &UnionType{Key: StructKey{Name: "usb_endpoint_extra_descriptor"}}, Kind: 1, RangeEnd: 2},
}}},
- {Key: StructKey{Name: "usb_endpoint_descriptor_t[array[usb_endpoint_extra_descriptor, 0:2]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_endpoint_descriptor_t[array[usb_endpoint_extra_descriptor, 0:2]]", IsVarlen: true}, Fields: []Type{
+ {Key: StructKey{Name: "usb_endpoint_descriptor_t[flags[usb_endpoint_addresses, int8], flags[usb_endpoint_attributes, int8], array[usb_endpoint_extra_descriptor, 0:2]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_endpoint_descriptor_t[flags[usb_endpoint_addresses, int8], flags[usb_endpoint_attributes, int8], array[usb_endpoint_extra_descriptor, 0:2]]", IsVarlen: true}, Fields: []Type{
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 7},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 5},
- &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bEndpointAddress", TypeSize: 1}}},
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_endpoint_addresses", FldName: "bEndpointAddress", TypeSize: 1}}, Vals: []uint64{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 0, 128}},
&FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_endpoint_attributes", FldName: "bmAttributes", TypeSize: 1}}, Vals: []uint64{0, 1, 2, 3, 0, 16, 0, 4, 8, 12, 0, 16, 16}},
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "wMaxPacketSize", TypeSize: 2}}},
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bInterval", TypeSize: 1}}},
@@ -25504,6 +25553,9 @@ var structDescs_386 = []*KeyedStruct{
{Key: StructKey{Name: "usb_interface_descriptor"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_interface_descriptor", IsVarlen: true}, Fields: []Type{
&StructType{Key: StructKey{Name: "usb_interface_descriptor_t[0, 0, 0, array[usb_interface_extra_descriptor, 0:2], array[usb_endpoint_descriptor, 0:16]]"}, FldName: "inner"},
}}},
+ {Key: StructKey{Name: "usb_interface_descriptor_hid"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_interface_descriptor_hid", IsVarlen: true}, Fields: []Type{
+ &StructType{Key: StructKey{Name: "usb_interface_descriptor_t[USB_CLASS_HID, USB_INTERFACE_SUBCLASS_BOOT, USB_INTERFACE_PROTOCOL_KEYBOARD, hid_descriptor_hid, array[usb_endpoint_descriptor_hid, 1]]"}, FldName: "inner"},
+ }}},
{Key: StructKey{Name: "usb_interface_descriptor_t[0, 0, 0, array[usb_interface_extra_descriptor, 0:2], array[usb_endpoint_descriptor, 0:16]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_interface_descriptor_t[0, 0, 0, array[usb_interface_extra_descriptor, 0:2], array[usb_endpoint_descriptor, 0:16]]", IsVarlen: true}, Fields: []Type{
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 9},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 4},
@@ -25517,6 +25569,19 @@ var structDescs_386 = []*KeyedStruct{
&ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "extra", IsVarlen: true}, Type: &UnionType{Key: StructKey{Name: "usb_interface_extra_descriptor"}}, Kind: 1, RangeEnd: 2},
&ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "endpoints", IsVarlen: true}, Type: &StructType{Key: StructKey{Name: "usb_endpoint_descriptor"}}, Kind: 1, RangeEnd: 16},
}}},
+ {Key: StructKey{Name: "usb_interface_descriptor_t[USB_CLASS_HID, USB_INTERFACE_SUBCLASS_BOOT, USB_INTERFACE_PROTOCOL_KEYBOARD, hid_descriptor_hid, array[usb_endpoint_descriptor_hid, 1]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_interface_descriptor_t[USB_CLASS_HID, USB_INTERFACE_SUBCLASS_BOOT, USB_INTERFACE_PROTOCOL_KEYBOARD, hid_descriptor_hid, array[usb_endpoint_descriptor_hid, 1]]", IsVarlen: true}, Fields: []Type{
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 9},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 4},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bInterfaceNumber", TypeSize: 1}}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bAlternateSetting", TypeSize: 1}}},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "bNumEndpoints", TypeSize: 1}}, Path: []string{"endpoints"}},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bInterfaceClass", TypeSize: 1}}, Val: 3},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bInterfaceSubClass", TypeSize: 1}}, Val: 1},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bInterfaceProtocol", TypeSize: 1}}, Val: 1},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "iInterface", TypeSize: 1}}},
+ &StructType{Key: StructKey{Name: "hid_descriptor_hid"}, FldName: "extra"},
+ &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "endpoints", IsVarlen: true}, Type: &StructType{Key: StructKey{Name: "usb_endpoint_descriptor_hid"}}, Kind: 1, RangeBegin: 1, RangeEnd: 1},
+ }}},
{Key: StructKey{Name: "usb_interface_extra_descriptor"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_interface_extra_descriptor", IsVarlen: true}, Fields: []Type{
&StructType{Key: StructKey{Name: "usb_generic_descriptor"}, FldName: "generic"},
&StructType{Key: StructKey{Name: "hid_descriptor_hid"}, FldName: "hid_hid"},
@@ -25535,11 +25600,11 @@ var structDescs_386 = []*KeyedStruct{
{Key: StructKey{Name: "usb_qualifier_descriptor"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_qualifier_descriptor", TypeSize: 10}, Fields: []Type{
&LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "bLength", TypeSize: 1}}, Path: []string{"parent"}},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 6},
- &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "bcdUSB", TypeSize: 2}}},
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_versions", FldName: "bcdUSB", TypeSize: 2}}, Vals: []uint64{272, 512, 513, 592, 768, 784}},
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bDeviceClass", TypeSize: 1}}},
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bDeviceSubClass", TypeSize: 1}}},
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bDeviceProtocol", TypeSize: 1}}},
- &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bMaxPacketSize0", TypeSize: 1}}},
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_max_packet_sizes", FldName: "bMaxPacketSize0", TypeSize: 1}}, Vals: []uint64{8, 16, 32, 64}, BitMask: true},
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bNumConfigurations", TypeSize: 1}}},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bRESERVED", TypeSize: 1}}},
}}},
@@ -26698,12 +26763,37 @@ var structDescs_386 = []*KeyedStruct{
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "hub_hs", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "vusb_descriptor_t[USB_TYPE_STANDARD, USB_DT_HUB, usb_hub_descriptor_hs]"}}},
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "hub_ss", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "vusb_descriptor_t[USB_TYPE_STANDARD, USB_DT_SS_HUB, usb_hub_descriptor_ss]"}}},
}}},
+ {Key: StructKey{Name: "vusb_descriptors_hid"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "vusb_descriptors_hid", TypeSize: 20}, Fields: []Type{
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "len", TypeSize: 4}}, Path: []string{"parent"}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "generic", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "vusb_descriptor_generic"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "string", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "vusb_descriptor_t[USB_TYPE_STANDARD, USB_DT_STRING, usb_string_descriptor]"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "hid_report", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "vusb_descriptor_t[USB_TYPE_STANDARD, HID_DT_REPORT, hid_descriptor_report]"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "bos", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "vusb_descriptor_t[USB_TYPE_STANDARD, USB_DT_BOS, usb_bos_descriptor]"}}},
+ }}},
{Key: StructKey{Name: "vusb_response_generic"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "vusb_response_generic", IsVarlen: true}, Fields: []Type{
&FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_request_types", FldName: "type", TypeSize: 1}}, Vals: []uint64{0, 32, 64}, BitMask: true},
&FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_requests", FldName: "req", TypeSize: 1}}, Vals: []uint64{0, 1, 3, 5, 6, 7, 8, 9, 10, 11, 12, 48, 49, 13, 14, 14, 15, 15, 16, 17, 18, 19, 20, 21, 22, 23, 20, 21, 22, 23, 24}},
&LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize", FldName: "len", TypeSize: 4}}, BitSize: 8, Path: []string{"data"}},
&BufferType{TypeCommon: TypeCommon{TypeName: "array", FldName: "data", IsVarlen: true}},
}}},
+ {Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_IDLE, void]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_IDLE, void]", TypeSize: 6}, Fields: []Type{
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "type", TypeSize: 1}}, Val: 32},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "req", TypeSize: 1}}, Val: 10},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize", FldName: "len", TypeSize: 4}}, BitSize: 8, Path: []string{"data"}},
+ &BufferType{TypeCommon: TypeCommon{TypeName: "void", FldName: "data"}, Kind: 1},
+ }}},
+ {Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_PROTOCOL, void]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_PROTOCOL, void]", TypeSize: 6}, Fields: []Type{
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "type", TypeSize: 1}}, Val: 32},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "req", TypeSize: 1}}, Val: 11},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize", FldName: "len", TypeSize: 4}}, BitSize: 8, Path: []string{"data"}},
+ &BufferType{TypeCommon: TypeCommon{TypeName: "void", FldName: "data"}, Kind: 1},
+ }}},
+ {Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_REPORT, void]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_REPORT, void]", TypeSize: 6}, Fields: []Type{
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "type", TypeSize: 1}}, Val: 32},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "req", TypeSize: 1}}, Val: 9},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize", FldName: "len", TypeSize: 4}}, BitSize: 8, Path: []string{"data"}},
+ &BufferType{TypeCommon: TypeCommon{TypeName: "void", FldName: "data"}, Kind: 1},
+ }}},
{Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, USB_CDC_GET_NTB_PARAMETERS, usb_cdc_ncm_ntb_parameters]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "vusb_response_t[USB_TYPE_CLASS, USB_CDC_GET_NTB_PARAMETERS, usb_cdc_ncm_ntb_parameters]", TypeSize: 34}, Fields: []Type{
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "type", TypeSize: 1}}, Val: 32},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "req", TypeSize: 1}}, Val: 128},
@@ -26771,6 +26861,13 @@ var structDescs_386 = []*KeyedStruct{
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "aiptek_set_report", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "vusb_response_t[USB_TYPE_VENDOR, 0x9, array[int8, 3]]"}}},
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "cdc_get_ntb_parameters", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, USB_CDC_GET_NTB_PARAMETERS, usb_cdc_ncm_ntb_parameters]"}}},
}}},
+ {Key: StructKey{Name: "vusb_responses_hid"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "vusb_responses_hid", TypeSize: 20}, Fields: []Type{
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "len", TypeSize: 4}}, Path: []string{"parent"}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "generic", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "vusb_response_generic"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "set_idle", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_IDLE, void]"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "set_report", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_REPORT, void]"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "set_protocol", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_PROTOCOL, void]"}}},
+ }}},
{Key: StructKey{Name: "winsize"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "winsize", TypeSize: 8}, Fields: []Type{
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "row", TypeSize: 2}}},
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "col", TypeSize: 2}}},
@@ -42763,11 +42860,22 @@ var syscalls_386 = []*Syscall{
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "dev", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "usb_device_descriptor"}}},
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "conn_descs", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "vusb_connect_descriptors"}}},
}, Ret: &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_usb", FldName: "ret", TypeSize: 4, ArgDir: 1}}},
+ {Name: "syz_usb_connect$hid", CallName: "syz_usb_connect", Args: []Type{
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_device_speed", FldName: "speed", TypeSize: 4}}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6}},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "dev_len", TypeSize: 4}}, Path: []string{"dev"}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "dev", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "usb_device_descriptor_hid"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "conn_descs", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "vusb_connect_descriptors"}}},
+ }, Ret: &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_usb_hid", FldName: "ret", TypeSize: 4, ArgDir: 1}}},
{Name: "syz_usb_control_io", CallName: "syz_usb_control_io", Args: []Type{
&ResourceType{TypeCommon: TypeCommon{TypeName: "fd_usb", FldName: "fd", TypeSize: 4}},
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "descs", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "vusb_descriptors"}}},
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "resps", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "vusb_responses"}}},
}},
+ {Name: "syz_usb_control_io$hid", CallName: "syz_usb_control_io", Args: []Type{
+ &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_usb_hid", FldName: "fd", TypeSize: 4}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "descs", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "vusb_descriptors_hid"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "resps", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "vusb_responses_hid"}}},
+ }},
{Name: "syz_usb_disconnect", CallName: "syz_usb_disconnect", Args: []Type{
&ResourceType{TypeCommon: TypeCommon{TypeName: "fd_usb", FldName: "fd", TypeSize: 4}},
}},
@@ -45432,6 +45540,9 @@ var consts_386 = []ConstValue{
{Name: "HID_REPORT_ID_UNKNOWN", Value: 4294967295},
{Name: "HID_REPORT_TYPE_MAX", Value: 3},
{Name: "HID_REPORT_TYPE_MIN", Value: 1},
+ {Name: "HID_REQ_SET_IDLE", Value: 10},
+ {Name: "HID_REQ_SET_PROTOCOL", Value: 11},
+ {Name: "HID_REQ_SET_REPORT", Value: 9},
{Name: "HUB_CHANGE_LOCAL_POWER", Value: 1},
{Name: "HUB_CHANGE_OVERCURRENT", Value: 2},
{Name: "HUB_CHAR_COMMON_LPSM"},
@@ -49714,10 +49825,14 @@ var consts_386 = []ConstValue{
{Name: "USB_CDC_OBEX_TYPE", Value: 21},
{Name: "USB_CDC_UNION_TYPE", Value: 6},
{Name: "USB_CDC_WHCM_TYPE", Value: 17},
+ {Name: "USB_CLASS_HID", Value: 3},
{Name: "USB_CONFIG_ATT_BATTERY", Value: 16},
{Name: "USB_CONFIG_ATT_ONE", Value: 128},
{Name: "USB_CONFIG_ATT_SELFPOWER", Value: 64},
{Name: "USB_CONFIG_ATT_WAKEUP", Value: 32},
+ {Name: "USB_CONFIG_HID_ATTRIBUTES", Value: 160},
+ {Name: "USB_DIR_IN", Value: 128},
+ {Name: "USB_DIR_OUT"},
{Name: "USB_DT_BOS", Value: 15},
{Name: "USB_DT_BOS_SIZE", Value: 5},
{Name: "USB_DT_CONFIG", Value: 2},
@@ -49749,6 +49864,8 @@ var consts_386 = []ConstValue{
{Name: "USB_DT_STRING", Value: 3},
{Name: "USB_DT_WIRELESS_ENDPOINT_COMP", Value: 17},
{Name: "USB_DT_WIRE_ADAPTER", Value: 33},
+ {Name: "USB_ENDPOINT_HID_ADDRESS", Value: 129},
+ {Name: "USB_ENDPOINT_HID_ATTRIBUTES", Value: 3},
{Name: "USB_ENDPOINT_INTR_NOTIFICATION", Value: 16},
{Name: "USB_ENDPOINT_INTR_PERIODIC"},
{Name: "USB_ENDPOINT_SYNC_ADAPTIVE", Value: 8},
@@ -49768,6 +49885,8 @@ var consts_386 = []ConstValue{
{Name: "USB_FULL_SPEED_OPERATION", Value: 2},
{Name: "USB_HIGH_SPEED_OPERATION", Value: 4},
{Name: "USB_HUB_PORTS_BITS", Value: 4},
+ {Name: "USB_INTERFACE_PROTOCOL_KEYBOARD", Value: 1},
+ {Name: "USB_INTERFACE_SUBCLASS_BOOT", Value: 1},
{Name: "USB_LOW_SPEED_OPERATION", Value: 1},
{Name: "USB_LPM_SUPPORT", Value: 2},
{Name: "USB_LTM_SUPPORT", Value: 2},
@@ -51581,4 +51700,4 @@ var consts_386 = []ConstValue{
{Name: "bpf_insn_load_imm_dw", Value: 24},
}
-const revision_386 = "7b016c59f893d8fc8b72f5117e1b98eafc6d79fc"
+const revision_386 = "1606116bedd394a0b861b0ec0a30a1c045b5e23b"
diff --git a/sys/linux/gen/amd64.go b/sys/linux/gen/amd64.go
index 2f67b0939..962673dab 100644
--- a/sys/linux/gen/amd64.go
+++ b/sys/linux/gen/amd64.go
@@ -112,6 +112,7 @@ var resources_amd64 = []*ResourceDesc{
{Name: "fd_uhid", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd", "fd_uhid"}, Values: []uint64{18446744073709551615, 18446744073709551516}},
{Name: "fd_uinput", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd", "fd_uinput"}, Values: []uint64{18446744073709551615, 18446744073709551516}},
{Name: "fd_usb", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd_usb"}, Values: []uint64{18446744073709551615}},
+ {Name: "fd_usb_hid", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd_usb", "fd_usb_hid"}, Values: []uint64{18446744073709551615}},
{Name: "fd_userio", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd", "fd_userio"}, Values: []uint64{18446744073709551615, 18446744073709551516}},
{Name: "fd_v4l2_buffer", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd", "fd_v4l2_buffer"}, Values: []uint64{18446744073709551615, 18446744073709551516}},
{Name: "fd_vhci", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd", "fd_vhci"}, Values: []uint64{18446744073709551615, 18446744073709551516}},
@@ -25768,9 +25769,23 @@ var structDescs_amd64 = []*KeyedStruct{
&BufferType{TypeCommon: TypeCommon{TypeName: "array", FldName: "slave_interfaces", IsVarlen: true}, Kind: 1, RangeEnd: 6},
}}},
{Key: StructKey{Name: "usb_config_descriptor"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_config_descriptor", IsVarlen: true}, Fields: []Type{
- &StructType{Key: StructKey{Name: "usb_config_descriptor_t[array[usb_interface_descriptor, 1]]"}, FldName: "inner"},
+ &StructType{Key: StructKey{Name: "usb_config_descriptor_t[flags[usb_config_attributes, int8], array[usb_interface_descriptor, 1]]"}, FldName: "inner"},
}}},
- {Key: StructKey{Name: "usb_config_descriptor_t[array[usb_interface_descriptor, 1]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_config_descriptor_t[array[usb_interface_descriptor, 1]]", IsVarlen: true}, Fields: []Type{
+ {Key: StructKey{Name: "usb_config_descriptor_hid"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_config_descriptor_hid", IsVarlen: true}, Fields: []Type{
+ &StructType{Key: StructKey{Name: "usb_config_descriptor_t[const[USB_CONFIG_HID_ATTRIBUTES, int8], array[usb_interface_descriptor_hid, 1]]"}, FldName: "inner"},
+ }}},
+ {Key: StructKey{Name: "usb_config_descriptor_t[const[USB_CONFIG_HID_ATTRIBUTES, int8], array[usb_interface_descriptor_hid, 1]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_config_descriptor_t[const[USB_CONFIG_HID_ATTRIBUTES, int8], array[usb_interface_descriptor_hid, 1]]", IsVarlen: true}, Fields: []Type{
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 9},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 2},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "wTotalLength", TypeSize: 2}}, Path: []string{"parent"}},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "bNumInterfaces", TypeSize: 1}}, Path: []string{"interfaces"}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bConfigurationValue", TypeSize: 1}}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "iConfiguration", TypeSize: 1}}},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bmAttributes", TypeSize: 1}}, Val: 160},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bMaxPower", TypeSize: 1}}},
+ &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "interfaces", IsVarlen: true}, Type: &StructType{Key: StructKey{Name: "usb_interface_descriptor_hid"}}, Kind: 1, RangeBegin: 1, RangeEnd: 1},
+ }}},
+ {Key: StructKey{Name: "usb_config_descriptor_t[flags[usb_config_attributes, int8], array[usb_interface_descriptor, 1]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_config_descriptor_t[flags[usb_config_attributes, int8], array[usb_interface_descriptor, 1]]", IsVarlen: true}, Fields: []Type{
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 9},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 2},
&LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "wTotalLength", TypeSize: 2}}, Path: []string{"parent"}},
@@ -25793,14 +25808,17 @@ var structDescs_amd64 = []*KeyedStruct{
{Key: StructKey{Name: "usb_device_descriptor"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_device_descriptor", IsVarlen: true}, Fields: []Type{
&StructType{Key: StructKey{Name: "usb_device_descriptor_t[0, 0, 0, 0, 0, 0, array[usb_config_descriptor, 1]]"}, FldName: "inner"},
}}},
+ {Key: StructKey{Name: "usb_device_descriptor_hid"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_device_descriptor_hid", IsVarlen: true}, Fields: []Type{
+ &StructType{Key: StructKey{Name: "usb_device_descriptor_t[0, 0, 0, 0x46d, 0xc31c, 64, array[usb_config_descriptor_hid, 1]]"}, FldName: "inner"},
+ }}},
{Key: StructKey{Name: "usb_device_descriptor_t[0, 0, 0, 0, 0, 0, array[usb_config_descriptor, 1]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_device_descriptor_t[0, 0, 0, 0, 0, 0, array[usb_config_descriptor, 1]]", IsVarlen: true}, Fields: []Type{
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 18},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 1},
- &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "bcdUSB", TypeSize: 2}}},
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_versions", FldName: "bcdUSB", TypeSize: 2}}, Vals: []uint64{272, 512, 513, 592, 768, 784}},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDeviceClass", TypeSize: 1}}},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDeviceSubClass", TypeSize: 1}}},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDeviceProtocol", TypeSize: 1}}},
- &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bMaxPacketSize0", TypeSize: 1}}},
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_max_packet_sizes", FldName: "bMaxPacketSize0", TypeSize: 1}}, Vals: []uint64{8, 16, 32, 64}, BitMask: true},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "idVendor", TypeSize: 2}}},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "idProduct", TypeSize: 2}}},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bcdDevice", TypeSize: 2}}},
@@ -25810,13 +25828,44 @@ var structDescs_amd64 = []*KeyedStruct{
&LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "bNumConfigurations", TypeSize: 1}}, Path: []string{"configs"}},
&ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "configs", IsVarlen: true}, Type: &StructType{Key: StructKey{Name: "usb_config_descriptor"}}, Kind: 1, RangeBegin: 1, RangeEnd: 1},
}}},
+ {Key: StructKey{Name: "usb_device_descriptor_t[0, 0, 0, 0x46d, 0xc31c, 64, array[usb_config_descriptor_hid, 1]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_device_descriptor_t[0, 0, 0, 0x46d, 0xc31c, 64, array[usb_config_descriptor_hid, 1]]", IsVarlen: true}, Fields: []Type{
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 18},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 1},
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_versions", FldName: "bcdUSB", TypeSize: 2}}, Vals: []uint64{272, 512, 513, 592, 768, 784}},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDeviceClass", TypeSize: 1}}},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDeviceSubClass", TypeSize: 1}}},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDeviceProtocol", TypeSize: 1}}},
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_max_packet_sizes", FldName: "bMaxPacketSize0", TypeSize: 1}}, Vals: []uint64{8, 16, 32, 64}, BitMask: true},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "idVendor", TypeSize: 2}}, Val: 1133},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "idProduct", TypeSize: 2}}, Val: 49948},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bcdDevice", TypeSize: 2}}, Val: 64},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "iManufacturer", TypeSize: 1}}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "iProduct", TypeSize: 1}}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "iSerialNumber", TypeSize: 1}}},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "bNumConfigurations", TypeSize: 1}}, Path: []string{"configs"}},
+ &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "configs", IsVarlen: true}, Type: &StructType{Key: StructKey{Name: "usb_config_descriptor_hid"}}, Kind: 1, RangeBegin: 1, RangeEnd: 1},
+ }}},
{Key: StructKey{Name: "usb_endpoint_descriptor"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_endpoint_descriptor", IsVarlen: true}, Fields: []Type{
- &StructType{Key: StructKey{Name: "usb_endpoint_descriptor_t[array[usb_endpoint_extra_descriptor, 0:2]]"}, FldName: "inner"},
+ &StructType{Key: StructKey{Name: "usb_endpoint_descriptor_t[flags[usb_endpoint_addresses, int8], flags[usb_endpoint_attributes, int8], array[usb_endpoint_extra_descriptor, 0:2]]"}, FldName: "inner"},
+ }}},
+ {Key: StructKey{Name: "usb_endpoint_descriptor_hid"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_endpoint_descriptor_hid", IsVarlen: true}, Fields: []Type{
+ &StructType{Key: StructKey{Name: "usb_endpoint_descriptor_t[const[USB_ENDPOINT_HID_ADDRESS, int8], const[USB_ENDPOINT_HID_ATTRIBUTES, int8], array[usb_endpoint_extra_descriptor, 0:2]]"}, FldName: "inner"},
+ }}},
+ {Key: StructKey{Name: "usb_endpoint_descriptor_t[const[USB_ENDPOINT_HID_ADDRESS, int8], const[USB_ENDPOINT_HID_ATTRIBUTES, int8], array[usb_endpoint_extra_descriptor, 0:2]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_endpoint_descriptor_t[const[USB_ENDPOINT_HID_ADDRESS, int8], const[USB_ENDPOINT_HID_ATTRIBUTES, int8], array[usb_endpoint_extra_descriptor, 0:2]]", IsVarlen: true}, Fields: []Type{
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 7},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 5},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bEndpointAddress", TypeSize: 1}}, Val: 129},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bmAttributes", TypeSize: 1}}, Val: 3},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "wMaxPacketSize", TypeSize: 2}}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bInterval", TypeSize: 1}}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bRefresh", TypeSize: 1}}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bSynchAddress", TypeSize: 1}}},
+ &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "extra", IsVarlen: true}, Type: &UnionType{Key: StructKey{Name: "usb_endpoint_extra_descriptor"}}, Kind: 1, RangeEnd: 2},
}}},
- {Key: StructKey{Name: "usb_endpoint_descriptor_t[array[usb_endpoint_extra_descriptor, 0:2]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_endpoint_descriptor_t[array[usb_endpoint_extra_descriptor, 0:2]]", IsVarlen: true}, Fields: []Type{
+ {Key: StructKey{Name: "usb_endpoint_descriptor_t[flags[usb_endpoint_addresses, int8], flags[usb_endpoint_attributes, int8], array[usb_endpoint_extra_descriptor, 0:2]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_endpoint_descriptor_t[flags[usb_endpoint_addresses, int8], flags[usb_endpoint_attributes, int8], array[usb_endpoint_extra_descriptor, 0:2]]", IsVarlen: true}, Fields: []Type{
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 7},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 5},
- &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bEndpointAddress", TypeSize: 1}}},
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_endpoint_addresses", FldName: "bEndpointAddress", TypeSize: 1}}, Vals: []uint64{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 0, 128}},
&FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_endpoint_attributes", FldName: "bmAttributes", TypeSize: 1}}, Vals: []uint64{0, 1, 2, 3, 0, 16, 0, 4, 8, 12, 0, 16, 16}},
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "wMaxPacketSize", TypeSize: 2}}},
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bInterval", TypeSize: 1}}},
@@ -25875,6 +25924,9 @@ var structDescs_amd64 = []*KeyedStruct{
{Key: StructKey{Name: "usb_interface_descriptor"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_interface_descriptor", IsVarlen: true}, Fields: []Type{
&StructType{Key: StructKey{Name: "usb_interface_descriptor_t[0, 0, 0, array[usb_interface_extra_descriptor, 0:2], array[usb_endpoint_descriptor, 0:16]]"}, FldName: "inner"},
}}},
+ {Key: StructKey{Name: "usb_interface_descriptor_hid"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_interface_descriptor_hid", IsVarlen: true}, Fields: []Type{
+ &StructType{Key: StructKey{Name: "usb_interface_descriptor_t[USB_CLASS_HID, USB_INTERFACE_SUBCLASS_BOOT, USB_INTERFACE_PROTOCOL_KEYBOARD, hid_descriptor_hid, array[usb_endpoint_descriptor_hid, 1]]"}, FldName: "inner"},
+ }}},
{Key: StructKey{Name: "usb_interface_descriptor_t[0, 0, 0, array[usb_interface_extra_descriptor, 0:2], array[usb_endpoint_descriptor, 0:16]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_interface_descriptor_t[0, 0, 0, array[usb_interface_extra_descriptor, 0:2], array[usb_endpoint_descriptor, 0:16]]", IsVarlen: true}, Fields: []Type{
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 9},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 4},
@@ -25888,6 +25940,19 @@ var structDescs_amd64 = []*KeyedStruct{
&ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "extra", IsVarlen: true}, Type: &UnionType{Key: StructKey{Name: "usb_interface_extra_descriptor"}}, Kind: 1, RangeEnd: 2},
&ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "endpoints", IsVarlen: true}, Type: &StructType{Key: StructKey{Name: "usb_endpoint_descriptor"}}, Kind: 1, RangeEnd: 16},
}}},
+ {Key: StructKey{Name: "usb_interface_descriptor_t[USB_CLASS_HID, USB_INTERFACE_SUBCLASS_BOOT, USB_INTERFACE_PROTOCOL_KEYBOARD, hid_descriptor_hid, array[usb_endpoint_descriptor_hid, 1]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_interface_descriptor_t[USB_CLASS_HID, USB_INTERFACE_SUBCLASS_BOOT, USB_INTERFACE_PROTOCOL_KEYBOARD, hid_descriptor_hid, array[usb_endpoint_descriptor_hid, 1]]", IsVarlen: true}, Fields: []Type{
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 9},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 4},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bInterfaceNumber", TypeSize: 1}}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bAlternateSetting", TypeSize: 1}}},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "bNumEndpoints", TypeSize: 1}}, Path: []string{"endpoints"}},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bInterfaceClass", TypeSize: 1}}, Val: 3},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bInterfaceSubClass", TypeSize: 1}}, Val: 1},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bInterfaceProtocol", TypeSize: 1}}, Val: 1},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "iInterface", TypeSize: 1}}},
+ &StructType{Key: StructKey{Name: "hid_descriptor_hid"}, FldName: "extra"},
+ &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "endpoints", IsVarlen: true}, Type: &StructType{Key: StructKey{Name: "usb_endpoint_descriptor_hid"}}, Kind: 1, RangeBegin: 1, RangeEnd: 1},
+ }}},
{Key: StructKey{Name: "usb_interface_extra_descriptor"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_interface_extra_descriptor", IsVarlen: true}, Fields: []Type{
&StructType{Key: StructKey{Name: "usb_generic_descriptor"}, FldName: "generic"},
&StructType{Key: StructKey{Name: "hid_descriptor_hid"}, FldName: "hid_hid"},
@@ -25906,11 +25971,11 @@ var structDescs_amd64 = []*KeyedStruct{
{Key: StructKey{Name: "usb_qualifier_descriptor"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_qualifier_descriptor", TypeSize: 10}, Fields: []Type{
&LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "bLength", TypeSize: 1}}, Path: []string{"parent"}},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 6},
- &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "bcdUSB", TypeSize: 2}}},
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_versions", FldName: "bcdUSB", TypeSize: 2}}, Vals: []uint64{272, 512, 513, 592, 768, 784}},
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bDeviceClass", TypeSize: 1}}},
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bDeviceSubClass", TypeSize: 1}}},
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bDeviceProtocol", TypeSize: 1}}},
- &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bMaxPacketSize0", TypeSize: 1}}},
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_max_packet_sizes", FldName: "bMaxPacketSize0", TypeSize: 1}}, Vals: []uint64{8, 16, 32, 64}, BitMask: true},
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bNumConfigurations", TypeSize: 1}}},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bRESERVED", TypeSize: 1}}},
}}},
@@ -27076,12 +27141,37 @@ var structDescs_amd64 = []*KeyedStruct{
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "hub_hs", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_descriptor_t[USB_TYPE_STANDARD, USB_DT_HUB, usb_hub_descriptor_hs]"}}},
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "hub_ss", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_descriptor_t[USB_TYPE_STANDARD, USB_DT_SS_HUB, usb_hub_descriptor_ss]"}}},
}}},
+ {Key: StructKey{Name: "vusb_descriptors_hid"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "vusb_descriptors_hid", TypeSize: 36}, Fields: []Type{
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "len", TypeSize: 4}}, Path: []string{"parent"}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "generic", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_descriptor_generic"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "string", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_descriptor_t[USB_TYPE_STANDARD, USB_DT_STRING, usb_string_descriptor]"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "hid_report", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_descriptor_t[USB_TYPE_STANDARD, HID_DT_REPORT, hid_descriptor_report]"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "bos", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_descriptor_t[USB_TYPE_STANDARD, USB_DT_BOS, usb_bos_descriptor]"}}},
+ }}},
{Key: StructKey{Name: "vusb_response_generic"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "vusb_response_generic", IsVarlen: true}, Fields: []Type{
&FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_request_types", FldName: "type", TypeSize: 1}}, Vals: []uint64{0, 32, 64}, BitMask: true},
&FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_requests", FldName: "req", TypeSize: 1}}, Vals: []uint64{0, 1, 3, 5, 6, 7, 8, 9, 10, 11, 12, 48, 49, 13, 14, 14, 15, 15, 16, 17, 18, 19, 20, 21, 22, 23, 20, 21, 22, 23, 24}},
&LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize", FldName: "len", TypeSize: 4}}, BitSize: 8, Path: []string{"data"}},
&BufferType{TypeCommon: TypeCommon{TypeName: "array", FldName: "data", IsVarlen: true}},
}}},
+ {Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_IDLE, void]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_IDLE, void]", TypeSize: 6}, Fields: []Type{
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "type", TypeSize: 1}}, Val: 32},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "req", TypeSize: 1}}, Val: 10},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize", FldName: "len", TypeSize: 4}}, BitSize: 8, Path: []string{"data"}},
+ &BufferType{TypeCommon: TypeCommon{TypeName: "void", FldName: "data"}, Kind: 1},
+ }}},
+ {Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_PROTOCOL, void]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_PROTOCOL, void]", TypeSize: 6}, Fields: []Type{
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "type", TypeSize: 1}}, Val: 32},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "req", TypeSize: 1}}, Val: 11},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize", FldName: "len", TypeSize: 4}}, BitSize: 8, Path: []string{"data"}},
+ &BufferType{TypeCommon: TypeCommon{TypeName: "void", FldName: "data"}, Kind: 1},
+ }}},
+ {Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_REPORT, void]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_REPORT, void]", TypeSize: 6}, Fields: []Type{
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "type", TypeSize: 1}}, Val: 32},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "req", TypeSize: 1}}, Val: 9},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize", FldName: "len", TypeSize: 4}}, BitSize: 8, Path: []string{"data"}},
+ &BufferType{TypeCommon: TypeCommon{TypeName: "void", FldName: "data"}, Kind: 1},
+ }}},
{Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, USB_CDC_GET_NTB_PARAMETERS, usb_cdc_ncm_ntb_parameters]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "vusb_response_t[USB_TYPE_CLASS, USB_CDC_GET_NTB_PARAMETERS, usb_cdc_ncm_ntb_parameters]", TypeSize: 34}, Fields: []Type{
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "type", TypeSize: 1}}, Val: 32},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "req", TypeSize: 1}}, Val: 128},
@@ -27149,6 +27239,13 @@ var structDescs_amd64 = []*KeyedStruct{
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "aiptek_set_report", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_response_t[USB_TYPE_VENDOR, 0x9, array[int8, 3]]"}}},
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "cdc_get_ntb_parameters", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, USB_CDC_GET_NTB_PARAMETERS, usb_cdc_ncm_ntb_parameters]"}}},
}}},
+ {Key: StructKey{Name: "vusb_responses_hid"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "vusb_responses_hid", TypeSize: 36}, Fields: []Type{
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "len", TypeSize: 4}}, Path: []string{"parent"}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "generic", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_response_generic"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "set_idle", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_IDLE, void]"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "set_report", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_REPORT, void]"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "set_protocol", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_PROTOCOL, void]"}}},
+ }}},
{Key: StructKey{Name: "winsize"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "winsize", TypeSize: 8}, Fields: []Type{
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "row", TypeSize: 2}}},
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "col", TypeSize: 2}}},
@@ -43285,11 +43382,22 @@ var syscalls_amd64 = []*Syscall{
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "dev", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "usb_device_descriptor"}}},
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "conn_descs", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_connect_descriptors"}}},
}, Ret: &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_usb", FldName: "ret", TypeSize: 4, ArgDir: 1}}},
+ {Name: "syz_usb_connect$hid", CallName: "syz_usb_connect", Args: []Type{
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_device_speed", FldName: "speed", TypeSize: 8}}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6}},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "dev_len", TypeSize: 8}}, Path: []string{"dev"}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "dev", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "usb_device_descriptor_hid"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "conn_descs", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_connect_descriptors"}}},
+ }, Ret: &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_usb_hid", FldName: "ret", TypeSize: 4, ArgDir: 1}}},
{Name: "syz_usb_control_io", CallName: "syz_usb_control_io", Args: []Type{
&ResourceType{TypeCommon: TypeCommon{TypeName: "fd_usb", FldName: "fd", TypeSize: 4}},
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "descs", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_descriptors"}}},
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "resps", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_responses"}}},
}},
+ {Name: "syz_usb_control_io$hid", CallName: "syz_usb_control_io", Args: []Type{
+ &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_usb_hid", FldName: "fd", TypeSize: 4}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "descs", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_descriptors_hid"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "resps", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_responses_hid"}}},
+ }},
{Name: "syz_usb_disconnect", CallName: "syz_usb_disconnect", Args: []Type{
&ResourceType{TypeCommon: TypeCommon{TypeName: "fd_usb", FldName: "fd", TypeSize: 4}},
}},
@@ -45954,6 +46062,9 @@ var consts_amd64 = []ConstValue{
{Name: "HID_REPORT_ID_UNKNOWN", Value: 4294967295},
{Name: "HID_REPORT_TYPE_MAX", Value: 3},
{Name: "HID_REPORT_TYPE_MIN", Value: 1},
+ {Name: "HID_REQ_SET_IDLE", Value: 10},
+ {Name: "HID_REQ_SET_PROTOCOL", Value: 11},
+ {Name: "HID_REQ_SET_REPORT", Value: 9},
{Name: "HUB_CHANGE_LOCAL_POWER", Value: 1},
{Name: "HUB_CHANGE_OVERCURRENT", Value: 2},
{Name: "HUB_CHAR_COMMON_LPSM"},
@@ -50250,10 +50361,14 @@ var consts_amd64 = []ConstValue{
{Name: "USB_CDC_OBEX_TYPE", Value: 21},
{Name: "USB_CDC_UNION_TYPE", Value: 6},
{Name: "USB_CDC_WHCM_TYPE", Value: 17},
+ {Name: "USB_CLASS_HID", Value: 3},
{Name: "USB_CONFIG_ATT_BATTERY", Value: 16},
{Name: "USB_CONFIG_ATT_ONE", Value: 128},
{Name: "USB_CONFIG_ATT_SELFPOWER", Value: 64},
{Name: "USB_CONFIG_ATT_WAKEUP", Value: 32},
+ {Name: "USB_CONFIG_HID_ATTRIBUTES", Value: 160},
+ {Name: "USB_DIR_IN", Value: 128},
+ {Name: "USB_DIR_OUT"},
{Name: "USB_DT_BOS", Value: 15},
{Name: "USB_DT_BOS_SIZE", Value: 5},
{Name: "USB_DT_CONFIG", Value: 2},
@@ -50285,6 +50400,8 @@ var consts_amd64 = []ConstValue{
{Name: "USB_DT_STRING", Value: 3},
{Name: "USB_DT_WIRELESS_ENDPOINT_COMP", Value: 17},
{Name: "USB_DT_WIRE_ADAPTER", Value: 33},
+ {Name: "USB_ENDPOINT_HID_ADDRESS", Value: 129},
+ {Name: "USB_ENDPOINT_HID_ATTRIBUTES", Value: 3},
{Name: "USB_ENDPOINT_INTR_NOTIFICATION", Value: 16},
{Name: "USB_ENDPOINT_INTR_PERIODIC"},
{Name: "USB_ENDPOINT_SYNC_ADAPTIVE", Value: 8},
@@ -50304,6 +50421,8 @@ var consts_amd64 = []ConstValue{
{Name: "USB_FULL_SPEED_OPERATION", Value: 2},
{Name: "USB_HIGH_SPEED_OPERATION", Value: 4},
{Name: "USB_HUB_PORTS_BITS", Value: 4},
+ {Name: "USB_INTERFACE_PROTOCOL_KEYBOARD", Value: 1},
+ {Name: "USB_INTERFACE_SUBCLASS_BOOT", Value: 1},
{Name: "USB_LOW_SPEED_OPERATION", Value: 1},
{Name: "USB_LPM_SUPPORT", Value: 2},
{Name: "USB_LTM_SUPPORT", Value: 2},
@@ -52118,4 +52237,4 @@ var consts_amd64 = []ConstValue{
{Name: "bpf_insn_load_imm_dw", Value: 24},
}
-const revision_amd64 = "32c55c0554c149bf56c310af8ec399333e20e0d2"
+const revision_amd64 = "ad6a79d9cc414f25b8b695e36fdefd7e3fb855e3"
diff --git a/sys/linux/gen/arm.go b/sys/linux/gen/arm.go
index 0f5469ea4..4025a8646 100644
--- a/sys/linux/gen/arm.go
+++ b/sys/linux/gen/arm.go
@@ -112,6 +112,7 @@ var resources_arm = []*ResourceDesc{
{Name: "fd_uhid", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd", "fd_uhid"}, Values: []uint64{18446744073709551615, 18446744073709551516}},
{Name: "fd_uinput", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd", "fd_uinput"}, Values: []uint64{18446744073709551615, 18446744073709551516}},
{Name: "fd_usb", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd_usb"}, Values: []uint64{18446744073709551615}},
+ {Name: "fd_usb_hid", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd_usb", "fd_usb_hid"}, Values: []uint64{18446744073709551615}},
{Name: "fd_userio", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd", "fd_userio"}, Values: []uint64{18446744073709551615, 18446744073709551516}},
{Name: "fd_v4l2_buffer", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd", "fd_v4l2_buffer"}, Values: []uint64{18446744073709551615, 18446744073709551516}},
{Name: "fd_vhci", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd", "fd_vhci"}, Values: []uint64{18446744073709551615, 18446744073709551516}},
@@ -25219,9 +25220,23 @@ var structDescs_arm = []*KeyedStruct{
&BufferType{TypeCommon: TypeCommon{TypeName: "array", FldName: "slave_interfaces", IsVarlen: true}, Kind: 1, RangeEnd: 6},
}}},
{Key: StructKey{Name: "usb_config_descriptor"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_config_descriptor", IsVarlen: true}, Fields: []Type{
- &StructType{Key: StructKey{Name: "usb_config_descriptor_t[array[usb_interface_descriptor, 1]]"}, FldName: "inner"},
+ &StructType{Key: StructKey{Name: "usb_config_descriptor_t[flags[usb_config_attributes, int8], array[usb_interface_descriptor, 1]]"}, FldName: "inner"},
}}},
- {Key: StructKey{Name: "usb_config_descriptor_t[array[usb_interface_descriptor, 1]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_config_descriptor_t[array[usb_interface_descriptor, 1]]", IsVarlen: true}, Fields: []Type{
+ {Key: StructKey{Name: "usb_config_descriptor_hid"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_config_descriptor_hid", IsVarlen: true}, Fields: []Type{
+ &StructType{Key: StructKey{Name: "usb_config_descriptor_t[const[USB_CONFIG_HID_ATTRIBUTES, int8], array[usb_interface_descriptor_hid, 1]]"}, FldName: "inner"},
+ }}},
+ {Key: StructKey{Name: "usb_config_descriptor_t[const[USB_CONFIG_HID_ATTRIBUTES, int8], array[usb_interface_descriptor_hid, 1]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_config_descriptor_t[const[USB_CONFIG_HID_ATTRIBUTES, int8], array[usb_interface_descriptor_hid, 1]]", IsVarlen: true}, Fields: []Type{
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 9},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 2},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "wTotalLength", TypeSize: 2}}, Path: []string{"parent"}},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "bNumInterfaces", TypeSize: 1}}, Path: []string{"interfaces"}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bConfigurationValue", TypeSize: 1}}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "iConfiguration", TypeSize: 1}}},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bmAttributes", TypeSize: 1}}, Val: 160},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bMaxPower", TypeSize: 1}}},
+ &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "interfaces", IsVarlen: true}, Type: &StructType{Key: StructKey{Name: "usb_interface_descriptor_hid"}}, Kind: 1, RangeBegin: 1, RangeEnd: 1},
+ }}},
+ {Key: StructKey{Name: "usb_config_descriptor_t[flags[usb_config_attributes, int8], array[usb_interface_descriptor, 1]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_config_descriptor_t[flags[usb_config_attributes, int8], array[usb_interface_descriptor, 1]]", IsVarlen: true}, Fields: []Type{
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 9},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 2},
&LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "wTotalLength", TypeSize: 2}}, Path: []string{"parent"}},
@@ -25244,14 +25259,17 @@ var structDescs_arm = []*KeyedStruct{
{Key: StructKey{Name: "usb_device_descriptor"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_device_descriptor", IsVarlen: true}, Fields: []Type{
&StructType{Key: StructKey{Name: "usb_device_descriptor_t[0, 0, 0, 0, 0, 0, array[usb_config_descriptor, 1]]"}, FldName: "inner"},
}}},
+ {Key: StructKey{Name: "usb_device_descriptor_hid"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_device_descriptor_hid", IsVarlen: true}, Fields: []Type{
+ &StructType{Key: StructKey{Name: "usb_device_descriptor_t[0, 0, 0, 0x46d, 0xc31c, 64, array[usb_config_descriptor_hid, 1]]"}, FldName: "inner"},
+ }}},
{Key: StructKey{Name: "usb_device_descriptor_t[0, 0, 0, 0, 0, 0, array[usb_config_descriptor, 1]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_device_descriptor_t[0, 0, 0, 0, 0, 0, array[usb_config_descriptor, 1]]", IsVarlen: true}, Fields: []Type{
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 18},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 1},
- &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "bcdUSB", TypeSize: 2}}},
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_versions", FldName: "bcdUSB", TypeSize: 2}}, Vals: []uint64{272, 512, 513, 592, 768, 784}},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDeviceClass", TypeSize: 1}}},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDeviceSubClass", TypeSize: 1}}},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDeviceProtocol", TypeSize: 1}}},
- &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bMaxPacketSize0", TypeSize: 1}}},
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_max_packet_sizes", FldName: "bMaxPacketSize0", TypeSize: 1}}, Vals: []uint64{8, 16, 32, 64}, BitMask: true},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "idVendor", TypeSize: 2}}},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "idProduct", TypeSize: 2}}},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bcdDevice", TypeSize: 2}}},
@@ -25261,13 +25279,44 @@ var structDescs_arm = []*KeyedStruct{
&LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "bNumConfigurations", TypeSize: 1}}, Path: []string{"configs"}},
&ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "configs", IsVarlen: true}, Type: &StructType{Key: StructKey{Name: "usb_config_descriptor"}}, Kind: 1, RangeBegin: 1, RangeEnd: 1},
}}},
+ {Key: StructKey{Name: "usb_device_descriptor_t[0, 0, 0, 0x46d, 0xc31c, 64, array[usb_config_descriptor_hid, 1]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_device_descriptor_t[0, 0, 0, 0x46d, 0xc31c, 64, array[usb_config_descriptor_hid, 1]]", IsVarlen: true}, Fields: []Type{
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 18},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 1},
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_versions", FldName: "bcdUSB", TypeSize: 2}}, Vals: []uint64{272, 512, 513, 592, 768, 784}},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDeviceClass", TypeSize: 1}}},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDeviceSubClass", TypeSize: 1}}},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDeviceProtocol", TypeSize: 1}}},
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_max_packet_sizes", FldName: "bMaxPacketSize0", TypeSize: 1}}, Vals: []uint64{8, 16, 32, 64}, BitMask: true},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "idVendor", TypeSize: 2}}, Val: 1133},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "idProduct", TypeSize: 2}}, Val: 49948},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bcdDevice", TypeSize: 2}}, Val: 64},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "iManufacturer", TypeSize: 1}}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "iProduct", TypeSize: 1}}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "iSerialNumber", TypeSize: 1}}},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "bNumConfigurations", TypeSize: 1}}, Path: []string{"configs"}},
+ &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "configs", IsVarlen: true}, Type: &StructType{Key: StructKey{Name: "usb_config_descriptor_hid"}}, Kind: 1, RangeBegin: 1, RangeEnd: 1},
+ }}},
{Key: StructKey{Name: "usb_endpoint_descriptor"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_endpoint_descriptor", IsVarlen: true}, Fields: []Type{
- &StructType{Key: StructKey{Name: "usb_endpoint_descriptor_t[array[usb_endpoint_extra_descriptor, 0:2]]"}, FldName: "inner"},
+ &StructType{Key: StructKey{Name: "usb_endpoint_descriptor_t[flags[usb_endpoint_addresses, int8], flags[usb_endpoint_attributes, int8], array[usb_endpoint_extra_descriptor, 0:2]]"}, FldName: "inner"},
+ }}},
+ {Key: StructKey{Name: "usb_endpoint_descriptor_hid"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_endpoint_descriptor_hid", IsVarlen: true}, Fields: []Type{
+ &StructType{Key: StructKey{Name: "usb_endpoint_descriptor_t[const[USB_ENDPOINT_HID_ADDRESS, int8], const[USB_ENDPOINT_HID_ATTRIBUTES, int8], array[usb_endpoint_extra_descriptor, 0:2]]"}, FldName: "inner"},
+ }}},
+ {Key: StructKey{Name: "usb_endpoint_descriptor_t[const[USB_ENDPOINT_HID_ADDRESS, int8], const[USB_ENDPOINT_HID_ATTRIBUTES, int8], array[usb_endpoint_extra_descriptor, 0:2]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_endpoint_descriptor_t[const[USB_ENDPOINT_HID_ADDRESS, int8], const[USB_ENDPOINT_HID_ATTRIBUTES, int8], array[usb_endpoint_extra_descriptor, 0:2]]", IsVarlen: true}, Fields: []Type{
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 7},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 5},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bEndpointAddress", TypeSize: 1}}, Val: 129},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bmAttributes", TypeSize: 1}}, Val: 3},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "wMaxPacketSize", TypeSize: 2}}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bInterval", TypeSize: 1}}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bRefresh", TypeSize: 1}}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bSynchAddress", TypeSize: 1}}},
+ &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "extra", IsVarlen: true}, Type: &UnionType{Key: StructKey{Name: "usb_endpoint_extra_descriptor"}}, Kind: 1, RangeEnd: 2},
}}},
- {Key: StructKey{Name: "usb_endpoint_descriptor_t[array[usb_endpoint_extra_descriptor, 0:2]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_endpoint_descriptor_t[array[usb_endpoint_extra_descriptor, 0:2]]", IsVarlen: true}, Fields: []Type{
+ {Key: StructKey{Name: "usb_endpoint_descriptor_t[flags[usb_endpoint_addresses, int8], flags[usb_endpoint_attributes, int8], array[usb_endpoint_extra_descriptor, 0:2]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_endpoint_descriptor_t[flags[usb_endpoint_addresses, int8], flags[usb_endpoint_attributes, int8], array[usb_endpoint_extra_descriptor, 0:2]]", IsVarlen: true}, Fields: []Type{
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 7},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 5},
- &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bEndpointAddress", TypeSize: 1}}},
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_endpoint_addresses", FldName: "bEndpointAddress", TypeSize: 1}}, Vals: []uint64{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 0, 128}},
&FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_endpoint_attributes", FldName: "bmAttributes", TypeSize: 1}}, Vals: []uint64{0, 1, 2, 3, 0, 16, 0, 4, 8, 12, 0, 16, 16}},
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "wMaxPacketSize", TypeSize: 2}}},
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bInterval", TypeSize: 1}}},
@@ -25326,6 +25375,9 @@ var structDescs_arm = []*KeyedStruct{
{Key: StructKey{Name: "usb_interface_descriptor"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_interface_descriptor", IsVarlen: true}, Fields: []Type{
&StructType{Key: StructKey{Name: "usb_interface_descriptor_t[0, 0, 0, array[usb_interface_extra_descriptor, 0:2], array[usb_endpoint_descriptor, 0:16]]"}, FldName: "inner"},
}}},
+ {Key: StructKey{Name: "usb_interface_descriptor_hid"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_interface_descriptor_hid", IsVarlen: true}, Fields: []Type{
+ &StructType{Key: StructKey{Name: "usb_interface_descriptor_t[USB_CLASS_HID, USB_INTERFACE_SUBCLASS_BOOT, USB_INTERFACE_PROTOCOL_KEYBOARD, hid_descriptor_hid, array[usb_endpoint_descriptor_hid, 1]]"}, FldName: "inner"},
+ }}},
{Key: StructKey{Name: "usb_interface_descriptor_t[0, 0, 0, array[usb_interface_extra_descriptor, 0:2], array[usb_endpoint_descriptor, 0:16]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_interface_descriptor_t[0, 0, 0, array[usb_interface_extra_descriptor, 0:2], array[usb_endpoint_descriptor, 0:16]]", IsVarlen: true}, Fields: []Type{
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 9},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 4},
@@ -25339,6 +25391,19 @@ var structDescs_arm = []*KeyedStruct{
&ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "extra", IsVarlen: true}, Type: &UnionType{Key: StructKey{Name: "usb_interface_extra_descriptor"}}, Kind: 1, RangeEnd: 2},
&ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "endpoints", IsVarlen: true}, Type: &StructType{Key: StructKey{Name: "usb_endpoint_descriptor"}}, Kind: 1, RangeEnd: 16},
}}},
+ {Key: StructKey{Name: "usb_interface_descriptor_t[USB_CLASS_HID, USB_INTERFACE_SUBCLASS_BOOT, USB_INTERFACE_PROTOCOL_KEYBOARD, hid_descriptor_hid, array[usb_endpoint_descriptor_hid, 1]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_interface_descriptor_t[USB_CLASS_HID, USB_INTERFACE_SUBCLASS_BOOT, USB_INTERFACE_PROTOCOL_KEYBOARD, hid_descriptor_hid, array[usb_endpoint_descriptor_hid, 1]]", IsVarlen: true}, Fields: []Type{
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 9},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 4},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bInterfaceNumber", TypeSize: 1}}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bAlternateSetting", TypeSize: 1}}},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "bNumEndpoints", TypeSize: 1}}, Path: []string{"endpoints"}},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bInterfaceClass", TypeSize: 1}}, Val: 3},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bInterfaceSubClass", TypeSize: 1}}, Val: 1},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bInterfaceProtocol", TypeSize: 1}}, Val: 1},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "iInterface", TypeSize: 1}}},
+ &StructType{Key: StructKey{Name: "hid_descriptor_hid"}, FldName: "extra"},
+ &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "endpoints", IsVarlen: true}, Type: &StructType{Key: StructKey{Name: "usb_endpoint_descriptor_hid"}}, Kind: 1, RangeBegin: 1, RangeEnd: 1},
+ }}},
{Key: StructKey{Name: "usb_interface_extra_descriptor"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_interface_extra_descriptor", IsVarlen: true}, Fields: []Type{
&StructType{Key: StructKey{Name: "usb_generic_descriptor"}, FldName: "generic"},
&StructType{Key: StructKey{Name: "hid_descriptor_hid"}, FldName: "hid_hid"},
@@ -25357,11 +25422,11 @@ var structDescs_arm = []*KeyedStruct{
{Key: StructKey{Name: "usb_qualifier_descriptor"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_qualifier_descriptor", TypeSize: 10}, Fields: []Type{
&LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "bLength", TypeSize: 1}}, Path: []string{"parent"}},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 6},
- &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "bcdUSB", TypeSize: 2}}},
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_versions", FldName: "bcdUSB", TypeSize: 2}}, Vals: []uint64{272, 512, 513, 592, 768, 784}},
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bDeviceClass", TypeSize: 1}}},
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bDeviceSubClass", TypeSize: 1}}},
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bDeviceProtocol", TypeSize: 1}}},
- &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bMaxPacketSize0", TypeSize: 1}}},
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_max_packet_sizes", FldName: "bMaxPacketSize0", TypeSize: 1}}, Vals: []uint64{8, 16, 32, 64}, BitMask: true},
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bNumConfigurations", TypeSize: 1}}},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bRESERVED", TypeSize: 1}}},
}}},
@@ -26504,12 +26569,37 @@ var structDescs_arm = []*KeyedStruct{
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "hub_hs", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "vusb_descriptor_t[USB_TYPE_STANDARD, USB_DT_HUB, usb_hub_descriptor_hs]"}}},
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "hub_ss", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "vusb_descriptor_t[USB_TYPE_STANDARD, USB_DT_SS_HUB, usb_hub_descriptor_ss]"}}},
}}},
+ {Key: StructKey{Name: "vusb_descriptors_hid"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "vusb_descriptors_hid", TypeSize: 20}, Fields: []Type{
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "len", TypeSize: 4}}, Path: []string{"parent"}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "generic", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "vusb_descriptor_generic"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "string", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "vusb_descriptor_t[USB_TYPE_STANDARD, USB_DT_STRING, usb_string_descriptor]"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "hid_report", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "vusb_descriptor_t[USB_TYPE_STANDARD, HID_DT_REPORT, hid_descriptor_report]"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "bos", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "vusb_descriptor_t[USB_TYPE_STANDARD, USB_DT_BOS, usb_bos_descriptor]"}}},
+ }}},
{Key: StructKey{Name: "vusb_response_generic"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "vusb_response_generic", IsVarlen: true}, Fields: []Type{
&FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_request_types", FldName: "type", TypeSize: 1}}, Vals: []uint64{0, 32, 64}, BitMask: true},
&FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_requests", FldName: "req", TypeSize: 1}}, Vals: []uint64{0, 1, 3, 5, 6, 7, 8, 9, 10, 11, 12, 48, 49, 13, 14, 14, 15, 15, 16, 17, 18, 19, 20, 21, 22, 23, 20, 21, 22, 23, 24}},
&LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize", FldName: "len", TypeSize: 4}}, BitSize: 8, Path: []string{"data"}},
&BufferType{TypeCommon: TypeCommon{TypeName: "array", FldName: "data", IsVarlen: true}},
}}},
+ {Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_IDLE, void]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_IDLE, void]", TypeSize: 6}, Fields: []Type{
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "type", TypeSize: 1}}, Val: 32},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "req", TypeSize: 1}}, Val: 10},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize", FldName: "len", TypeSize: 4}}, BitSize: 8, Path: []string{"data"}},
+ &BufferType{TypeCommon: TypeCommon{TypeName: "void", FldName: "data"}, Kind: 1},
+ }}},
+ {Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_PROTOCOL, void]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_PROTOCOL, void]", TypeSize: 6}, Fields: []Type{
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "type", TypeSize: 1}}, Val: 32},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "req", TypeSize: 1}}, Val: 11},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize", FldName: "len", TypeSize: 4}}, BitSize: 8, Path: []string{"data"}},
+ &BufferType{TypeCommon: TypeCommon{TypeName: "void", FldName: "data"}, Kind: 1},
+ }}},
+ {Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_REPORT, void]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_REPORT, void]", TypeSize: 6}, Fields: []Type{
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "type", TypeSize: 1}}, Val: 32},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "req", TypeSize: 1}}, Val: 9},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize", FldName: "len", TypeSize: 4}}, BitSize: 8, Path: []string{"data"}},
+ &BufferType{TypeCommon: TypeCommon{TypeName: "void", FldName: "data"}, Kind: 1},
+ }}},
{Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, USB_CDC_GET_NTB_PARAMETERS, usb_cdc_ncm_ntb_parameters]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "vusb_response_t[USB_TYPE_CLASS, USB_CDC_GET_NTB_PARAMETERS, usb_cdc_ncm_ntb_parameters]", TypeSize: 34}, Fields: []Type{
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "type", TypeSize: 1}}, Val: 32},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "req", TypeSize: 1}}, Val: 128},
@@ -26577,6 +26667,13 @@ var structDescs_arm = []*KeyedStruct{
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "aiptek_set_report", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "vusb_response_t[USB_TYPE_VENDOR, 0x9, array[int8, 3]]"}}},
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "cdc_get_ntb_parameters", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, USB_CDC_GET_NTB_PARAMETERS, usb_cdc_ncm_ntb_parameters]"}}},
}}},
+ {Key: StructKey{Name: "vusb_responses_hid"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "vusb_responses_hid", TypeSize: 20}, Fields: []Type{
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "len", TypeSize: 4}}, Path: []string{"parent"}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "generic", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "vusb_response_generic"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "set_idle", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_IDLE, void]"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "set_report", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_REPORT, void]"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "set_protocol", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_PROTOCOL, void]"}}},
+ }}},
{Key: StructKey{Name: "winsize"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "winsize", TypeSize: 8}, Fields: []Type{
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "row", TypeSize: 2}}},
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "col", TypeSize: 2}}},
@@ -42419,11 +42516,22 @@ var syscalls_arm = []*Syscall{
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "dev", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "usb_device_descriptor"}}},
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "conn_descs", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "vusb_connect_descriptors"}}},
}, Ret: &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_usb", FldName: "ret", TypeSize: 4, ArgDir: 1}}},
+ {Name: "syz_usb_connect$hid", CallName: "syz_usb_connect", Args: []Type{
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_device_speed", FldName: "speed", TypeSize: 4}}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6}},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "dev_len", TypeSize: 4}}, Path: []string{"dev"}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "dev", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "usb_device_descriptor_hid"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "conn_descs", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "vusb_connect_descriptors"}}},
+ }, Ret: &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_usb_hid", FldName: "ret", TypeSize: 4, ArgDir: 1}}},
{Name: "syz_usb_control_io", CallName: "syz_usb_control_io", Args: []Type{
&ResourceType{TypeCommon: TypeCommon{TypeName: "fd_usb", FldName: "fd", TypeSize: 4}},
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "descs", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "vusb_descriptors"}}},
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "resps", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "vusb_responses"}}},
}},
+ {Name: "syz_usb_control_io$hid", CallName: "syz_usb_control_io", Args: []Type{
+ &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_usb_hid", FldName: "fd", TypeSize: 4}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "descs", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "vusb_descriptors_hid"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "resps", TypeSize: 4}, Type: &StructType{Key: StructKey{Name: "vusb_responses_hid"}}},
+ }},
{Name: "syz_usb_disconnect", CallName: "syz_usb_disconnect", Args: []Type{
&ResourceType{TypeCommon: TypeCommon{TypeName: "fd_usb", FldName: "fd", TypeSize: 4}},
}},
@@ -45072,6 +45180,9 @@ var consts_arm = []ConstValue{
{Name: "HID_REPORT_ID_UNKNOWN", Value: 4294967295},
{Name: "HID_REPORT_TYPE_MAX", Value: 3},
{Name: "HID_REPORT_TYPE_MIN", Value: 1},
+ {Name: "HID_REQ_SET_IDLE", Value: 10},
+ {Name: "HID_REQ_SET_PROTOCOL", Value: 11},
+ {Name: "HID_REQ_SET_REPORT", Value: 9},
{Name: "HUB_CHANGE_LOCAL_POWER", Value: 1},
{Name: "HUB_CHANGE_OVERCURRENT", Value: 2},
{Name: "HUB_CHAR_COMMON_LPSM"},
@@ -49301,10 +49412,14 @@ var consts_arm = []ConstValue{
{Name: "USB_CDC_OBEX_TYPE", Value: 21},
{Name: "USB_CDC_UNION_TYPE", Value: 6},
{Name: "USB_CDC_WHCM_TYPE", Value: 17},
+ {Name: "USB_CLASS_HID", Value: 3},
{Name: "USB_CONFIG_ATT_BATTERY", Value: 16},
{Name: "USB_CONFIG_ATT_ONE", Value: 128},
{Name: "USB_CONFIG_ATT_SELFPOWER", Value: 64},
{Name: "USB_CONFIG_ATT_WAKEUP", Value: 32},
+ {Name: "USB_CONFIG_HID_ATTRIBUTES", Value: 160},
+ {Name: "USB_DIR_IN", Value: 128},
+ {Name: "USB_DIR_OUT"},
{Name: "USB_DT_BOS", Value: 15},
{Name: "USB_DT_BOS_SIZE", Value: 5},
{Name: "USB_DT_CONFIG", Value: 2},
@@ -49336,6 +49451,8 @@ var consts_arm = []ConstValue{
{Name: "USB_DT_STRING", Value: 3},
{Name: "USB_DT_WIRELESS_ENDPOINT_COMP", Value: 17},
{Name: "USB_DT_WIRE_ADAPTER", Value: 33},
+ {Name: "USB_ENDPOINT_HID_ADDRESS", Value: 129},
+ {Name: "USB_ENDPOINT_HID_ATTRIBUTES", Value: 3},
{Name: "USB_ENDPOINT_INTR_NOTIFICATION", Value: 16},
{Name: "USB_ENDPOINT_INTR_PERIODIC"},
{Name: "USB_ENDPOINT_SYNC_ADAPTIVE", Value: 8},
@@ -49355,6 +49472,8 @@ var consts_arm = []ConstValue{
{Name: "USB_FULL_SPEED_OPERATION", Value: 2},
{Name: "USB_HIGH_SPEED_OPERATION", Value: 4},
{Name: "USB_HUB_PORTS_BITS", Value: 4},
+ {Name: "USB_INTERFACE_PROTOCOL_KEYBOARD", Value: 1},
+ {Name: "USB_INTERFACE_SUBCLASS_BOOT", Value: 1},
{Name: "USB_LOW_SPEED_OPERATION", Value: 1},
{Name: "USB_LPM_SUPPORT", Value: 2},
{Name: "USB_LTM_SUPPORT", Value: 2},
@@ -51158,4 +51277,4 @@ var consts_arm = []ConstValue{
{Name: "bpf_insn_load_imm_dw", Value: 24},
}
-const revision_arm = "300d8749cd787852bb03fd8891c932184670b175"
+const revision_arm = "3c3fb436aa51c107a7fe346fe0e53a7c18779d1c"
diff --git a/sys/linux/gen/arm64.go b/sys/linux/gen/arm64.go
index d35370ab0..a587818ab 100644
--- a/sys/linux/gen/arm64.go
+++ b/sys/linux/gen/arm64.go
@@ -112,6 +112,7 @@ var resources_arm64 = []*ResourceDesc{
{Name: "fd_uhid", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd", "fd_uhid"}, Values: []uint64{18446744073709551615, 18446744073709551516}},
{Name: "fd_uinput", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd", "fd_uinput"}, Values: []uint64{18446744073709551615, 18446744073709551516}},
{Name: "fd_usb", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd_usb"}, Values: []uint64{18446744073709551615}},
+ {Name: "fd_usb_hid", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd_usb", "fd_usb_hid"}, Values: []uint64{18446744073709551615}},
{Name: "fd_userio", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd", "fd_userio"}, Values: []uint64{18446744073709551615, 18446744073709551516}},
{Name: "fd_v4l2_buffer", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd", "fd_v4l2_buffer"}, Values: []uint64{18446744073709551615, 18446744073709551516}},
{Name: "fd_vhci", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd", "fd_vhci"}, Values: []uint64{18446744073709551615, 18446744073709551516}},
@@ -25585,9 +25586,23 @@ var structDescs_arm64 = []*KeyedStruct{
&BufferType{TypeCommon: TypeCommon{TypeName: "array", FldName: "slave_interfaces", IsVarlen: true}, Kind: 1, RangeEnd: 6},
}}},
{Key: StructKey{Name: "usb_config_descriptor"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_config_descriptor", IsVarlen: true}, Fields: []Type{
- &StructType{Key: StructKey{Name: "usb_config_descriptor_t[array[usb_interface_descriptor, 1]]"}, FldName: "inner"},
+ &StructType{Key: StructKey{Name: "usb_config_descriptor_t[flags[usb_config_attributes, int8], array[usb_interface_descriptor, 1]]"}, FldName: "inner"},
}}},
- {Key: StructKey{Name: "usb_config_descriptor_t[array[usb_interface_descriptor, 1]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_config_descriptor_t[array[usb_interface_descriptor, 1]]", IsVarlen: true}, Fields: []Type{
+ {Key: StructKey{Name: "usb_config_descriptor_hid"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_config_descriptor_hid", IsVarlen: true}, Fields: []Type{
+ &StructType{Key: StructKey{Name: "usb_config_descriptor_t[const[USB_CONFIG_HID_ATTRIBUTES, int8], array[usb_interface_descriptor_hid, 1]]"}, FldName: "inner"},
+ }}},
+ {Key: StructKey{Name: "usb_config_descriptor_t[const[USB_CONFIG_HID_ATTRIBUTES, int8], array[usb_interface_descriptor_hid, 1]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_config_descriptor_t[const[USB_CONFIG_HID_ATTRIBUTES, int8], array[usb_interface_descriptor_hid, 1]]", IsVarlen: true}, Fields: []Type{
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 9},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 2},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "wTotalLength", TypeSize: 2}}, Path: []string{"parent"}},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "bNumInterfaces", TypeSize: 1}}, Path: []string{"interfaces"}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bConfigurationValue", TypeSize: 1}}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "iConfiguration", TypeSize: 1}}},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bmAttributes", TypeSize: 1}}, Val: 160},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bMaxPower", TypeSize: 1}}},
+ &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "interfaces", IsVarlen: true}, Type: &StructType{Key: StructKey{Name: "usb_interface_descriptor_hid"}}, Kind: 1, RangeBegin: 1, RangeEnd: 1},
+ }}},
+ {Key: StructKey{Name: "usb_config_descriptor_t[flags[usb_config_attributes, int8], array[usb_interface_descriptor, 1]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_config_descriptor_t[flags[usb_config_attributes, int8], array[usb_interface_descriptor, 1]]", IsVarlen: true}, Fields: []Type{
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 9},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 2},
&LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "wTotalLength", TypeSize: 2}}, Path: []string{"parent"}},
@@ -25610,14 +25625,17 @@ var structDescs_arm64 = []*KeyedStruct{
{Key: StructKey{Name: "usb_device_descriptor"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_device_descriptor", IsVarlen: true}, Fields: []Type{
&StructType{Key: StructKey{Name: "usb_device_descriptor_t[0, 0, 0, 0, 0, 0, array[usb_config_descriptor, 1]]"}, FldName: "inner"},
}}},
+ {Key: StructKey{Name: "usb_device_descriptor_hid"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_device_descriptor_hid", IsVarlen: true}, Fields: []Type{
+ &StructType{Key: StructKey{Name: "usb_device_descriptor_t[0, 0, 0, 0x46d, 0xc31c, 64, array[usb_config_descriptor_hid, 1]]"}, FldName: "inner"},
+ }}},
{Key: StructKey{Name: "usb_device_descriptor_t[0, 0, 0, 0, 0, 0, array[usb_config_descriptor, 1]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_device_descriptor_t[0, 0, 0, 0, 0, 0, array[usb_config_descriptor, 1]]", IsVarlen: true}, Fields: []Type{
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 18},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 1},
- &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "bcdUSB", TypeSize: 2}}},
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_versions", FldName: "bcdUSB", TypeSize: 2}}, Vals: []uint64{272, 512, 513, 592, 768, 784}},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDeviceClass", TypeSize: 1}}},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDeviceSubClass", TypeSize: 1}}},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDeviceProtocol", TypeSize: 1}}},
- &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bMaxPacketSize0", TypeSize: 1}}},
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_max_packet_sizes", FldName: "bMaxPacketSize0", TypeSize: 1}}, Vals: []uint64{8, 16, 32, 64}, BitMask: true},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "idVendor", TypeSize: 2}}},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "idProduct", TypeSize: 2}}},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bcdDevice", TypeSize: 2}}},
@@ -25627,13 +25645,44 @@ var structDescs_arm64 = []*KeyedStruct{
&LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "bNumConfigurations", TypeSize: 1}}, Path: []string{"configs"}},
&ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "configs", IsVarlen: true}, Type: &StructType{Key: StructKey{Name: "usb_config_descriptor"}}, Kind: 1, RangeBegin: 1, RangeEnd: 1},
}}},
+ {Key: StructKey{Name: "usb_device_descriptor_t[0, 0, 0, 0x46d, 0xc31c, 64, array[usb_config_descriptor_hid, 1]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_device_descriptor_t[0, 0, 0, 0x46d, 0xc31c, 64, array[usb_config_descriptor_hid, 1]]", IsVarlen: true}, Fields: []Type{
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 18},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 1},
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_versions", FldName: "bcdUSB", TypeSize: 2}}, Vals: []uint64{272, 512, 513, 592, 768, 784}},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDeviceClass", TypeSize: 1}}},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDeviceSubClass", TypeSize: 1}}},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDeviceProtocol", TypeSize: 1}}},
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_max_packet_sizes", FldName: "bMaxPacketSize0", TypeSize: 1}}, Vals: []uint64{8, 16, 32, 64}, BitMask: true},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "idVendor", TypeSize: 2}}, Val: 1133},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "idProduct", TypeSize: 2}}, Val: 49948},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bcdDevice", TypeSize: 2}}, Val: 64},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "iManufacturer", TypeSize: 1}}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "iProduct", TypeSize: 1}}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "iSerialNumber", TypeSize: 1}}},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "bNumConfigurations", TypeSize: 1}}, Path: []string{"configs"}},
+ &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "configs", IsVarlen: true}, Type: &StructType{Key: StructKey{Name: "usb_config_descriptor_hid"}}, Kind: 1, RangeBegin: 1, RangeEnd: 1},
+ }}},
{Key: StructKey{Name: "usb_endpoint_descriptor"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_endpoint_descriptor", IsVarlen: true}, Fields: []Type{
- &StructType{Key: StructKey{Name: "usb_endpoint_descriptor_t[array[usb_endpoint_extra_descriptor, 0:2]]"}, FldName: "inner"},
+ &StructType{Key: StructKey{Name: "usb_endpoint_descriptor_t[flags[usb_endpoint_addresses, int8], flags[usb_endpoint_attributes, int8], array[usb_endpoint_extra_descriptor, 0:2]]"}, FldName: "inner"},
+ }}},
+ {Key: StructKey{Name: "usb_endpoint_descriptor_hid"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_endpoint_descriptor_hid", IsVarlen: true}, Fields: []Type{
+ &StructType{Key: StructKey{Name: "usb_endpoint_descriptor_t[const[USB_ENDPOINT_HID_ADDRESS, int8], const[USB_ENDPOINT_HID_ATTRIBUTES, int8], array[usb_endpoint_extra_descriptor, 0:2]]"}, FldName: "inner"},
+ }}},
+ {Key: StructKey{Name: "usb_endpoint_descriptor_t[const[USB_ENDPOINT_HID_ADDRESS, int8], const[USB_ENDPOINT_HID_ATTRIBUTES, int8], array[usb_endpoint_extra_descriptor, 0:2]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_endpoint_descriptor_t[const[USB_ENDPOINT_HID_ADDRESS, int8], const[USB_ENDPOINT_HID_ATTRIBUTES, int8], array[usb_endpoint_extra_descriptor, 0:2]]", IsVarlen: true}, Fields: []Type{
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 7},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 5},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bEndpointAddress", TypeSize: 1}}, Val: 129},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bmAttributes", TypeSize: 1}}, Val: 3},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "wMaxPacketSize", TypeSize: 2}}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bInterval", TypeSize: 1}}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bRefresh", TypeSize: 1}}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bSynchAddress", TypeSize: 1}}},
+ &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "extra", IsVarlen: true}, Type: &UnionType{Key: StructKey{Name: "usb_endpoint_extra_descriptor"}}, Kind: 1, RangeEnd: 2},
}}},
- {Key: StructKey{Name: "usb_endpoint_descriptor_t[array[usb_endpoint_extra_descriptor, 0:2]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_endpoint_descriptor_t[array[usb_endpoint_extra_descriptor, 0:2]]", IsVarlen: true}, Fields: []Type{
+ {Key: StructKey{Name: "usb_endpoint_descriptor_t[flags[usb_endpoint_addresses, int8], flags[usb_endpoint_attributes, int8], array[usb_endpoint_extra_descriptor, 0:2]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_endpoint_descriptor_t[flags[usb_endpoint_addresses, int8], flags[usb_endpoint_attributes, int8], array[usb_endpoint_extra_descriptor, 0:2]]", IsVarlen: true}, Fields: []Type{
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 7},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 5},
- &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bEndpointAddress", TypeSize: 1}}},
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_endpoint_addresses", FldName: "bEndpointAddress", TypeSize: 1}}, Vals: []uint64{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 0, 128}},
&FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_endpoint_attributes", FldName: "bmAttributes", TypeSize: 1}}, Vals: []uint64{0, 1, 2, 3, 0, 16, 0, 4, 8, 12, 0, 16, 16}},
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "wMaxPacketSize", TypeSize: 2}}},
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bInterval", TypeSize: 1}}},
@@ -25692,6 +25741,9 @@ var structDescs_arm64 = []*KeyedStruct{
{Key: StructKey{Name: "usb_interface_descriptor"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_interface_descriptor", IsVarlen: true}, Fields: []Type{
&StructType{Key: StructKey{Name: "usb_interface_descriptor_t[0, 0, 0, array[usb_interface_extra_descriptor, 0:2], array[usb_endpoint_descriptor, 0:16]]"}, FldName: "inner"},
}}},
+ {Key: StructKey{Name: "usb_interface_descriptor_hid"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_interface_descriptor_hid", IsVarlen: true}, Fields: []Type{
+ &StructType{Key: StructKey{Name: "usb_interface_descriptor_t[USB_CLASS_HID, USB_INTERFACE_SUBCLASS_BOOT, USB_INTERFACE_PROTOCOL_KEYBOARD, hid_descriptor_hid, array[usb_endpoint_descriptor_hid, 1]]"}, FldName: "inner"},
+ }}},
{Key: StructKey{Name: "usb_interface_descriptor_t[0, 0, 0, array[usb_interface_extra_descriptor, 0:2], array[usb_endpoint_descriptor, 0:16]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_interface_descriptor_t[0, 0, 0, array[usb_interface_extra_descriptor, 0:2], array[usb_endpoint_descriptor, 0:16]]", IsVarlen: true}, Fields: []Type{
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 9},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 4},
@@ -25705,6 +25757,19 @@ var structDescs_arm64 = []*KeyedStruct{
&ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "extra", IsVarlen: true}, Type: &UnionType{Key: StructKey{Name: "usb_interface_extra_descriptor"}}, Kind: 1, RangeEnd: 2},
&ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "endpoints", IsVarlen: true}, Type: &StructType{Key: StructKey{Name: "usb_endpoint_descriptor"}}, Kind: 1, RangeEnd: 16},
}}},
+ {Key: StructKey{Name: "usb_interface_descriptor_t[USB_CLASS_HID, USB_INTERFACE_SUBCLASS_BOOT, USB_INTERFACE_PROTOCOL_KEYBOARD, hid_descriptor_hid, array[usb_endpoint_descriptor_hid, 1]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_interface_descriptor_t[USB_CLASS_HID, USB_INTERFACE_SUBCLASS_BOOT, USB_INTERFACE_PROTOCOL_KEYBOARD, hid_descriptor_hid, array[usb_endpoint_descriptor_hid, 1]]", IsVarlen: true}, Fields: []Type{
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 9},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 4},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bInterfaceNumber", TypeSize: 1}}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bAlternateSetting", TypeSize: 1}}},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "bNumEndpoints", TypeSize: 1}}, Path: []string{"endpoints"}},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bInterfaceClass", TypeSize: 1}}, Val: 3},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bInterfaceSubClass", TypeSize: 1}}, Val: 1},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bInterfaceProtocol", TypeSize: 1}}, Val: 1},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "iInterface", TypeSize: 1}}},
+ &StructType{Key: StructKey{Name: "hid_descriptor_hid"}, FldName: "extra"},
+ &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "endpoints", IsVarlen: true}, Type: &StructType{Key: StructKey{Name: "usb_endpoint_descriptor_hid"}}, Kind: 1, RangeBegin: 1, RangeEnd: 1},
+ }}},
{Key: StructKey{Name: "usb_interface_extra_descriptor"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_interface_extra_descriptor", IsVarlen: true}, Fields: []Type{
&StructType{Key: StructKey{Name: "usb_generic_descriptor"}, FldName: "generic"},
&StructType{Key: StructKey{Name: "hid_descriptor_hid"}, FldName: "hid_hid"},
@@ -25723,11 +25788,11 @@ var structDescs_arm64 = []*KeyedStruct{
{Key: StructKey{Name: "usb_qualifier_descriptor"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_qualifier_descriptor", TypeSize: 10}, Fields: []Type{
&LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "bLength", TypeSize: 1}}, Path: []string{"parent"}},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 6},
- &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "bcdUSB", TypeSize: 2}}},
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_versions", FldName: "bcdUSB", TypeSize: 2}}, Vals: []uint64{272, 512, 513, 592, 768, 784}},
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bDeviceClass", TypeSize: 1}}},
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bDeviceSubClass", TypeSize: 1}}},
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bDeviceProtocol", TypeSize: 1}}},
- &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bMaxPacketSize0", TypeSize: 1}}},
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_max_packet_sizes", FldName: "bMaxPacketSize0", TypeSize: 1}}, Vals: []uint64{8, 16, 32, 64}, BitMask: true},
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bNumConfigurations", TypeSize: 1}}},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bRESERVED", TypeSize: 1}}},
}}},
@@ -26868,12 +26933,37 @@ var structDescs_arm64 = []*KeyedStruct{
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "hub_hs", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_descriptor_t[USB_TYPE_STANDARD, USB_DT_HUB, usb_hub_descriptor_hs]"}}},
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "hub_ss", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_descriptor_t[USB_TYPE_STANDARD, USB_DT_SS_HUB, usb_hub_descriptor_ss]"}}},
}}},
+ {Key: StructKey{Name: "vusb_descriptors_hid"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "vusb_descriptors_hid", TypeSize: 36}, Fields: []Type{
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "len", TypeSize: 4}}, Path: []string{"parent"}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "generic", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_descriptor_generic"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "string", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_descriptor_t[USB_TYPE_STANDARD, USB_DT_STRING, usb_string_descriptor]"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "hid_report", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_descriptor_t[USB_TYPE_STANDARD, HID_DT_REPORT, hid_descriptor_report]"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "bos", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_descriptor_t[USB_TYPE_STANDARD, USB_DT_BOS, usb_bos_descriptor]"}}},
+ }}},
{Key: StructKey{Name: "vusb_response_generic"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "vusb_response_generic", IsVarlen: true}, Fields: []Type{
&FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_request_types", FldName: "type", TypeSize: 1}}, Vals: []uint64{0, 32, 64}, BitMask: true},
&FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_requests", FldName: "req", TypeSize: 1}}, Vals: []uint64{0, 1, 3, 5, 6, 7, 8, 9, 10, 11, 12, 48, 49, 13, 14, 14, 15, 15, 16, 17, 18, 19, 20, 21, 22, 23, 20, 21, 22, 23, 24}},
&LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize", FldName: "len", TypeSize: 4}}, BitSize: 8, Path: []string{"data"}},
&BufferType{TypeCommon: TypeCommon{TypeName: "array", FldName: "data", IsVarlen: true}},
}}},
+ {Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_IDLE, void]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_IDLE, void]", TypeSize: 6}, Fields: []Type{
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "type", TypeSize: 1}}, Val: 32},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "req", TypeSize: 1}}, Val: 10},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize", FldName: "len", TypeSize: 4}}, BitSize: 8, Path: []string{"data"}},
+ &BufferType{TypeCommon: TypeCommon{TypeName: "void", FldName: "data"}, Kind: 1},
+ }}},
+ {Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_PROTOCOL, void]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_PROTOCOL, void]", TypeSize: 6}, Fields: []Type{
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "type", TypeSize: 1}}, Val: 32},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "req", TypeSize: 1}}, Val: 11},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize", FldName: "len", TypeSize: 4}}, BitSize: 8, Path: []string{"data"}},
+ &BufferType{TypeCommon: TypeCommon{TypeName: "void", FldName: "data"}, Kind: 1},
+ }}},
+ {Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_REPORT, void]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_REPORT, void]", TypeSize: 6}, Fields: []Type{
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "type", TypeSize: 1}}, Val: 32},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "req", TypeSize: 1}}, Val: 9},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize", FldName: "len", TypeSize: 4}}, BitSize: 8, Path: []string{"data"}},
+ &BufferType{TypeCommon: TypeCommon{TypeName: "void", FldName: "data"}, Kind: 1},
+ }}},
{Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, USB_CDC_GET_NTB_PARAMETERS, usb_cdc_ncm_ntb_parameters]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "vusb_response_t[USB_TYPE_CLASS, USB_CDC_GET_NTB_PARAMETERS, usb_cdc_ncm_ntb_parameters]", TypeSize: 34}, Fields: []Type{
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "type", TypeSize: 1}}, Val: 32},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "req", TypeSize: 1}}, Val: 128},
@@ -26941,6 +27031,13 @@ var structDescs_arm64 = []*KeyedStruct{
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "aiptek_set_report", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_response_t[USB_TYPE_VENDOR, 0x9, array[int8, 3]]"}}},
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "cdc_get_ntb_parameters", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, USB_CDC_GET_NTB_PARAMETERS, usb_cdc_ncm_ntb_parameters]"}}},
}}},
+ {Key: StructKey{Name: "vusb_responses_hid"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "vusb_responses_hid", TypeSize: 36}, Fields: []Type{
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "len", TypeSize: 4}}, Path: []string{"parent"}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "generic", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_response_generic"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "set_idle", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_IDLE, void]"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "set_report", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_REPORT, void]"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "set_protocol", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_PROTOCOL, void]"}}},
+ }}},
{Key: StructKey{Name: "winsize"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "winsize", TypeSize: 8}, Fields: []Type{
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "row", TypeSize: 2}}},
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "col", TypeSize: 2}}},
@@ -42761,11 +42858,22 @@ var syscalls_arm64 = []*Syscall{
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "dev", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "usb_device_descriptor"}}},
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "conn_descs", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_connect_descriptors"}}},
}, Ret: &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_usb", FldName: "ret", TypeSize: 4, ArgDir: 1}}},
+ {Name: "syz_usb_connect$hid", CallName: "syz_usb_connect", Args: []Type{
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_device_speed", FldName: "speed", TypeSize: 8}}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6}},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "dev_len", TypeSize: 8}}, Path: []string{"dev"}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "dev", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "usb_device_descriptor_hid"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "conn_descs", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_connect_descriptors"}}},
+ }, Ret: &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_usb_hid", FldName: "ret", TypeSize: 4, ArgDir: 1}}},
{Name: "syz_usb_control_io", CallName: "syz_usb_control_io", Args: []Type{
&ResourceType{TypeCommon: TypeCommon{TypeName: "fd_usb", FldName: "fd", TypeSize: 4}},
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "descs", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_descriptors"}}},
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "resps", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_responses"}}},
}},
+ {Name: "syz_usb_control_io$hid", CallName: "syz_usb_control_io", Args: []Type{
+ &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_usb_hid", FldName: "fd", TypeSize: 4}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "descs", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_descriptors_hid"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "resps", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_responses_hid"}}},
+ }},
{Name: "syz_usb_disconnect", CallName: "syz_usb_disconnect", Args: []Type{
&ResourceType{TypeCommon: TypeCommon{TypeName: "fd_usb", FldName: "fd", TypeSize: 4}},
}},
@@ -45400,6 +45508,9 @@ var consts_arm64 = []ConstValue{
{Name: "HID_REPORT_ID_UNKNOWN", Value: 4294967295},
{Name: "HID_REPORT_TYPE_MAX", Value: 3},
{Name: "HID_REPORT_TYPE_MIN", Value: 1},
+ {Name: "HID_REQ_SET_IDLE", Value: 10},
+ {Name: "HID_REQ_SET_PROTOCOL", Value: 11},
+ {Name: "HID_REQ_SET_REPORT", Value: 9},
{Name: "HUB_CHANGE_LOCAL_POWER", Value: 1},
{Name: "HUB_CHANGE_OVERCURRENT", Value: 2},
{Name: "HUB_CHAR_COMMON_LPSM"},
@@ -49641,10 +49752,14 @@ var consts_arm64 = []ConstValue{
{Name: "USB_CDC_OBEX_TYPE", Value: 21},
{Name: "USB_CDC_UNION_TYPE", Value: 6},
{Name: "USB_CDC_WHCM_TYPE", Value: 17},
+ {Name: "USB_CLASS_HID", Value: 3},
{Name: "USB_CONFIG_ATT_BATTERY", Value: 16},
{Name: "USB_CONFIG_ATT_ONE", Value: 128},
{Name: "USB_CONFIG_ATT_SELFPOWER", Value: 64},
{Name: "USB_CONFIG_ATT_WAKEUP", Value: 32},
+ {Name: "USB_CONFIG_HID_ATTRIBUTES", Value: 160},
+ {Name: "USB_DIR_IN", Value: 128},
+ {Name: "USB_DIR_OUT"},
{Name: "USB_DT_BOS", Value: 15},
{Name: "USB_DT_BOS_SIZE", Value: 5},
{Name: "USB_DT_CONFIG", Value: 2},
@@ -49676,6 +49791,8 @@ var consts_arm64 = []ConstValue{
{Name: "USB_DT_STRING", Value: 3},
{Name: "USB_DT_WIRELESS_ENDPOINT_COMP", Value: 17},
{Name: "USB_DT_WIRE_ADAPTER", Value: 33},
+ {Name: "USB_ENDPOINT_HID_ADDRESS", Value: 129},
+ {Name: "USB_ENDPOINT_HID_ATTRIBUTES", Value: 3},
{Name: "USB_ENDPOINT_INTR_NOTIFICATION", Value: 16},
{Name: "USB_ENDPOINT_INTR_PERIODIC"},
{Name: "USB_ENDPOINT_SYNC_ADAPTIVE", Value: 8},
@@ -49695,6 +49812,8 @@ var consts_arm64 = []ConstValue{
{Name: "USB_FULL_SPEED_OPERATION", Value: 2},
{Name: "USB_HIGH_SPEED_OPERATION", Value: 4},
{Name: "USB_HUB_PORTS_BITS", Value: 4},
+ {Name: "USB_INTERFACE_PROTOCOL_KEYBOARD", Value: 1},
+ {Name: "USB_INTERFACE_SUBCLASS_BOOT", Value: 1},
{Name: "USB_LOW_SPEED_OPERATION", Value: 1},
{Name: "USB_LPM_SUPPORT", Value: 2},
{Name: "USB_LTM_SUPPORT", Value: 2},
@@ -51468,4 +51587,4 @@ var consts_arm64 = []ConstValue{
{Name: "bpf_insn_load_imm_dw", Value: 24},
}
-const revision_arm64 = "9849acfe4ce02bc898a58c5da917118cef487c07"
+const revision_arm64 = "6bb14aa21820407360f010f256bc72e1c84cfd3e"
diff --git a/sys/linux/gen/ppc64le.go b/sys/linux/gen/ppc64le.go
index 2aaf43c52..b678398b0 100644
--- a/sys/linux/gen/ppc64le.go
+++ b/sys/linux/gen/ppc64le.go
@@ -112,6 +112,7 @@ var resources_ppc64le = []*ResourceDesc{
{Name: "fd_uhid", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd", "fd_uhid"}, Values: []uint64{18446744073709551615, 18446744073709551516}},
{Name: "fd_uinput", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd", "fd_uinput"}, Values: []uint64{18446744073709551615, 18446744073709551516}},
{Name: "fd_usb", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd_usb"}, Values: []uint64{18446744073709551615}},
+ {Name: "fd_usb_hid", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd_usb", "fd_usb_hid"}, Values: []uint64{18446744073709551615}},
{Name: "fd_userio", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd", "fd_userio"}, Values: []uint64{18446744073709551615, 18446744073709551516}},
{Name: "fd_v4l2_buffer", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd", "fd_v4l2_buffer"}, Values: []uint64{18446744073709551615, 18446744073709551516}},
{Name: "fd_vhci", Type: &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int32", TypeSize: 4}}}, Kind: []string{"fd", "fd_vhci"}, Values: []uint64{18446744073709551615, 18446744073709551516}},
@@ -25455,9 +25456,23 @@ var structDescs_ppc64le = []*KeyedStruct{
&BufferType{TypeCommon: TypeCommon{TypeName: "array", FldName: "slave_interfaces", IsVarlen: true}, Kind: 1, RangeEnd: 6},
}}},
{Key: StructKey{Name: "usb_config_descriptor"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_config_descriptor", IsVarlen: true}, Fields: []Type{
- &StructType{Key: StructKey{Name: "usb_config_descriptor_t[array[usb_interface_descriptor, 1]]"}, FldName: "inner"},
+ &StructType{Key: StructKey{Name: "usb_config_descriptor_t[flags[usb_config_attributes, int8], array[usb_interface_descriptor, 1]]"}, FldName: "inner"},
}}},
- {Key: StructKey{Name: "usb_config_descriptor_t[array[usb_interface_descriptor, 1]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_config_descriptor_t[array[usb_interface_descriptor, 1]]", IsVarlen: true}, Fields: []Type{
+ {Key: StructKey{Name: "usb_config_descriptor_hid"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_config_descriptor_hid", IsVarlen: true}, Fields: []Type{
+ &StructType{Key: StructKey{Name: "usb_config_descriptor_t[const[USB_CONFIG_HID_ATTRIBUTES, int8], array[usb_interface_descriptor_hid, 1]]"}, FldName: "inner"},
+ }}},
+ {Key: StructKey{Name: "usb_config_descriptor_t[const[USB_CONFIG_HID_ATTRIBUTES, int8], array[usb_interface_descriptor_hid, 1]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_config_descriptor_t[const[USB_CONFIG_HID_ATTRIBUTES, int8], array[usb_interface_descriptor_hid, 1]]", IsVarlen: true}, Fields: []Type{
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 9},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 2},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "wTotalLength", TypeSize: 2}}, Path: []string{"parent"}},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "bNumInterfaces", TypeSize: 1}}, Path: []string{"interfaces"}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bConfigurationValue", TypeSize: 1}}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "iConfiguration", TypeSize: 1}}},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bmAttributes", TypeSize: 1}}, Val: 160},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bMaxPower", TypeSize: 1}}},
+ &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "interfaces", IsVarlen: true}, Type: &StructType{Key: StructKey{Name: "usb_interface_descriptor_hid"}}, Kind: 1, RangeBegin: 1, RangeEnd: 1},
+ }}},
+ {Key: StructKey{Name: "usb_config_descriptor_t[flags[usb_config_attributes, int8], array[usb_interface_descriptor, 1]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_config_descriptor_t[flags[usb_config_attributes, int8], array[usb_interface_descriptor, 1]]", IsVarlen: true}, Fields: []Type{
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 9},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 2},
&LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "wTotalLength", TypeSize: 2}}, Path: []string{"parent"}},
@@ -25480,14 +25495,17 @@ var structDescs_ppc64le = []*KeyedStruct{
{Key: StructKey{Name: "usb_device_descriptor"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_device_descriptor", IsVarlen: true}, Fields: []Type{
&StructType{Key: StructKey{Name: "usb_device_descriptor_t[0, 0, 0, 0, 0, 0, array[usb_config_descriptor, 1]]"}, FldName: "inner"},
}}},
+ {Key: StructKey{Name: "usb_device_descriptor_hid"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_device_descriptor_hid", IsVarlen: true}, Fields: []Type{
+ &StructType{Key: StructKey{Name: "usb_device_descriptor_t[0, 0, 0, 0x46d, 0xc31c, 64, array[usb_config_descriptor_hid, 1]]"}, FldName: "inner"},
+ }}},
{Key: StructKey{Name: "usb_device_descriptor_t[0, 0, 0, 0, 0, 0, array[usb_config_descriptor, 1]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_device_descriptor_t[0, 0, 0, 0, 0, 0, array[usb_config_descriptor, 1]]", IsVarlen: true}, Fields: []Type{
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 18},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 1},
- &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "bcdUSB", TypeSize: 2}}},
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_versions", FldName: "bcdUSB", TypeSize: 2}}, Vals: []uint64{272, 512, 513, 592, 768, 784}},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDeviceClass", TypeSize: 1}}},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDeviceSubClass", TypeSize: 1}}},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDeviceProtocol", TypeSize: 1}}},
- &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bMaxPacketSize0", TypeSize: 1}}},
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_max_packet_sizes", FldName: "bMaxPacketSize0", TypeSize: 1}}, Vals: []uint64{8, 16, 32, 64}, BitMask: true},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "idVendor", TypeSize: 2}}},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "idProduct", TypeSize: 2}}},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bcdDevice", TypeSize: 2}}},
@@ -25497,13 +25515,44 @@ var structDescs_ppc64le = []*KeyedStruct{
&LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "bNumConfigurations", TypeSize: 1}}, Path: []string{"configs"}},
&ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "configs", IsVarlen: true}, Type: &StructType{Key: StructKey{Name: "usb_config_descriptor"}}, Kind: 1, RangeBegin: 1, RangeEnd: 1},
}}},
+ {Key: StructKey{Name: "usb_device_descriptor_t[0, 0, 0, 0x46d, 0xc31c, 64, array[usb_config_descriptor_hid, 1]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_device_descriptor_t[0, 0, 0, 0x46d, 0xc31c, 64, array[usb_config_descriptor_hid, 1]]", IsVarlen: true}, Fields: []Type{
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 18},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 1},
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_versions", FldName: "bcdUSB", TypeSize: 2}}, Vals: []uint64{272, 512, 513, 592, 768, 784}},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDeviceClass", TypeSize: 1}}},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDeviceSubClass", TypeSize: 1}}},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDeviceProtocol", TypeSize: 1}}},
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_max_packet_sizes", FldName: "bMaxPacketSize0", TypeSize: 1}}, Vals: []uint64{8, 16, 32, 64}, BitMask: true},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "idVendor", TypeSize: 2}}, Val: 1133},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "idProduct", TypeSize: 2}}, Val: 49948},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bcdDevice", TypeSize: 2}}, Val: 64},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "iManufacturer", TypeSize: 1}}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "iProduct", TypeSize: 1}}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "iSerialNumber", TypeSize: 1}}},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "bNumConfigurations", TypeSize: 1}}, Path: []string{"configs"}},
+ &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "configs", IsVarlen: true}, Type: &StructType{Key: StructKey{Name: "usb_config_descriptor_hid"}}, Kind: 1, RangeBegin: 1, RangeEnd: 1},
+ }}},
{Key: StructKey{Name: "usb_endpoint_descriptor"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_endpoint_descriptor", IsVarlen: true}, Fields: []Type{
- &StructType{Key: StructKey{Name: "usb_endpoint_descriptor_t[array[usb_endpoint_extra_descriptor, 0:2]]"}, FldName: "inner"},
+ &StructType{Key: StructKey{Name: "usb_endpoint_descriptor_t[flags[usb_endpoint_addresses, int8], flags[usb_endpoint_attributes, int8], array[usb_endpoint_extra_descriptor, 0:2]]"}, FldName: "inner"},
+ }}},
+ {Key: StructKey{Name: "usb_endpoint_descriptor_hid"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_endpoint_descriptor_hid", IsVarlen: true}, Fields: []Type{
+ &StructType{Key: StructKey{Name: "usb_endpoint_descriptor_t[const[USB_ENDPOINT_HID_ADDRESS, int8], const[USB_ENDPOINT_HID_ATTRIBUTES, int8], array[usb_endpoint_extra_descriptor, 0:2]]"}, FldName: "inner"},
+ }}},
+ {Key: StructKey{Name: "usb_endpoint_descriptor_t[const[USB_ENDPOINT_HID_ADDRESS, int8], const[USB_ENDPOINT_HID_ATTRIBUTES, int8], array[usb_endpoint_extra_descriptor, 0:2]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_endpoint_descriptor_t[const[USB_ENDPOINT_HID_ADDRESS, int8], const[USB_ENDPOINT_HID_ATTRIBUTES, int8], array[usb_endpoint_extra_descriptor, 0:2]]", IsVarlen: true}, Fields: []Type{
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 7},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 5},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bEndpointAddress", TypeSize: 1}}, Val: 129},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bmAttributes", TypeSize: 1}}, Val: 3},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "wMaxPacketSize", TypeSize: 2}}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bInterval", TypeSize: 1}}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bRefresh", TypeSize: 1}}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bSynchAddress", TypeSize: 1}}},
+ &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "extra", IsVarlen: true}, Type: &UnionType{Key: StructKey{Name: "usb_endpoint_extra_descriptor"}}, Kind: 1, RangeEnd: 2},
}}},
- {Key: StructKey{Name: "usb_endpoint_descriptor_t[array[usb_endpoint_extra_descriptor, 0:2]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_endpoint_descriptor_t[array[usb_endpoint_extra_descriptor, 0:2]]", IsVarlen: true}, Fields: []Type{
+ {Key: StructKey{Name: "usb_endpoint_descriptor_t[flags[usb_endpoint_addresses, int8], flags[usb_endpoint_attributes, int8], array[usb_endpoint_extra_descriptor, 0:2]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_endpoint_descriptor_t[flags[usb_endpoint_addresses, int8], flags[usb_endpoint_attributes, int8], array[usb_endpoint_extra_descriptor, 0:2]]", IsVarlen: true}, Fields: []Type{
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 7},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 5},
- &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bEndpointAddress", TypeSize: 1}}},
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_endpoint_addresses", FldName: "bEndpointAddress", TypeSize: 1}}, Vals: []uint64{1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 0, 128}},
&FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_endpoint_attributes", FldName: "bmAttributes", TypeSize: 1}}, Vals: []uint64{0, 1, 2, 3, 0, 16, 0, 4, 8, 12, 0, 16, 16}},
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "wMaxPacketSize", TypeSize: 2}}},
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bInterval", TypeSize: 1}}},
@@ -25562,6 +25611,9 @@ var structDescs_ppc64le = []*KeyedStruct{
{Key: StructKey{Name: "usb_interface_descriptor"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_interface_descriptor", IsVarlen: true}, Fields: []Type{
&StructType{Key: StructKey{Name: "usb_interface_descriptor_t[0, 0, 0, array[usb_interface_extra_descriptor, 0:2], array[usb_endpoint_descriptor, 0:16]]"}, FldName: "inner"},
}}},
+ {Key: StructKey{Name: "usb_interface_descriptor_hid"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_interface_descriptor_hid", IsVarlen: true}, Fields: []Type{
+ &StructType{Key: StructKey{Name: "usb_interface_descriptor_t[USB_CLASS_HID, USB_INTERFACE_SUBCLASS_BOOT, USB_INTERFACE_PROTOCOL_KEYBOARD, hid_descriptor_hid, array[usb_endpoint_descriptor_hid, 1]]"}, FldName: "inner"},
+ }}},
{Key: StructKey{Name: "usb_interface_descriptor_t[0, 0, 0, array[usb_interface_extra_descriptor, 0:2], array[usb_endpoint_descriptor, 0:16]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_interface_descriptor_t[0, 0, 0, array[usb_interface_extra_descriptor, 0:2], array[usb_endpoint_descriptor, 0:16]]", IsVarlen: true}, Fields: []Type{
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 9},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 4},
@@ -25575,6 +25627,19 @@ var structDescs_ppc64le = []*KeyedStruct{
&ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "extra", IsVarlen: true}, Type: &UnionType{Key: StructKey{Name: "usb_interface_extra_descriptor"}}, Kind: 1, RangeEnd: 2},
&ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "endpoints", IsVarlen: true}, Type: &StructType{Key: StructKey{Name: "usb_endpoint_descriptor"}}, Kind: 1, RangeEnd: 16},
}}},
+ {Key: StructKey{Name: "usb_interface_descriptor_t[USB_CLASS_HID, USB_INTERFACE_SUBCLASS_BOOT, USB_INTERFACE_PROTOCOL_KEYBOARD, hid_descriptor_hid, array[usb_endpoint_descriptor_hid, 1]]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_interface_descriptor_t[USB_CLASS_HID, USB_INTERFACE_SUBCLASS_BOOT, USB_INTERFACE_PROTOCOL_KEYBOARD, hid_descriptor_hid, array[usb_endpoint_descriptor_hid, 1]]", IsVarlen: true}, Fields: []Type{
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bLength", TypeSize: 1}}, Val: 9},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 4},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bInterfaceNumber", TypeSize: 1}}},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bAlternateSetting", TypeSize: 1}}},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "bNumEndpoints", TypeSize: 1}}, Path: []string{"endpoints"}},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bInterfaceClass", TypeSize: 1}}, Val: 3},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bInterfaceSubClass", TypeSize: 1}}, Val: 1},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bInterfaceProtocol", TypeSize: 1}}, Val: 1},
+ &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "iInterface", TypeSize: 1}}},
+ &StructType{Key: StructKey{Name: "hid_descriptor_hid"}, FldName: "extra"},
+ &ArrayType{TypeCommon: TypeCommon{TypeName: "array", FldName: "endpoints", IsVarlen: true}, Type: &StructType{Key: StructKey{Name: "usb_endpoint_descriptor_hid"}}, Kind: 1, RangeBegin: 1, RangeEnd: 1},
+ }}},
{Key: StructKey{Name: "usb_interface_extra_descriptor"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_interface_extra_descriptor", IsVarlen: true}, Fields: []Type{
&StructType{Key: StructKey{Name: "usb_generic_descriptor"}, FldName: "generic"},
&StructType{Key: StructKey{Name: "hid_descriptor_hid"}, FldName: "hid_hid"},
@@ -25593,11 +25658,11 @@ var structDescs_ppc64le = []*KeyedStruct{
{Key: StructKey{Name: "usb_qualifier_descriptor"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "usb_qualifier_descriptor", TypeSize: 10}, Fields: []Type{
&LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "bLength", TypeSize: 1}}, Path: []string{"parent"}},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bDescriptorType", TypeSize: 1}}, Val: 6},
- &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "bcdUSB", TypeSize: 2}}},
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_versions", FldName: "bcdUSB", TypeSize: 2}}, Vals: []uint64{272, 512, 513, 592, 768, 784}},
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bDeviceClass", TypeSize: 1}}},
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bDeviceSubClass", TypeSize: 1}}},
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bDeviceProtocol", TypeSize: 1}}},
- &IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bMaxPacketSize0", TypeSize: 1}}},
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_max_packet_sizes", FldName: "bMaxPacketSize0", TypeSize: 1}}, Vals: []uint64{8, 16, 32, 64}, BitMask: true},
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int8", FldName: "bNumConfigurations", TypeSize: 1}}},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "bRESERVED", TypeSize: 1}}},
}}},
@@ -26763,12 +26828,37 @@ var structDescs_ppc64le = []*KeyedStruct{
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "hub_hs", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_descriptor_t[USB_TYPE_STANDARD, USB_DT_HUB, usb_hub_descriptor_hs]"}}},
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "hub_ss", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_descriptor_t[USB_TYPE_STANDARD, USB_DT_SS_HUB, usb_hub_descriptor_ss]"}}},
}}},
+ {Key: StructKey{Name: "vusb_descriptors_hid"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "vusb_descriptors_hid", TypeSize: 36}, Fields: []Type{
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "len", TypeSize: 4}}, Path: []string{"parent"}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "generic", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_descriptor_generic"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "string", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_descriptor_t[USB_TYPE_STANDARD, USB_DT_STRING, usb_string_descriptor]"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "hid_report", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_descriptor_t[USB_TYPE_STANDARD, HID_DT_REPORT, hid_descriptor_report]"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "bos", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_descriptor_t[USB_TYPE_STANDARD, USB_DT_BOS, usb_bos_descriptor]"}}},
+ }}},
{Key: StructKey{Name: "vusb_response_generic"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "vusb_response_generic", IsVarlen: true}, Fields: []Type{
&FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_request_types", FldName: "type", TypeSize: 1}}, Vals: []uint64{0, 32, 64}, BitMask: true},
&FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_requests", FldName: "req", TypeSize: 1}}, Vals: []uint64{0, 1, 3, 5, 6, 7, 8, 9, 10, 11, 12, 48, 49, 13, 14, 14, 15, 15, 16, 17, 18, 19, 20, 21, 22, 23, 20, 21, 22, 23, 24}},
&LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize", FldName: "len", TypeSize: 4}}, BitSize: 8, Path: []string{"data"}},
&BufferType{TypeCommon: TypeCommon{TypeName: "array", FldName: "data", IsVarlen: true}},
}}},
+ {Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_IDLE, void]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_IDLE, void]", TypeSize: 6}, Fields: []Type{
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "type", TypeSize: 1}}, Val: 32},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "req", TypeSize: 1}}, Val: 10},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize", FldName: "len", TypeSize: 4}}, BitSize: 8, Path: []string{"data"}},
+ &BufferType{TypeCommon: TypeCommon{TypeName: "void", FldName: "data"}, Kind: 1},
+ }}},
+ {Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_PROTOCOL, void]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_PROTOCOL, void]", TypeSize: 6}, Fields: []Type{
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "type", TypeSize: 1}}, Val: 32},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "req", TypeSize: 1}}, Val: 11},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize", FldName: "len", TypeSize: 4}}, BitSize: 8, Path: []string{"data"}},
+ &BufferType{TypeCommon: TypeCommon{TypeName: "void", FldName: "data"}, Kind: 1},
+ }}},
+ {Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_REPORT, void]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_REPORT, void]", TypeSize: 6}, Fields: []Type{
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "type", TypeSize: 1}}, Val: 32},
+ &ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "req", TypeSize: 1}}, Val: 9},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "bytesize", FldName: "len", TypeSize: 4}}, BitSize: 8, Path: []string{"data"}},
+ &BufferType{TypeCommon: TypeCommon{TypeName: "void", FldName: "data"}, Kind: 1},
+ }}},
{Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, USB_CDC_GET_NTB_PARAMETERS, usb_cdc_ncm_ntb_parameters]"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "vusb_response_t[USB_TYPE_CLASS, USB_CDC_GET_NTB_PARAMETERS, usb_cdc_ncm_ntb_parameters]", TypeSize: 34}, Fields: []Type{
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "type", TypeSize: 1}}, Val: 32},
&ConstType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "const", FldName: "req", TypeSize: 1}}, Val: 128},
@@ -26836,6 +26926,13 @@ var structDescs_ppc64le = []*KeyedStruct{
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "aiptek_set_report", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_response_t[USB_TYPE_VENDOR, 0x9, array[int8, 3]]"}}},
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "cdc_get_ntb_parameters", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, USB_CDC_GET_NTB_PARAMETERS, usb_cdc_ncm_ntb_parameters]"}}},
}}},
+ {Key: StructKey{Name: "vusb_responses_hid"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "vusb_responses_hid", TypeSize: 36}, Fields: []Type{
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "len", TypeSize: 4}}, Path: []string{"parent"}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "generic", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_response_generic"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "set_idle", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_IDLE, void]"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "set_report", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_REPORT, void]"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "set_protocol", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_response_t[USB_TYPE_CLASS, HID_REQ_SET_PROTOCOL, void]"}}},
+ }}},
{Key: StructKey{Name: "winsize"}, Desc: &StructDesc{TypeCommon: TypeCommon{TypeName: "winsize", TypeSize: 8}, Fields: []Type{
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "row", TypeSize: 2}}},
&IntType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "int16", FldName: "col", TypeSize: 2}}},
@@ -42734,11 +42831,22 @@ var syscalls_ppc64le = []*Syscall{
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "dev", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "usb_device_descriptor"}}},
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "conn_descs", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_connect_descriptors"}}},
}, Ret: &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_usb", FldName: "ret", TypeSize: 4, ArgDir: 1}}},
+ {Name: "syz_usb_connect$hid", CallName: "syz_usb_connect", Args: []Type{
+ &FlagsType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "usb_device_speed", FldName: "speed", TypeSize: 8}}, Vals: []uint64{0, 1, 2, 3, 4, 5, 6}},
+ &LenType{IntTypeCommon: IntTypeCommon{TypeCommon: TypeCommon{TypeName: "len", FldName: "dev_len", TypeSize: 8}}, Path: []string{"dev"}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "dev", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "usb_device_descriptor_hid"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "conn_descs", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_connect_descriptors"}}},
+ }, Ret: &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_usb_hid", FldName: "ret", TypeSize: 4, ArgDir: 1}}},
{Name: "syz_usb_control_io", CallName: "syz_usb_control_io", Args: []Type{
&ResourceType{TypeCommon: TypeCommon{TypeName: "fd_usb", FldName: "fd", TypeSize: 4}},
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "descs", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_descriptors"}}},
&PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "resps", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_responses"}}},
}},
+ {Name: "syz_usb_control_io$hid", CallName: "syz_usb_control_io", Args: []Type{
+ &ResourceType{TypeCommon: TypeCommon{TypeName: "fd_usb_hid", FldName: "fd", TypeSize: 4}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "descs", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_descriptors_hid"}}},
+ &PtrType{TypeCommon: TypeCommon{TypeName: "ptr", FldName: "resps", TypeSize: 8}, Type: &StructType{Key: StructKey{Name: "vusb_responses_hid"}}},
+ }},
{Name: "syz_usb_disconnect", CallName: "syz_usb_disconnect", Args: []Type{
&ResourceType{TypeCommon: TypeCommon{TypeName: "fd_usb", FldName: "fd", TypeSize: 4}},
}},
@@ -45394,6 +45502,9 @@ var consts_ppc64le = []ConstValue{
{Name: "HID_REPORT_ID_UNKNOWN", Value: 4294967295},
{Name: "HID_REPORT_TYPE_MAX", Value: 3},
{Name: "HID_REPORT_TYPE_MIN", Value: 1},
+ {Name: "HID_REQ_SET_IDLE", Value: 10},
+ {Name: "HID_REQ_SET_PROTOCOL", Value: 11},
+ {Name: "HID_REQ_SET_REPORT", Value: 9},
{Name: "HUB_CHANGE_LOCAL_POWER", Value: 1},
{Name: "HUB_CHANGE_OVERCURRENT", Value: 2},
{Name: "HUB_CHAR_COMMON_LPSM"},
@@ -49616,10 +49727,14 @@ var consts_ppc64le = []ConstValue{
{Name: "USB_CDC_OBEX_TYPE", Value: 21},
{Name: "USB_CDC_UNION_TYPE", Value: 6},
{Name: "USB_CDC_WHCM_TYPE", Value: 17},
+ {Name: "USB_CLASS_HID", Value: 3},
{Name: "USB_CONFIG_ATT_BATTERY", Value: 16},
{Name: "USB_CONFIG_ATT_ONE", Value: 128},
{Name: "USB_CONFIG_ATT_SELFPOWER", Value: 64},
{Name: "USB_CONFIG_ATT_WAKEUP", Value: 32},
+ {Name: "USB_CONFIG_HID_ATTRIBUTES", Value: 160},
+ {Name: "USB_DIR_IN", Value: 128},
+ {Name: "USB_DIR_OUT"},
{Name: "USB_DT_BOS", Value: 15},
{Name: "USB_DT_BOS_SIZE", Value: 5},
{Name: "USB_DT_CONFIG", Value: 2},
@@ -49651,6 +49766,8 @@ var consts_ppc64le = []ConstValue{
{Name: "USB_DT_STRING", Value: 3},
{Name: "USB_DT_WIRELESS_ENDPOINT_COMP", Value: 17},
{Name: "USB_DT_WIRE_ADAPTER", Value: 33},
+ {Name: "USB_ENDPOINT_HID_ADDRESS", Value: 129},
+ {Name: "USB_ENDPOINT_HID_ATTRIBUTES", Value: 3},
{Name: "USB_ENDPOINT_INTR_NOTIFICATION", Value: 16},
{Name: "USB_ENDPOINT_INTR_PERIODIC"},
{Name: "USB_ENDPOINT_SYNC_ADAPTIVE", Value: 8},
@@ -49670,6 +49787,8 @@ var consts_ppc64le = []ConstValue{
{Name: "USB_FULL_SPEED_OPERATION", Value: 2},
{Name: "USB_HIGH_SPEED_OPERATION", Value: 4},
{Name: "USB_HUB_PORTS_BITS", Value: 4},
+ {Name: "USB_INTERFACE_PROTOCOL_KEYBOARD", Value: 1},
+ {Name: "USB_INTERFACE_SUBCLASS_BOOT", Value: 1},
{Name: "USB_LOW_SPEED_OPERATION", Value: 1},
{Name: "USB_LPM_SUPPORT", Value: 2},
{Name: "USB_LTM_SUPPORT", Value: 2},
@@ -51435,4 +51554,4 @@ var consts_ppc64le = []ConstValue{
{Name: "bpf_insn_load_imm_dw", Value: 24},
}
-const revision_ppc64le = "12a67b26a16f091bb22565da44fc18f098ad4f59"
+const revision_ppc64le = "639f7473fa165cbe9436142cae3f78b2b627c06b"
diff --git a/sys/linux/vusb_386.const b/sys/linux/vusb_386.const
index 0ab135e7e..303fc602b 100644
--- a/sys/linux/vusb_386.const
+++ b/sys/linux/vusb_386.const
@@ -36,6 +36,9 @@ HID_MAIN_ITEM_TAG_FEATURE = 11
HID_MAIN_ITEM_TAG_INPUT = 8
HID_MAIN_ITEM_TAG_OUTPUT = 9
HID_MAX_DESCRIPTOR_SIZE = 4096
+HID_REQ_SET_IDLE = 10
+HID_REQ_SET_PROTOCOL = 11
+HID_REQ_SET_REPORT = 9
HUB_CHANGE_LOCAL_POWER = 1
HUB_CHANGE_OVERCURRENT = 2
HUB_CHAR_COMMON_LPSM = 0
@@ -79,10 +82,14 @@ USB_CDC_NETWORK_TERMINAL_TYPE = 10
USB_CDC_OBEX_TYPE = 21
USB_CDC_UNION_TYPE = 6
USB_CDC_WHCM_TYPE = 17
+USB_CLASS_HID = 3
USB_CONFIG_ATT_BATTERY = 16
USB_CONFIG_ATT_ONE = 128
USB_CONFIG_ATT_SELFPOWER = 64
USB_CONFIG_ATT_WAKEUP = 32
+USB_CONFIG_HID_ATTRIBUTES = 160
+USB_DIR_IN = 128
+USB_DIR_OUT = 0
USB_DT_BOS = 15
USB_DT_BOS_SIZE = 5
USB_DT_CONFIG = 2
@@ -114,6 +121,8 @@ USB_DT_SS_HUB = 42
USB_DT_STRING = 3
USB_DT_WIRELESS_ENDPOINT_COMP = 17
USB_DT_WIRE_ADAPTER = 33
+USB_ENDPOINT_HID_ADDRESS = 129
+USB_ENDPOINT_HID_ATTRIBUTES = 3
USB_ENDPOINT_INTR_NOTIFICATION = 16
USB_ENDPOINT_INTR_PERIODIC = 0
USB_ENDPOINT_SYNC_ADAPTIVE = 8
@@ -133,6 +142,8 @@ USB_EXT_PORT_STAT_TX_SPEED_ID = 240
USB_FULL_SPEED_OPERATION = 2
USB_HIGH_SPEED_OPERATION = 4
USB_HUB_PORTS_BITS = 4
+USB_INTERFACE_PROTOCOL_KEYBOARD = 1
+USB_INTERFACE_SUBCLASS_BOOT = 1
USB_LOW_SPEED_OPERATION = 1
USB_LPM_SUPPORT = 2
USB_LTM_SUPPORT = 2
diff --git a/sys/linux/vusb_amd64.const b/sys/linux/vusb_amd64.const
index 0ab135e7e..303fc602b 100644
--- a/sys/linux/vusb_amd64.const
+++ b/sys/linux/vusb_amd64.const
@@ -36,6 +36,9 @@ HID_MAIN_ITEM_TAG_FEATURE = 11
HID_MAIN_ITEM_TAG_INPUT = 8
HID_MAIN_ITEM_TAG_OUTPUT = 9
HID_MAX_DESCRIPTOR_SIZE = 4096
+HID_REQ_SET_IDLE = 10
+HID_REQ_SET_PROTOCOL = 11
+HID_REQ_SET_REPORT = 9
HUB_CHANGE_LOCAL_POWER = 1
HUB_CHANGE_OVERCURRENT = 2
HUB_CHAR_COMMON_LPSM = 0
@@ -79,10 +82,14 @@ USB_CDC_NETWORK_TERMINAL_TYPE = 10
USB_CDC_OBEX_TYPE = 21
USB_CDC_UNION_TYPE = 6
USB_CDC_WHCM_TYPE = 17
+USB_CLASS_HID = 3
USB_CONFIG_ATT_BATTERY = 16
USB_CONFIG_ATT_ONE = 128
USB_CONFIG_ATT_SELFPOWER = 64
USB_CONFIG_ATT_WAKEUP = 32
+USB_CONFIG_HID_ATTRIBUTES = 160
+USB_DIR_IN = 128
+USB_DIR_OUT = 0
USB_DT_BOS = 15
USB_DT_BOS_SIZE = 5
USB_DT_CONFIG = 2
@@ -114,6 +121,8 @@ USB_DT_SS_HUB = 42
USB_DT_STRING = 3
USB_DT_WIRELESS_ENDPOINT_COMP = 17
USB_DT_WIRE_ADAPTER = 33
+USB_ENDPOINT_HID_ADDRESS = 129
+USB_ENDPOINT_HID_ATTRIBUTES = 3
USB_ENDPOINT_INTR_NOTIFICATION = 16
USB_ENDPOINT_INTR_PERIODIC = 0
USB_ENDPOINT_SYNC_ADAPTIVE = 8
@@ -133,6 +142,8 @@ USB_EXT_PORT_STAT_TX_SPEED_ID = 240
USB_FULL_SPEED_OPERATION = 2
USB_HIGH_SPEED_OPERATION = 4
USB_HUB_PORTS_BITS = 4
+USB_INTERFACE_PROTOCOL_KEYBOARD = 1
+USB_INTERFACE_SUBCLASS_BOOT = 1
USB_LOW_SPEED_OPERATION = 1
USB_LPM_SUPPORT = 2
USB_LTM_SUPPORT = 2
diff --git a/sys/linux/vusb_arm.const b/sys/linux/vusb_arm.const
index 0ab135e7e..303fc602b 100644
--- a/sys/linux/vusb_arm.const
+++ b/sys/linux/vusb_arm.const
@@ -36,6 +36,9 @@ HID_MAIN_ITEM_TAG_FEATURE = 11
HID_MAIN_ITEM_TAG_INPUT = 8
HID_MAIN_ITEM_TAG_OUTPUT = 9
HID_MAX_DESCRIPTOR_SIZE = 4096
+HID_REQ_SET_IDLE = 10
+HID_REQ_SET_PROTOCOL = 11
+HID_REQ_SET_REPORT = 9
HUB_CHANGE_LOCAL_POWER = 1
HUB_CHANGE_OVERCURRENT = 2
HUB_CHAR_COMMON_LPSM = 0
@@ -79,10 +82,14 @@ USB_CDC_NETWORK_TERMINAL_TYPE = 10
USB_CDC_OBEX_TYPE = 21
USB_CDC_UNION_TYPE = 6
USB_CDC_WHCM_TYPE = 17
+USB_CLASS_HID = 3
USB_CONFIG_ATT_BATTERY = 16
USB_CONFIG_ATT_ONE = 128
USB_CONFIG_ATT_SELFPOWER = 64
USB_CONFIG_ATT_WAKEUP = 32
+USB_CONFIG_HID_ATTRIBUTES = 160
+USB_DIR_IN = 128
+USB_DIR_OUT = 0
USB_DT_BOS = 15
USB_DT_BOS_SIZE = 5
USB_DT_CONFIG = 2
@@ -114,6 +121,8 @@ USB_DT_SS_HUB = 42
USB_DT_STRING = 3
USB_DT_WIRELESS_ENDPOINT_COMP = 17
USB_DT_WIRE_ADAPTER = 33
+USB_ENDPOINT_HID_ADDRESS = 129
+USB_ENDPOINT_HID_ATTRIBUTES = 3
USB_ENDPOINT_INTR_NOTIFICATION = 16
USB_ENDPOINT_INTR_PERIODIC = 0
USB_ENDPOINT_SYNC_ADAPTIVE = 8
@@ -133,6 +142,8 @@ USB_EXT_PORT_STAT_TX_SPEED_ID = 240
USB_FULL_SPEED_OPERATION = 2
USB_HIGH_SPEED_OPERATION = 4
USB_HUB_PORTS_BITS = 4
+USB_INTERFACE_PROTOCOL_KEYBOARD = 1
+USB_INTERFACE_SUBCLASS_BOOT = 1
USB_LOW_SPEED_OPERATION = 1
USB_LPM_SUPPORT = 2
USB_LTM_SUPPORT = 2
diff --git a/sys/linux/vusb_arm64.const b/sys/linux/vusb_arm64.const
index 0ab135e7e..303fc602b 100644
--- a/sys/linux/vusb_arm64.const
+++ b/sys/linux/vusb_arm64.const
@@ -36,6 +36,9 @@ HID_MAIN_ITEM_TAG_FEATURE = 11
HID_MAIN_ITEM_TAG_INPUT = 8
HID_MAIN_ITEM_TAG_OUTPUT = 9
HID_MAX_DESCRIPTOR_SIZE = 4096
+HID_REQ_SET_IDLE = 10
+HID_REQ_SET_PROTOCOL = 11
+HID_REQ_SET_REPORT = 9
HUB_CHANGE_LOCAL_POWER = 1
HUB_CHANGE_OVERCURRENT = 2
HUB_CHAR_COMMON_LPSM = 0
@@ -79,10 +82,14 @@ USB_CDC_NETWORK_TERMINAL_TYPE = 10
USB_CDC_OBEX_TYPE = 21
USB_CDC_UNION_TYPE = 6
USB_CDC_WHCM_TYPE = 17
+USB_CLASS_HID = 3
USB_CONFIG_ATT_BATTERY = 16
USB_CONFIG_ATT_ONE = 128
USB_CONFIG_ATT_SELFPOWER = 64
USB_CONFIG_ATT_WAKEUP = 32
+USB_CONFIG_HID_ATTRIBUTES = 160
+USB_DIR_IN = 128
+USB_DIR_OUT = 0
USB_DT_BOS = 15
USB_DT_BOS_SIZE = 5
USB_DT_CONFIG = 2
@@ -114,6 +121,8 @@ USB_DT_SS_HUB = 42
USB_DT_STRING = 3
USB_DT_WIRELESS_ENDPOINT_COMP = 17
USB_DT_WIRE_ADAPTER = 33
+USB_ENDPOINT_HID_ADDRESS = 129
+USB_ENDPOINT_HID_ATTRIBUTES = 3
USB_ENDPOINT_INTR_NOTIFICATION = 16
USB_ENDPOINT_INTR_PERIODIC = 0
USB_ENDPOINT_SYNC_ADAPTIVE = 8
@@ -133,6 +142,8 @@ USB_EXT_PORT_STAT_TX_SPEED_ID = 240
USB_FULL_SPEED_OPERATION = 2
USB_HIGH_SPEED_OPERATION = 4
USB_HUB_PORTS_BITS = 4
+USB_INTERFACE_PROTOCOL_KEYBOARD = 1
+USB_INTERFACE_SUBCLASS_BOOT = 1
USB_LOW_SPEED_OPERATION = 1
USB_LPM_SUPPORT = 2
USB_LTM_SUPPORT = 2
diff --git a/sys/linux/vusb_ppc64le.const b/sys/linux/vusb_ppc64le.const
index 0ab135e7e..303fc602b 100644
--- a/sys/linux/vusb_ppc64le.const
+++ b/sys/linux/vusb_ppc64le.const
@@ -36,6 +36,9 @@ HID_MAIN_ITEM_TAG_FEATURE = 11
HID_MAIN_ITEM_TAG_INPUT = 8
HID_MAIN_ITEM_TAG_OUTPUT = 9
HID_MAX_DESCRIPTOR_SIZE = 4096
+HID_REQ_SET_IDLE = 10
+HID_REQ_SET_PROTOCOL = 11
+HID_REQ_SET_REPORT = 9
HUB_CHANGE_LOCAL_POWER = 1
HUB_CHANGE_OVERCURRENT = 2
HUB_CHAR_COMMON_LPSM = 0
@@ -79,10 +82,14 @@ USB_CDC_NETWORK_TERMINAL_TYPE = 10
USB_CDC_OBEX_TYPE = 21
USB_CDC_UNION_TYPE = 6
USB_CDC_WHCM_TYPE = 17
+USB_CLASS_HID = 3
USB_CONFIG_ATT_BATTERY = 16
USB_CONFIG_ATT_ONE = 128
USB_CONFIG_ATT_SELFPOWER = 64
USB_CONFIG_ATT_WAKEUP = 32
+USB_CONFIG_HID_ATTRIBUTES = 160
+USB_DIR_IN = 128
+USB_DIR_OUT = 0
USB_DT_BOS = 15
USB_DT_BOS_SIZE = 5
USB_DT_CONFIG = 2
@@ -114,6 +121,8 @@ USB_DT_SS_HUB = 42
USB_DT_STRING = 3
USB_DT_WIRELESS_ENDPOINT_COMP = 17
USB_DT_WIRE_ADAPTER = 33
+USB_ENDPOINT_HID_ADDRESS = 129
+USB_ENDPOINT_HID_ATTRIBUTES = 3
USB_ENDPOINT_INTR_NOTIFICATION = 16
USB_ENDPOINT_INTR_PERIODIC = 0
USB_ENDPOINT_SYNC_ADAPTIVE = 8
@@ -133,6 +142,8 @@ USB_EXT_PORT_STAT_TX_SPEED_ID = 240
USB_FULL_SPEED_OPERATION = 2
USB_HIGH_SPEED_OPERATION = 4
USB_HUB_PORTS_BITS = 4
+USB_INTERFACE_PROTOCOL_KEYBOARD = 1
+USB_INTERFACE_SUBCLASS_BOOT = 1
USB_LOW_SPEED_OPERATION = 1
USB_LPM_SUPPORT = 2
USB_LTM_SUPPORT = 2