qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [usb] signal RHSC in ohci_attach
@ 2006-05-22 16:26 Lonnie Mendez
  0 siblings, 0 replies; only message in thread
From: Lonnie Mendez @ 2006-05-22 16:26 UTC (permalink / raw)
  To: qemu-devel

[-- Attachment #1: Type: text/plain, Size: 98 bytes --]

  The attached patch signals root hub status change interrupt for 
attach/detach in ohci_attach.


[-- Attachment #2: qemu-ohci-rhsc.diff --]
[-- Type: text/plain, Size: 551 bytes --]

--- qemu/hw/usb-ohci.c	2006-05-22 11:02:16.000000000 -0500
+++ qemu/hw/usb-ohci.c	2006-05-22 11:22:46.000000000 -0500
@@ -252,6 +252,7 @@
 {
     OHCIState *s = port1->opaque;
     OHCIPort *port = &s->rhport[port1->index];
+    uint32_t old_state = port->ctrl;
 
     if (dev) {
         if (port->port.dev) {
@@ -290,6 +291,9 @@
         port->port.dev = NULL;
         dprintf("usb-ohci: Detached port %d\n", port1->index);
     }
+
+    if (old_state != port->ctrl)
+        ohci_set_interrupt(s, OHCI_INTR_RHSC);
 }
 
 /* Reset the controller */

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2006-05-22 16:26 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-05-22 16:26 [Qemu-devel] [usb] signal RHSC in ohci_attach Lonnie Mendez

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).