Re: Question about expected behavior when PM runtime is disabled

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, 14 Jun 2011, Rafael J. Wysocki wrote:

> > Then you suggest:
> > 
> > 	Call pm_runtime_disable after .suspend;
> > 
> > 	Call pm_runtime_get_noresume and pm_runtime_enable before
> > 	.resume;
> > 
> > 	Call pm_runtime_put_sync after .complete.
> > 
> > Right?
> 
> Yes, that would be resonable IMO.

This turns out to be harder than it looks.  If an error occurs, we may
run the complete callback for devices that never were suspended or
resumed and hence never had their usage_count incremented.  How can we
tell that we need to skip the pm_runtime_put_sync for these devices?

Would it be okay to call pm_runtime_put_sync immediately after the
resume callback instead of after complete?

Alan Stern

_______________________________________________
linux-pm mailing list
linux-pm@xxxxxxxxxxxxxxxxxxxxxxxxxx
https://lists.linux-foundation.org/mailman/listinfo/linux-pm


[Index of Archives]     [Linux ACPI]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [CPU Freq]     [Kernel Newbies]     [Fedora Kernel]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux