USB autosuspend suspends vhci_hcd. In this process hcd_bus_suspend gets executed which puts vhci_hcd in suspend state and calls vhci_hub_status. vhci_hub_status function checks hub state and if it is in suspend state, usb_hcd_resume_root_hub gets executed which resumes hub and if hub is idle, again autosuspend puts it in suspend state and this goes on. vhci_hub_status should resume hub only when hub port is in suspend state and hub port status has changed. Signed-off-by: navin patidar <navinp@xxxxxxx> --- drivers/staging/usbip/vhci_hcd.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/usbip/vhci_hcd.c b/drivers/staging/usbip/vhci_hcd.c index 12a9a5f..6076f42 100644 --- a/drivers/staging/usbip/vhci_hcd.c +++ b/drivers/staging/usbip/vhci_hcd.c @@ -220,7 +220,7 @@ static int vhci_hub_status(struct usb_hcd *hcd, char *buf) pr_info("changed %d\n", changed); - if (hcd->state == HC_STATE_SUSPENDED) + if ((hcd->state == HC_STATE_SUSPENDED) && (changed == 1)) usb_hcd_resume_root_hub(hcd); done: -- 1.7.9.5 ------------------------------------------------------------------------------------------------------------------------------- This e-mail is for the sole use of the intended recipient(s) and may contain confidential and privileged information. If you are not the intended recipient, please contact the sender by reply e-mail and destroy all copies and the original message. Any unauthorized review, use, disclosure, dissemination, forwarding, printing or copying of this email is strictly prohibited and appropriate legal action will be taken. ------------------------------------------------------------------------------------------------------------------------------- -- To unsubscribe from this list: send the line "unsubscribe linux-usb" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html