summary refs log tree commit diff stats
path: root/hw/usb/desc.c
diff options
context:
space:
mode:
authorAnthony Liguori <aliguori@amazon.com>2013-12-06 12:54:35 -0800
committerAnthony Liguori <aliguori@amazon.com>2013-12-06 12:54:36 -0800
commite679f05248e220b8ef587e8fd6c64ffe83b1e16f (patch)
treeb0a6f7e6d54c230848bf9af901ee584480eae199 /hw/usb/desc.c
parent783eb67e7a125eaf226e5ea4f5df97c1ea42311e (diff)
parent0b1fa34e1dd2764ee7ae2be849e1c5ba5e8724ca (diff)
downloadfocaccia-qemu-e679f05248e220b8ef587e8fd6c64ffe83b1e16f.tar.gz
focaccia-qemu-e679f05248e220b8ef587e8fd6c64ffe83b1e16f.zip
Merge remote-tracking branch 'kraxel/tags/pull-usb-1' into staging
Improvements for usb3 bulk stream (usb core, xhci).
Bugfixes for uas emulation.
Add remote wakeup support for ehci.
Add suspend support for xhci.
Misc minor tweaks and fixes.

# gpg: Signature made Thu 28 Nov 2013 11:44:49 PM PST using RSA key ID D3E87138
# gpg: Can't check signature: public key not found

# By Hans de Goede (11) and others
# Via Gerd Hoffmann
* kraxel/tags/pull-usb-1:
  usb: move usb_{hi,lo} helpers to header file.
  usb: add vendor request defines
  trace-events: Clean up after removal of old usb-host code
  Revert "usb-tablet: Don't claim wakeup capability for USB-2 version"
  ehci: implement port wakeup
  xhci: Call usb_device_alloc/free_streams
  usb: Add usb_device_alloc/free_streams
  usb: Add max_streams attribute to endpoint info
  uas: s/ui/iu/
  uas: Fix response iu struct definition
  uas: Bounds check tags when using streams
  uas: Streams are numbered 1-y, rather then 0-x
  uas: Fix / cleanup usb_uas_task error handling
  uas: Only use report iu-s for task_mgmt status reporting
  scsi: Add 2 new sense codes needed by uas
  xhci: add support for suspend/resume
  xhci: Add a few missing checks for disconnected devices

Message-id: 1385712381-30918-1-git-send-email-kraxel@redhat.com
Signed-off-by: Anthony Liguori <aliguori@amazon.com>
Diffstat (limited to 'hw/usb/desc.c')
-rw-r--r--hw/usb/desc.c12
1 files changed, 2 insertions, 10 deletions
diff --git a/hw/usb/desc.c b/hw/usb/desc.c
index bf6c522682..f18a043500 100644
--- a/hw/usb/desc.c
+++ b/hw/usb/desc.c
@@ -6,16 +6,6 @@
 
 /* ------------------------------------------------------------------ */
 
-static uint8_t usb_lo(uint16_t val)
-{
-    return val & 0xff;
-}
-
-static uint8_t usb_hi(uint16_t val)
-{
-    return (val >> 8) & 0xff;
-}
-
 int usb_desc_device(const USBDescID *id, const USBDescDevice *dev,
                     uint8_t *dest, size_t len)
 {
@@ -385,6 +375,8 @@ static void usb_desc_ep_init(USBDevice *dev)
             usb_ep_set_ifnum(dev, pid, ep, iface->bInterfaceNumber);
             usb_ep_set_max_packet_size(dev, pid, ep,
                                        iface->eps[e].wMaxPacketSize);
+            usb_ep_set_max_streams(dev, pid, ep,
+                                   iface->eps[e].bmAttributes_super);
         }
     }
 }