]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
3.0-stable patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 27 Mar 2012 17:34:47 +0000 (10:34 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 27 Mar 2012 17:34:47 +0000 (10:34 -0700)
added patches:
pm-hibernate-enable-usermodehelpers-in-hibernate-error-path.patch

queue-3.0/pm-hibernate-enable-usermodehelpers-in-hibernate-error-path.patch [new file with mode: 0644]
queue-3.0/series

diff --git a/queue-3.0/pm-hibernate-enable-usermodehelpers-in-hibernate-error-path.patch b/queue-3.0/pm-hibernate-enable-usermodehelpers-in-hibernate-error-path.patch
new file mode 100644 (file)
index 0000000..7d5dfbf
--- /dev/null
@@ -0,0 +1,52 @@
+From 05b4877f6a4f1ba4952d1222213d262bf8c132b7 Mon Sep 17 00:00:00 2001
+From: "Srivatsa S. Bhat" <srivatsa.bhat@linux.vnet.ibm.com>
+Date: Fri, 17 Feb 2012 23:39:51 +0100
+Subject: PM / Hibernate: Enable usermodehelpers in hibernate() error path
+
+From: "Srivatsa S. Bhat" <srivatsa.bhat@linux.vnet.ibm.com>
+
+commit 05b4877f6a4f1ba4952d1222213d262bf8c132b7 upstream.
+
+If create_basic_memory_bitmaps() fails, usermodehelpers are not re-enabled
+before returning. Fix this. And while at it, reword the goto labels so that
+they look more meaningful.
+
+Signed-off-by: Srivatsa S. Bhat <srivatsa.bhat@linux.vnet.ibm.com>
+Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ kernel/power/hibernate.c |    7 ++++---
+ 1 file changed, 4 insertions(+), 3 deletions(-)
+
+--- a/kernel/power/hibernate.c
++++ b/kernel/power/hibernate.c
+@@ -623,7 +623,7 @@ int hibernate(void)
+       /* Allocate memory management structures */
+       error = create_basic_memory_bitmaps();
+       if (error)
+-              goto Exit;
++              goto Enable_umh;
+       printk(KERN_INFO "PM: Syncing filesystems ... ");
+       sys_sync();
+@@ -631,7 +631,7 @@ int hibernate(void)
+       error = prepare_processes();
+       if (error)
+-              goto Finish;
++              goto Free_bitmaps;
+       if (hibernation_test(TEST_FREEZER))
+               goto Thaw;
+@@ -663,8 +663,9 @@ int hibernate(void)
+  Thaw:
+       thaw_processes();
+- Finish:
++ Free_bitmaps:
+       free_basic_memory_bitmaps();
++ Enable_umh:
+       usermodehelper_enable();
+  Exit:
+       pm_notifier_call_chain(PM_POST_HIBERNATION);
index 750daf667166db808784671b02655dfbc2ae7036..216eb7d80bd1e818aeb8b57f6a703f6dea113342 100644 (file)
@@ -77,3 +77,4 @@ hwmon-fam15h_power-correct-sign-extension-of-running_avg_capture.patch
 lgdt330x-fix-signedness-error-in-i2c_read_demod_bytes.patch
 pvrusb2-fix-7mhz-8mhz-dvb-t-tuner-support-for-hvr1900-rev-d1f5.patch
 e1000e-avoid-wrong-check-on-tx-hang.patch
+pm-hibernate-enable-usermodehelpers-in-hibernate-error-path.patch