Re: how to know how long it takes on suspend/resume for platform usb driver
From: loody <hidden>
Date: 2014-02-20 06:09:58
hi all: 2014-01-06 23:10 GMT+08:00 Alan Stern [off-list ref]:
On Mon, 6 Jan 2014, loody wrote:quoted
quoted
quoted
2. is it possible to change the order of calling resume callback? for example, suppose the original sequence is "ehci -> xhci -> tty ..." and I want to change as "tty-> ehci -> xhci".It is possible only to a very limited extent. You can turn async suspend/resume on or off, and this will affect the order. Of course, when async suspend/resume is off, the total time required will be longer than when it is on. Why do you want to change the order? It shouldn't make any difference.Because I want the GUI and input part of driver resume as earlier as possible. Such that user can keep on their previous work more quicker.I doubt it will make any noticeable difference. Remember, userspace remains frozen until _all_ the devices have been resumed. Until that happens, the user can't do anything.
after tracing the kernel src, I found the usb resume call back is called in drivers/base/power/main.c -> dpm_resume. is that the only way usb resume functions could be called? if resume has bottom half mechanism, is it possible to put usb resume function at there in stead of first beginning resume step? thanks for your help, -- Regards,