usb-keyboard: acknowledge HID_REQ_SET_REPORT to the host
authorarighi <arighi@38d2e660-2303-0410-9eaa-f027e97ec537>
Thu, 23 Sep 2010 10:24:23 +0000 (10:24 +0000)
committerarighi <arighi@38d2e660-2303-0410-9eaa-f027e97ec537>
Thu, 23 Sep 2010 10:24:23 +0000 (10:24 +0000)
This fixes the following connection timeout errors on Linux when reading
the USB device details via lsusb -v:

  cannot read device status, Connection timed out (110)

git-svn-id: https://src.develer.com/svnoss/bertos/trunk@4269 38d2e660-2303-0410-9eaa-f027e97ec537

bertos/drv/usb_keyboard.c

index 63c39c57f4c652673c4a833b90db6deca2fa937c..46607f4af88a849e5e0b66aafef598681aeca48d 100644 (file)
@@ -238,6 +238,7 @@ static void usb_hid_event_cb(usb_ctrlrequest_t *ctrl)
                break;
        case HID_REQ_SET_REPORT:
                LOG_INFO("%s: HID_REQ_SET_REPORT\n", __func__);
+               usb_ep_write(USB_DIR_IN | 0, NULL, 0);
                break;
        case HID_REQ_GET_IDLE:
                LOG_INFO("%s: HID_REQ_GET_IDLE\n", __func__);