diff options
author | Rafael J. Wysocki <rafael.j.wysocki@intel.com> | 2013-11-18 19:06:49 -0500 |
---|---|---|
committer | Rafael J. Wysocki <rafael.j.wysocki@intel.com> | 2013-11-18 19:06:49 -0500 |
commit | 77aa26514a3858cabce748fa093d871b5a51d269 (patch) | |
tree | 6625ffc28c4d1eef7f69818964f4e484e92fd3f2 /Documentation | |
parent | 6431b430973c1c6eb2597da1533764cb4f696526 (diff) | |
parent | aa1b9f13b3346352455bfdc343ecff7667b84ff5 (diff) |
Merge branch 'pm-runtime'
* pm-runtime:
PM / Runtime: Fix error path for prepare
PM / Runtime: Update documentation around probe|remove|suspend
Diffstat (limited to 'Documentation')
-rw-r--r-- | Documentation/power/runtime_pm.txt | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/Documentation/power/runtime_pm.txt b/Documentation/power/runtime_pm.txt index 0f54333b0ff2..b6ce00b2be9a 100644 --- a/Documentation/power/runtime_pm.txt +++ b/Documentation/power/runtime_pm.txt | |||
@@ -547,13 +547,11 @@ helper functions described in Section 4. In that case, pm_runtime_resume() | |||
547 | should be used. Of course, for this purpose the device's runtime PM has to be | 547 | should be used. Of course, for this purpose the device's runtime PM has to be |
548 | enabled earlier by calling pm_runtime_enable(). | 548 | enabled earlier by calling pm_runtime_enable(). |
549 | 549 | ||
550 | If the device bus type's or driver's ->probe() callback runs | 550 | It may be desirable to suspend the device once ->probe() has finished. |
551 | pm_runtime_suspend() or pm_runtime_idle() or their asynchronous counterparts, | 551 | Therefore the driver core uses the asyncronous pm_request_idle() to submit a |
552 | they will fail returning -EAGAIN, because the device's usage counter is | 552 | request to execute the subsystem-level idle callback for the device at that |
553 | incremented by the driver core before executing ->probe(). Still, it may be | 553 | time. A driver that makes use of the runtime autosuspend feature, may want to |
554 | desirable to suspend the device as soon as ->probe() has finished, so the driver | 554 | update the last busy mark before returning from ->probe(). |
555 | core uses pm_runtime_put_sync() to invoke the subsystem-level idle callback for | ||
556 | the device at that time. | ||
557 | 555 | ||
558 | Moreover, the driver core prevents runtime PM callbacks from racing with the bus | 556 | Moreover, the driver core prevents runtime PM callbacks from racing with the bus |
559 | notifier callback in __device_release_driver(), which is necessary, because the | 557 | notifier callback in __device_release_driver(), which is necessary, because the |
@@ -656,7 +654,7 @@ out the following operations: | |||
656 | __pm_runtime_disable() with 'false' as the second argument for every device | 654 | __pm_runtime_disable() with 'false' as the second argument for every device |
657 | right before executing the subsystem-level .suspend_late() callback for it. | 655 | right before executing the subsystem-level .suspend_late() callback for it. |
658 | 656 | ||
659 | * During system resume it calls pm_runtime_enable() and pm_runtime_put_sync() | 657 | * During system resume it calls pm_runtime_enable() and pm_runtime_put() |
660 | for every device right after executing the subsystem-level .resume_early() | 658 | for every device right after executing the subsystem-level .resume_early() |
661 | callback and right after executing the subsystem-level .resume() callback | 659 | callback and right after executing the subsystem-level .resume() callback |
662 | for it, respectively. | 660 | for it, respectively. |