summaryrefslogtreecommitdiffstats
path: root/recipes-kernel/linux/linux-ti33x-psp-3.2/3.2.22/0036-PM-Sleep-Prevent-waiting-forever-on-asynchronous-sus.patch
diff options
context:
space:
mode:
authorKoen Kooi <koen@dominion.thruhere.net>2012-07-17 09:23:14 +0200
committerDenys Dmytriyenko <denys@ti.com>2012-07-31 15:49:41 -0400
commitf95b2e51ea8194b82d2476b338610782a83ce4de (patch)
tree4247f78cc4cd7a203fa3ffb6ae1712388470e79e /recipes-kernel/linux/linux-ti33x-psp-3.2/3.2.22/0036-PM-Sleep-Prevent-waiting-forever-on-asynchronous-sus.patch
parentced11b612173e112f981fa99612a8c6f6f399cfb (diff)
downloadmeta-ti-f95b2e51ea8194b82d2476b338610782a83ce4de.tar.gz
linux-ti33x-psp 3.2: update to 3.2.23
Regenerate all beaglebone patches and add one vfs tracer patch for powertop Signed-off-by: Koen Kooi <koen@dominion.thruhere.net> Signed-off-by: Denys Dmytriyenko <denys@ti.com>
Diffstat (limited to 'recipes-kernel/linux/linux-ti33x-psp-3.2/3.2.22/0036-PM-Sleep-Prevent-waiting-forever-on-asynchronous-sus.patch')
-rw-r--r--recipes-kernel/linux/linux-ti33x-psp-3.2/3.2.22/0036-PM-Sleep-Prevent-waiting-forever-on-asynchronous-sus.patch62
1 files changed, 62 insertions, 0 deletions
diff --git a/recipes-kernel/linux/linux-ti33x-psp-3.2/3.2.22/0036-PM-Sleep-Prevent-waiting-forever-on-asynchronous-sus.patch b/recipes-kernel/linux/linux-ti33x-psp-3.2/3.2.22/0036-PM-Sleep-Prevent-waiting-forever-on-asynchronous-sus.patch
new file mode 100644
index 00000000..0426542c
--- /dev/null
+++ b/recipes-kernel/linux/linux-ti33x-psp-3.2/3.2.22/0036-PM-Sleep-Prevent-waiting-forever-on-asynchronous-sus.patch
@@ -0,0 +1,62 @@
1From 148576d5144418385e4a0d59c5c9547d662ae0f2 Mon Sep 17 00:00:00 2001
2From: Mandeep Singh Baines <msb@chromium.org>
3Date: Sun, 24 Jun 2012 23:31:09 +0200
4Subject: [PATCH 36/46] PM / Sleep: Prevent waiting forever on asynchronous
5 suspend after abort
6
7commit 1f758b23177d588a71b96ad02990e715949bb82f upstream.
8
9__device_suspend() must always send a completion. Otherwise, parent
10devices will wait forever.
11
12Commit 1e2ef05b, "PM: Limit race conditions between runtime PM and
13system sleep (v2)", introduced a regression by short-circuiting the
14complete_all() for certain error cases.
15
16This patch fixes the bug by always signalling a completion.
17
18Addresses http://crosbug.com/31972
19
20Tested by injecting an abort.
21
22Signed-off-by: Mandeep Singh Baines <msb@chromium.org>
23Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
24Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
25---
26 drivers/base/power/main.c | 6 ++++--
27 1 file changed, 4 insertions(+), 2 deletions(-)
28
29diff --git a/drivers/base/power/main.c b/drivers/base/power/main.c
30index c3d2dfc..b96544a 100644
31--- a/drivers/base/power/main.c
32+++ b/drivers/base/power/main.c
33@@ -869,7 +869,7 @@ static int __device_suspend(struct device *dev, pm_message_t state, bool async)
34 dpm_wait_for_children(dev, async);
35
36 if (async_error)
37- return 0;
38+ goto Complete;
39
40 pm_runtime_get_noresume(dev);
41 if (pm_runtime_barrier(dev) && device_may_wakeup(dev))
42@@ -878,7 +878,7 @@ static int __device_suspend(struct device *dev, pm_message_t state, bool async)
43 if (pm_wakeup_pending()) {
44 pm_runtime_put_sync(dev);
45 async_error = -EBUSY;
46- return 0;
47+ goto Complete;
48 }
49
50 device_lock(dev);
51@@ -926,6 +926,8 @@ static int __device_suspend(struct device *dev, pm_message_t state, bool async)
52 }
53
54 device_unlock(dev);
55+
56+ Complete:
57 complete_all(&dev->power.completion);
58
59 if (error) {
60--
611.7.10
62