summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRafael J. Wysocki <rjw@sisk.pl>2009-12-03 20:21:21 +0100
committerGreg Kroah-Hartman <gregkh@suse.de>2009-12-18 14:03:10 -0800
commit7f112f35f0da073a10d4d3bfdfcef2955555e4f7 (patch)
treef2af74f4ec1f058e7b4c450a3d38177dd7428f02
parent9f3bb2b1e8f891b008ab3d74d789444cab5ef695 (diff)
downloadlwn-7f112f35f0da073a10d4d3bfdfcef2955555e4f7.tar.gz
lwn-7f112f35f0da073a10d4d3bfdfcef2955555e4f7.zip
PM / Runtime: Fix lockdep warning in __pm_runtime_set_status()
commit bab636b921017f0db6e0c2979438f50b898a9808 upstream. Lockdep complains about taking the parent lock in __pm_runtime_set_status(), so mark it as nested. Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl> Reported-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
-rw-r--r--drivers/base/power/runtime.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/base/power/runtime.c b/drivers/base/power/runtime.c
index 846d89e3d122..0a4b75f834c0 100644
--- a/drivers/base/power/runtime.c
+++ b/drivers/base/power/runtime.c
@@ -777,7 +777,7 @@ int __pm_runtime_set_status(struct device *dev, unsigned int status)
}
if (parent) {
- spin_lock(&parent->power.lock);
+ spin_lock_nested(&parent->power.lock, SINGLE_DEPTH_NESTING);
/*
* It is invalid to put an active child under a parent that is