aboutsummaryrefslogtreecommitdiff
path: root/hw/usb/hcd-xhci.c
diff options
context:
space:
mode:
Diffstat (limited to 'hw/usb/hcd-xhci.c')
-rw-r--r--hw/usb/hcd-xhci.c14
1 files changed, 5 insertions, 9 deletions
diff --git a/hw/usb/hcd-xhci.c b/hw/usb/hcd-xhci.c
index 19bbb164e..8dc9986e5 100644
--- a/hw/usb/hcd-xhci.c
+++ b/hw/usb/hcd-xhci.c
@@ -662,8 +662,11 @@ static void xhci_msix_update(XHCIState *xhci)
static void xhci_intr_raise(XHCIState *xhci)
{
- if (!(xhci->iman & IMAN_IP) ||
- !(xhci->iman & IMAN_IE)) {
+ xhci->erdp_low |= ERDP_EHB;
+ xhci->iman |= IMAN_IP;
+ xhci->usbsts |= USBSTS_EINT;
+
+ if (!(xhci->iman & IMAN_IE)) {
return;
}
@@ -784,9 +787,6 @@ static void xhci_events_update(XHCIState *xhci)
}
if (do_irq) {
- xhci->erdp_low |= ERDP_EHB;
- xhci->iman |= IMAN_IP;
- xhci->usbsts |= USBSTS_EINT;
xhci_intr_raise(xhci);
}
@@ -847,10 +847,6 @@ static void xhci_event(XHCIState *xhci, XHCIEvent *event)
xhci_write_event(xhci, event);
}
- xhci->erdp_low |= ERDP_EHB;
- xhci->iman |= IMAN_IP;
- xhci->usbsts |= USBSTS_EINT;
-
xhci_intr_raise(xhci);
}