qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH] host-libusb: Correct test for USB packet state


From: Ed Maste
Subject: Re: [Qemu-devel] [PATCH] host-libusb: Correct test for USB packet state
Date: Tue, 21 May 2013 09:45:34 -0400

On 7 May 2013 10:06, Ed Maste <address@hidden> wrote:
> USB_RET_ASYNC is -6, so inflight was always false.

Ping.  I believe the "if (inflight)" block in usb_host_req_abort() can
never be executed in the current code.

> Signed-off-by: Ed Maste <address@hidden>
> ---
>  hw/usb/host-libusb.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/hw/usb/host-libusb.c b/hw/usb/host-libusb.c
> index d1186b8..0af6ce3 100644
> --- a/hw/usb/host-libusb.c
> +++ b/hw/usb/host-libusb.c
> @@ -384,7 +384,7 @@ out:
>  static void usb_host_req_abort(USBHostRequest *r)
>  {
>      USBHostDevice  *s = r->host;
> -    bool inflight = (r->p && r->p->state == USB_RET_ASYNC);
> +    bool inflight = (r->p && r->p->state == USB_PACKET_ASYNC);
>
>      if (inflight) {
>          r->p->status = USB_RET_NODEV;
> --
> 1.7.11.5



reply via email to

[Prev in Thread] Current Thread [Next in Thread]