Skip to contentSkip to conversation

ehci: update irq on reset

PATCH New Gerd Hoffmann 1 participant 1 message Jan 19, 2016

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 ehci: update irq on reset

After clearing the status register we also have to update the irq line status. Otherwise a irq which happends to be pending at reset time causes a interrupt storm. And the guest can't stop as the status register doesn't indicate any pending interrupt.

Both NetBSD and FreeBSD hang on shutdown because of that.

---
 hw/usb/hcd-ehci.c | 1 +
 1 file changed, 1 insertion(+)
hw/usb/hcd-ehci.c +1 -0
index d07f228..d2b7fa2 100644
@@ -865,6 +865,7 @@ void ehci_reset(void *opaque)
     s->usbsts = USBSTS_HALT;
     s->usbsts_pending = 0;
     s->usbsts_frindex = 0;
+    ehci_update_irq(s);
 
     s->astate = EST_INACTIVE;
     s->pstate = EST_INACTIVE;
Signature · 1 line
1.8.3.1