Skip to content

Commit

Permalink
Merge branch 'pm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/…
Browse files Browse the repository at this point in the history
…git/rafael/suspend-2.6

* 'pm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/suspend-2.6:
  PM: fix irq enable/disable in runtime PM code
  • Loading branch information
Linus Torvalds committed Nov 30, 2009
2 parents f8a2cee + 862f89b commit 432983d
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions drivers/base/power/runtime.c
Original file line number Diff line number Diff line change
Expand Up @@ -328,11 +328,11 @@ int __pm_runtime_resume(struct device *dev, bool from_wq)
* necessary.
*/
parent = dev->parent;
spin_unlock_irq(&dev->power.lock);
spin_unlock(&dev->power.lock);

pm_runtime_get_noresume(parent);

spin_lock_irq(&parent->power.lock);
spin_lock(&parent->power.lock);
/*
* We can resume if the parent's run-time PM is disabled or it
* is set to ignore children.
Expand All @@ -343,9 +343,9 @@ int __pm_runtime_resume(struct device *dev, bool from_wq)
if (parent->power.runtime_status != RPM_ACTIVE)
retval = -EBUSY;
}
spin_unlock_irq(&parent->power.lock);
spin_unlock(&parent->power.lock);

spin_lock_irq(&dev->power.lock);
spin_lock(&dev->power.lock);
if (retval)
goto out;
goto repeat;
Expand Down Expand Up @@ -777,7 +777,7 @@ int __pm_runtime_set_status(struct device *dev, unsigned int status)
}

if (parent) {
spin_lock_irq(&parent->power.lock);
spin_lock(&parent->power.lock);

/*
* It is invalid to put an active child under a parent that is
Expand All @@ -793,7 +793,7 @@ int __pm_runtime_set_status(struct device *dev, unsigned int status)
atomic_inc(&parent->power.child_count);
}

spin_unlock_irq(&parent->power.lock);
spin_unlock(&parent->power.lock);

if (error)
goto out;
Expand Down

0 comments on commit 432983d

Please sign in to comment.