usb-ehci: add queue data struct
commit0122f47279d18eb79fa63ddc550aa43a98d85faf
authorGerd Hoffmann <kraxel@redhat.com>
Thu, 19 May 2011 08:49:03 +0000 (19 10:49 +0200)
committerGerd Hoffmann <kraxel@redhat.com>
Tue, 14 Jun 2011 10:36:29 +0000 (14 12:36 +0200)
tree0f6ec6086a7a4dfa7df5dc7dca94ae4c8090fd62
parentf2c88dc10e9258ba57f5edaeb3670259fb6ac2b9
usb-ehci: add queue data struct

Add EHCIQueue struct, move the fields needed to track the queue state
into that struct.  Pass the new struct instead of ehci state down to
functions which handle the queue state.  Lot of variable references have
changed due to that without an actual functional change.

Replace fetch_addr with two variables, one for async and one for
periodic schedule.  Add functions to get and set the fetch address.

Use EHCIQueue->usb_status (old name: EHCIState->exec_status) directly in
ehci_execute_complete instead of passing around the status using a
parameters and the return value.

ehci_state_fetchqh returns a EHCIQueue struct now.

No change in behavior.

Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
hw/usb-ehci.c