Skip to contentSkip to conversation

usb-hub: clear suspend on detach

PATCH New Gerd Hoffmann 1 participant 1 message Sep 12, 2018

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 usb-hub: clear suspend on detach

---
 hw/usb/dev-hub.c | 4 ++++
 1 file changed, 4 insertions(+)
hw/usb/dev-hub.c +4 -0
index 5d9743ef93..dc368179d1 100644
@@ -191,6 +191,10 @@ static void usb_hub_detach(USBPort *port1)
         port->wPortStatus &= ~PORT_STAT_ENABLE;
         port->wPortChange |= PORT_STAT_C_ENABLE;
     }
+    if (port->wPortStatus & PORT_STAT_SUSPEND) {
+        port->wPortStatus &= ~PORT_STAT_SUSPEND;
+        port->wPortChange |= PORT_STAT_C_SUSPEND;
+    }
     usb_wakeup(s->intr, 0);
 }
 
Signature · 1 line
2.9.3