Messages in this thread | | | From | Peter Chen <> | Subject | RE: USB remote wakeup through gpio interrupt | Date | Thu, 6 Mar 2014 06:05:13 +0000 |
| |
> > Hi Peter, > > Thanks for your reply. > > I can use pm_runtime_get in interrupt handler, but i am not getting your > idea of using pm_runtime_put in interrupt handler? >
After your device finishes using usb, it may need to toggle gpio to trigger interrupt, and you can suspend usb at this interrupt handler using pm_runtime_put.
> My device is usb telephony modem, which will give interrupt through gpio > when call comes. so at that time i want to wakeup the usb functionality > as remote wakeup is not working properly. > > will pm_runtime_put suspend the device immidiately or it will not suspend > the device till it is in use? >
It should suspend device immediately if you have not set any timeout value for runtime. You call pm_runtime_put, it means you want to stop using device, the host will stop sending SOF after it finishes suspending bus routine.
Peter
| |