Skip to content

Commit

Permalink
usb-redir: Only add actually in flight packets to the in flight queue
Browse files Browse the repository at this point in the history
Packets which are queued up, but not yet handed over to the device, are
*not* in flight.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
  • Loading branch information
jwrdegoede authored and kraxel committed Nov 16, 2012
1 parent 55903f1 commit 2cb343b
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion hw/usb/redirect.c
Expand Up @@ -342,7 +342,9 @@ static void usbredir_fill_already_in_flight_from_ep(USBRedirDevice *dev,
if (p->combined && p != p->combined->first) {
continue;
}
packet_id_queue_add(&dev->already_in_flight, p->id);
if (p->state == USB_PACKET_ASYNC) {
packet_id_queue_add(&dev->already_in_flight, p->id);
}
}
}

Expand Down

0 comments on commit 2cb343b

Please sign in to comment.