diff options
author | Rafael J. Wysocki <rjw@sisk.pl> | 2012-09-24 07:30:55 -0400 |
---|---|---|
committer | Rafael J. Wysocki <rjw@sisk.pl> | 2012-09-24 07:30:55 -0400 |
commit | 071f58279f274f749c4109aef86d899766014139 (patch) | |
tree | 028e8da9404d88c8deb8d969233f85b2ff883cd0 /drivers/base | |
parent | c26d4114aac55b57078caf83e261621d22e4596d (diff) | |
parent | 6f3c77b040fc24708228607bba504878de5236d1 (diff) |
Merge branch 'pm-runtime'
* pm-runtime:
PM / Runtime: let rpm_resume() succeed if RPM_ACTIVE, even when disabled, v2
Diffstat (limited to 'drivers/base')
-rw-r--r-- | drivers/base/power/runtime.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/base/power/runtime.c b/drivers/base/power/runtime.c index 7d9c1cb1c39a..3148b10dc2e5 100644 --- a/drivers/base/power/runtime.c +++ b/drivers/base/power/runtime.c | |||
@@ -509,6 +509,9 @@ static int rpm_resume(struct device *dev, int rpmflags) | |||
509 | repeat: | 509 | repeat: |
510 | if (dev->power.runtime_error) | 510 | if (dev->power.runtime_error) |
511 | retval = -EINVAL; | 511 | retval = -EINVAL; |
512 | else if (dev->power.disable_depth == 1 && dev->power.is_suspended | ||
513 | && dev->power.runtime_status == RPM_ACTIVE) | ||
514 | retval = 1; | ||
512 | else if (dev->power.disable_depth > 0) | 515 | else if (dev->power.disable_depth > 0) |
513 | retval = -EACCES; | 516 | retval = -EACCES; |
514 | if (retval) | 517 | if (retval) |