yeahuh / rpms / qemu-kvm

Forked from rpms/qemu-kvm 2 years ago
Clone

Blame SOURCES/kvm-usb-hcd-xhci-Remove-unused-cancelled-member-from-XHC.patch

9ae3a8
From fc1acb16e008aea013d59435fc14b967f1c8a144 Mon Sep 17 00:00:00 2001
9ae3a8
From: Gerd Hoffmann <kraxel@redhat.com>
9ae3a8
Date: Fri, 11 Jul 2014 14:20:49 +0200
9ae3a8
Subject: [PATCH 15/43] usb-hcd-xhci: Remove unused cancelled member from
9ae3a8
 XHCITransfer
9ae3a8
9ae3a8
Message-id: <1405088470-24115-17-git-send-email-kraxel@redhat.com>
9ae3a8
Patchwork-id: 59831
9ae3a8
O-Subject: [RHEL-7.1 qemu-kvm PATCH 16/37] usb-hcd-xhci: Remove unused cancelled member from XHCITransfer
9ae3a8
Bugzilla: 980747
9ae3a8
RH-Acked-by: Dr. David Alan Gilbert (git) <dgilbert@redhat.com>
9ae3a8
RH-Acked-by: Miroslav Rezanina <mrezanin@redhat.com>
9ae3a8
RH-Acked-by: Laszlo Ersek <lersek@redhat.com>
9ae3a8
9ae3a8
From: Hans de Goede <hdegoede@redhat.com>
9ae3a8
9ae3a8
Since qemu's USB model is geared towards emulated devices cancellation
9ae3a8
is instanteneous, so no need to wait for cancellation to complete, as
9ae3a8
such there is no wait for cancellation code, and the cancelled bool
9ae3a8
as well as the bogus comment about it can be removed.
9ae3a8
9ae3a8
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
9ae3a8
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
9ae3a8
(cherry picked from commit 8de1838afed4b5b05d18cc42a3e5a6fe9b19f29b)
9ae3a8
---
9ae3a8
 hw/usb/hcd-xhci.c | 5 -----
9ae3a8
 1 file changed, 5 deletions(-)
9ae3a8
9ae3a8
Signed-off-by: Miroslav Rezanina <mrezanin@redhat.com>
9ae3a8
---
9ae3a8
 hw/usb/hcd-xhci.c | 5 -----
9ae3a8
 1 file changed, 5 deletions(-)
9ae3a8
9ae3a8
diff --git a/hw/usb/hcd-xhci.c b/hw/usb/hcd-xhci.c
9ae3a8
index af0c42d..3b4cd01 100644
9ae3a8
--- a/hw/usb/hcd-xhci.c
9ae3a8
+++ b/hw/usb/hcd-xhci.c
9ae3a8
@@ -346,7 +346,6 @@ typedef struct XHCITransfer {
9ae3a8
     QEMUSGList sgl;
9ae3a8
     bool running_async;
9ae3a8
     bool running_retry;
9ae3a8
-    bool cancelled;
9ae3a8
     bool complete;
9ae3a8
     bool int_req;
9ae3a8
     unsigned int iso_pkts;
9ae3a8
@@ -1312,8 +1311,6 @@ static int xhci_ep_nuke_one_xfer(XHCITransfer *t)
9ae3a8
     if (t->running_async) {
9ae3a8
         usb_cancel_packet(&t->packet);
9ae3a8
         t->running_async = 0;
9ae3a8
-        t->cancelled = 1;
9ae3a8
-        DPRINTF("xhci: cancelling transfer, waiting for it to complete\n");
9ae3a8
         killed = 1;
9ae3a8
     }
9ae3a8
     if (t->running_retry) {
9ae3a8
@@ -1730,14 +1727,12 @@ static int xhci_complete_packet(XHCITransfer *xfer)
9ae3a8
         xfer->running_async = 1;
9ae3a8
         xfer->running_retry = 0;
9ae3a8
         xfer->complete = 0;
9ae3a8
-        xfer->cancelled = 0;
9ae3a8
         return 0;
9ae3a8
     } else if (xfer->packet.status == USB_RET_NAK) {
9ae3a8
         trace_usb_xhci_xfer_nak(xfer);
9ae3a8
         xfer->running_async = 0;
9ae3a8
         xfer->running_retry = 1;
9ae3a8
         xfer->complete = 0;
9ae3a8
-        xfer->cancelled = 0;
9ae3a8
         return 0;
9ae3a8
     } else {
9ae3a8
         xfer->running_async = 0;
9ae3a8
-- 
9ae3a8
1.8.3.1
9ae3a8