]> git.proxmox.com Git - mirror_qemu.git/commitdiff
patch in bLength for hub descriptor (Lonnie Mendez)
authorbellard <bellard@c046a42c-6fe2-441c-8c8c-71466251a162>
Fri, 5 May 2006 20:05:35 +0000 (20:05 +0000)
committerbellard <bellard@c046a42c-6fe2-441c-8c8c-71466251a162>
Fri, 5 May 2006 20:05:35 +0000 (20:05 +0000)
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@1905 c046a42c-6fe2-441c-8c8c-71466251a162

hw/usb-hub.c

index fd916128cfdeb7e0994dd010c5af34fd71012a17..ec51ad929718aaedd3a1e4bd0baf51eef9b4ca2d 100644 (file)
@@ -152,7 +152,7 @@ static const uint8_t qemu_hub_config_descriptor[] = {
 
 static const uint8_t qemu_hub_hub_descriptor[] =
 {
-       0x09,                   /*  u8  bLength; */
+       0x00,                   /*  u8  bLength; patched in later */
        0x29,                   /*  u8  bDescriptorType; Hub-descriptor */
        0x00,                   /*  u8  bNbrPorts; (patched later) */
        0x0a,                   /* u16  wHubCharacteristics; */
@@ -417,6 +417,7 @@ static int usb_hub_handle_control(USBDevice *dev, int request, int value,
             }
 
             ret = sizeof(qemu_hub_hub_descriptor) + var_hub_size;
+            data[0] = ret;
             break;
         }
     default: