public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-commits] proj/qemu-kvm:qemu-kvm-1.1.2-gentoo commit in: hw/usb/
@ 2013-01-19  3:47 Doug Goldstein
  0 siblings, 0 replies; 3+ messages in thread
From: Doug Goldstein @ 2013-01-19  3:47 UTC (permalink / raw
  To: gentoo-commits

commit:     9abd43ddd30ce5729f69c575de50f363daeee4de
Author:     Hans de Goede <hdegoede <AT> redhat <DOT> com>
AuthorDate: Wed Oct 10 13:50:36 2012 +0000
Commit:     Doug Goldstein <cardoe <AT> gentoo <DOT> org>
CommitDate: Wed Nov 21 21:22:42 2012 +0000
URL:        http://git.overlays.gentoo.org/gitweb/?p=proj/qemu-kvm.git;a=commit;h=9abd43dd

uhci: Raise interrupt when requested even for non active tds

According to the spec we must raise an interrupt when one is requested
even for non active tds.

Linux depends on this, for bulk transfers it runs an inactivity timer
to work around a bug in early uhci revisions, when we take longer then
200 ms to process a packet, this timer goes of, and as part of the
handling Linux then unlinks the qh, and relinks it after the frindex
has increased by atleast 1, the problem is Linux only checks for the
frindex increases on an interrupt, and we don't send that, causing
the qh to go inactive for more then 32 frames, at which point we
consider the packet cancelled.

Signed-off-by: Hans de Goede <hdegoede <AT> redhat.com>
Signed-off-by: Gerd Hoffmann <kraxel <AT> redhat.com>
(cherry picked from commit 883bca776daa43111e9c39008f0038f7c62ae723)

---
 hw/usb/hcd-uhci.c |   10 +++++++++-
 1 files changed, 9 insertions(+), 1 deletions(-)

diff --git a/hw/usb/hcd-uhci.c b/hw/usb/hcd-uhci.c
index 3803f52..a8bb164 100644
--- a/hw/usb/hcd-uhci.c
+++ b/hw/usb/hcd-uhci.c
@@ -806,8 +806,16 @@ static int uhci_handle_td(UHCIState *s, uint32_t addr, UHCI_TD *td,
     USBEndpoint *ep;
 
     /* Is active ? */
-    if (!(td->ctrl & TD_CTRL_ACTIVE))
+    if (!(td->ctrl & TD_CTRL_ACTIVE)) {
+        /*
+         * ehci11d spec page 22: "Even if the Active bit in the TD is already
+         * cleared when the TD is fetched ... an IOC interrupt is generated"
+         */
+        if (td->ctrl & TD_CTRL_IOC) {
+                *int_mask |= 0x01;
+        }
         return TD_RESULT_NEXT_QH;
+    }
 
     async = uhci_async_find_td(s, addr, td);
     if (async) {


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* [gentoo-commits] proj/qemu-kvm:qemu-kvm-1.1.2-gentoo commit in: hw/usb/
@ 2013-01-19  3:47 Doug Goldstein
  0 siblings, 0 replies; 3+ messages in thread
From: Doug Goldstein @ 2013-01-19  3:47 UTC (permalink / raw
  To: gentoo-commits

commit:     f00280ab8e0c4d425bef788c8d0e2653d323130d
Author:     Gerd Hoffmann <kraxel <AT> redhat <DOT> com>
AuthorDate: Fri Jul 13 09:38:13 2012 +0000
Commit:     Doug Goldstein <cardoe <AT> gentoo <DOT> org>
CommitDate: Wed Nov 21 21:24:59 2012 +0000
URL:        http://git.overlays.gentoo.org/gitweb/?p=proj/qemu-kvm.git;a=commit;h=f00280ab

usb-storage: fix SYNCHRONIZE_CACHE

Commit 59310659073d85745854f2f10c4292555c5a1c51 is incomplete,
we'll arrive in the scsi command complete callback in CSW state
and must handle that case correctly.

Signed-off-by: Gerd Hoffmann <kraxel <AT> redhat.com>
(cherry picked from commit 54414218d78c9d043417b27bb29bd0334b4e3cb5)

---
 hw/usb/dev-storage.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)

diff --git a/hw/usb/dev-storage.c b/hw/usb/dev-storage.c
index ae22fb1..3a993d3 100644
--- a/hw/usb/dev-storage.c
+++ b/hw/usb/dev-storage.c
@@ -242,6 +242,9 @@ static void usb_msd_command_complete(SCSIRequest *req, uint32_t status, size_t r
                the status read packet.  */
             usb_msd_send_status(s, p);
             s->mode = USB_MSDM_CBW;
+        } else if (s->mode == USB_MSDM_CSW) {
+            usb_msd_send_status(s, p);
+            s->mode = USB_MSDM_CBW;
         } else {
             if (s->data_len) {
                 int len = (p->iov.size - p->result);


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* [gentoo-commits] proj/qemu-kvm:qemu-kvm-1.1.2-gentoo commit in: hw/usb/
@ 2013-01-19  3:47 Doug Goldstein
  0 siblings, 0 replies; 3+ messages in thread
From: Doug Goldstein @ 2013-01-19  3:47 UTC (permalink / raw
  To: gentoo-commits

commit:     a3af4fdfa20f6815753e18793d6cdd04f641a914
Author:     Gerd Hoffmann <kraxel <AT> redhat <DOT> com>
AuthorDate: Wed Oct 24 14:19:21 2012 +0000
Commit:     Doug Goldstein <cardoe <AT> gentoo <DOT> org>
CommitDate: Wed Nov 21 21:28:51 2012 +0000
URL:        http://git.overlays.gentoo.org/gitweb/?p=proj/qemu-kvm.git;a=commit;h=a3af4fdf

xhci: fix usb name in caps

Used to be "UTB" not "USB".

Signed-off-by: Gerd Hoffmann <kraxel <AT> redhat.com>
(cherry picked from commit 0ebfb144e8ad3f2da436d630fdcc5aa9ab646341)

---
 hw/usb/hcd-xhci.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/hw/usb/hcd-xhci.c b/hw/usb/hcd-xhci.c
index 5cf1a64..10be478 100644
--- a/hw/usb/hcd-xhci.c
+++ b/hw/usb/hcd-xhci.c
@@ -2372,7 +2372,7 @@ static uint32_t xhci_cap_read(XHCIState *xhci, uint32_t reg)
         return 0x02000002; /* USB 2.0 */
 #endif
     case 0x24: /* Supported Protocol:04 */
-        return 0x20425455; /* "USB " */
+        return 0x20425355; /* "USB " */
     case 0x28: /* Supported Protocol:08 */
         return 0x00000001 | (USB2_PORTS<<8);
     case 0x2c: /* Supported Protocol:0c */
@@ -2381,7 +2381,7 @@ static uint32_t xhci_cap_read(XHCIState *xhci, uint32_t reg)
     case 0x30: /* Supported Protocol:00 */
         return 0x03000002; /* USB 3.0 */
     case 0x34: /* Supported Protocol:04 */
-        return 0x20425455; /* "USB " */
+        return 0x20425355; /* "USB " */
     case 0x38: /* Supported Protocol:08 */
         return 0x00000000 | (USB2_PORTS+1) | (USB3_PORTS<<8);
     case 0x3c: /* Supported Protocol:0c */


^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2013-01-19  3:48 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-01-19  3:47 [gentoo-commits] proj/qemu-kvm:qemu-kvm-1.1.2-gentoo commit in: hw/usb/ Doug Goldstein
  -- strict thread matches above, loose matches on Subject: below --
2013-01-19  3:47 Doug Goldstein
2013-01-19  3:47 Doug Goldstein

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox