> > > I have post one patch which may remove the message, see link[2]. > > I don't think sleeping is the right answer. For example, at the same > time as the resume there could be a new device plugged in. > > What we really want to do is prevent the root hub from autosuspending > while the resume signal is active. One possibility is to have the HCD > call pm_runtime_get_noresume. Can you think of anything better? > I also agree with no auto suspend occur during the resume signal is active. But one think I still can't understand that you add usb_autopm_get_interface_no_resume( to_usb_interface(hub->intfdev)); the purpose should be avoid hub's auto-suspend. But why the hub's suspend still occurs after calling it, see below log? -----------------------------------------------LOG---------------------------------------------------- usb usb1: usb wakeup-resume usb usb1: usb auto-resume ci_hdrc ci_hdrc.0: resume root hub hub 1-0:1.0: hub_resume usb usb1: wait for ports resuming over hub 1-0:1.0: port 1: status 0107 change 0000 process hub 1-0:1.0: state 7 ports 1 chg 0000 evt 0000 hub 1-0:1.0: hub_suspend usb usb1: bus auto-suspend, wakeup 1 ci_hdrc ci_hdrc.0: suspend root hub ci_hdrc ci_hdrc.0: suspend failed because a port is resuming usb usb1: bus suspend fail, err -16 hub 1-0:1.0: hub_resume usb usb1: wait for ports resuming over ci_hdrc ci_hdrc.0: GetStatus port:1 status 10001805 8 ACK POWER sig=j PE CONNECT hub 1-0:1.0: port 1: status 0103 change 0004 process hub 1-0:1.0: state 7 ports 1 chg 0002 evt 0000 ci_hdrc ci_hdrc.0: GetStatus port:1 status 10001805 8 ACK POWER sig=j PE CONNECT usb 1-1: usb wakeup-resume usb 1-1: finish resume hub 1-1:1.0: hub_resume -----------------------------------------diff of kick_khubd------------------------------------------------------------------- --- a/drivers/usb/core/hub.c +++ b/drivers/usb/core/hub.c @@ -635,6 +635,12 @@ static void kick_khubd(struct usb_hub *hub) if (!hub->disconnected && list_empty(&hub->event_list)) { list_add_tail(&hub->event_list, &hub_event_list); + if (in_interrupt()) + printk("in_int\n"); + else if (in_irq()) + printk("in_irq\n"); + else + printk("process\n"); /* Suppress autosuspend until khubd runs */ usb_autopm_get_interface_no_resume( to_usb_interface(hub->intfdev)); Peter -- 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