On Wed, 5 Mar 2014, Poulain, Loic wrote:

> + function 'do_rebind_interface' is in charge of unbind and rebind the 
> interfaces with the 'need_binfind' flag set.
> + However this method is only called in 'usb_resume_complete'.
> + Problem is that 'usb_resume_complete' is a dev_pm_ops callback (core/usb.h) 
> used by the System PM core which is never called in a runtime PM scenario.
> + So interfaces remain suspended forever (or until the next PM system 
> suspend/resume), device is unusable.
> (unbinding/rebinding manually the interface via sysfs recovers the device)
> 
> Could you please let me know if it's the expected behavior or a real issue. 
> Should we not call 'do_rebind_interface' in the runtime resume sequence?

I suspect this is an oversight.

Still, implementing it would be difficult.  In usb_runtime_resume, the 
device lock may or may not already be held.  Therefore we cannot simply 
lock the device and call do_rebind_interfaces.

Using a work queue for this seems like overkill (and it seems fragile).  
I don't know what we should do.

Alan Stern

--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to