usb: device: hid: correct bcdHID to v1.11 spec

bcdHID is intended for the spec version of USB HID. It was pointing to the
v1.1 bcdUSB define which happens to be the same value for the v1.10 hid
spec version. This corrects it to use the v1.11 HID spec.

Signed-off-by: Ryan McClelland <ryanmcclelland@meta.com>
This commit is contained in:
Ryan McClelland 2022-12-17 11:20:37 -08:00 committed by Carles Cufí
commit 34cfba73b4
2 changed files with 4 additions and 1 deletions

View file

@ -33,6 +33,9 @@ extern "C" {
* @{ * @{
*/ */
/** HID Specification release v1.11 */
#define USB_HID_VERSION 0x0111
/** USB HID Class HID descriptor type */ /** USB HID Class HID descriptor type */
#define USB_DESC_HID 0x21 #define USB_DESC_HID 0x21
/** USB HID Class Report descriptor type */ /** USB HID Class Report descriptor type */

View file

@ -82,7 +82,7 @@ struct usb_hid_config {
{ \ { \
.bLength = sizeof(struct usb_hid_descriptor), \ .bLength = sizeof(struct usb_hid_descriptor), \
.bDescriptorType = USB_DESC_HID, \ .bDescriptorType = USB_DESC_HID, \
.bcdHID = sys_cpu_to_le16(USB_SRN_1_1), \ .bcdHID = sys_cpu_to_le16(USB_HID_VERSION), \
.bCountryCode = 0, \ .bCountryCode = 0, \
.bNumDescriptors = 1, \ .bNumDescriptors = 1, \
.subdesc[0] = { \ .subdesc[0] = { \