2
0
mirror of https://github.com/edk2-porting/linux-next.git synced 2024-12-18 02:04:05 +08:00

Merge branch 'pm-runtime'

* pm-runtime:
  PM / Runtime: let rpm_resume() succeed if RPM_ACTIVE, even when disabled, v2
This commit is contained in:
Rafael J. Wysocki 2012-09-24 13:30:55 +02:00
commit 071f58279f

View File

@ -509,6 +509,9 @@ static int rpm_resume(struct device *dev, int rpmflags)
repeat:
if (dev->power.runtime_error)
retval = -EINVAL;
else if (dev->power.disable_depth == 1 && dev->power.is_suspended
&& dev->power.runtime_status == RPM_ACTIVE)
retval = 1;
else if (dev->power.disable_depth > 0)
retval = -EACCES;
if (retval)