]> git.proxmox.com Git - qemu.git/commit
usb: unique packet ids
authorGerd Hoffmann <kraxel@redhat.com>
Thu, 23 Aug 2012 11:30:13 +0000 (13:30 +0200)
committerGerd Hoffmann <kraxel@redhat.com>
Fri, 31 Aug 2012 09:57:23 +0000 (11:57 +0200)
commite983395d30d1d5bfa0ed3ae9c028c130f7c498cc
tree6377ecd839a30655f4a78eee1db5aec531804da7
parent0132b4b6595423c92f54d7e0b172b5d73aaa8375
usb: unique packet ids

This patch adds IDs to usb packets.  Those IDs are (a) supposed to be
unique for the lifecycle of a packet (from packet setup until the packet
is either completed or canceled) and (b) stable across migration.

uhci, ohci, ehci and xhci use the guest physical address of the transfer
descriptor for this.

musb needs a different approach because there is no transfer descriptor.
But musb also doesn't support pipelining, so we have never more than one
packet per endpoint in flight.  So we go create an ID based on endpoint
and device address.

Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
hw/usb.h
hw/usb/core.c
hw/usb/hcd-ehci.c
hw/usb/hcd-musb.c
hw/usb/hcd-ohci.c
hw/usb/hcd-uhci.c
hw/usb/hcd-xhci.c