]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
3.1 patches
authorGreg Kroah-Hartman <gregkh@suse.de>
Tue, 8 Nov 2011 22:03:04 +0000 (14:03 -0800)
committerGreg Kroah-Hartman <gregkh@suse.de>
Tue, 8 Nov 2011 22:03:04 +0000 (14:03 -0800)
added patches:
crypto-cryptd-use-subsys_initcall-to-prevent-races-with-aesni.patch
pm-suspend-off-by-one-in-pm_suspend.patch

queue-3.1/crypto-cryptd-use-subsys_initcall-to-prevent-races-with-aesni.patch [new file with mode: 0644]
queue-3.1/pm-suspend-off-by-one-in-pm_suspend.patch [new file with mode: 0644]
queue-3.1/series

diff --git a/queue-3.1/crypto-cryptd-use-subsys_initcall-to-prevent-races-with-aesni.patch b/queue-3.1/crypto-cryptd-use-subsys_initcall-to-prevent-races-with-aesni.patch
new file mode 100644 (file)
index 0000000..6a59081
--- /dev/null
@@ -0,0 +1,34 @@
+From b2bac6acf86d05d8af0499f37d91ecac15722803 Mon Sep 17 00:00:00 2001
+From: Herbert Xu <herbert@gondor.apana.org.au>
+Date: Fri, 19 Aug 2011 16:11:23 +0800
+Subject: crypto: cryptd - Use subsys_initcall to prevent races with aesni
+
+From: Herbert Xu <herbert@gondor.apana.org.au>
+
+commit b2bac6acf86d05d8af0499f37d91ecac15722803 upstream.
+
+As cryptd is depeneded on by other algorithms such as aesni-intel,
+it needs to be registered before them.  When everything is built
+as modules, this occurs naturally.  However, for this to work when
+they are built-in, we need to use subsys_initcall in cryptd.
+
+Tested-by: Josh Boyer <jwboyer@redhat.com>
+Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
+Cc: Kerin Millar <kerframil@gmail.com>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+---
+ crypto/cryptd.c |    2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/crypto/cryptd.c
++++ b/crypto/cryptd.c
+@@ -945,7 +945,7 @@ static void __exit cryptd_exit(void)
+       crypto_unregister_template(&cryptd_tmpl);
+ }
+-module_init(cryptd_init);
++subsys_initcall(cryptd_init);
+ module_exit(cryptd_exit);
+ MODULE_LICENSE("GPL");
diff --git a/queue-3.1/pm-suspend-off-by-one-in-pm_suspend.patch b/queue-3.1/pm-suspend-off-by-one-in-pm_suspend.patch
new file mode 100644 (file)
index 0000000..d0fa5be
--- /dev/null
@@ -0,0 +1,33 @@
+From 528f7ce6e439edeac38f6b3f8561f1be129b5e91 Mon Sep 17 00:00:00 2001
+From: Dan Carpenter <dan.carpenter@oracle.com>
+Date: Wed, 21 Sep 2011 20:55:04 +0200
+Subject: PM / Suspend: Off by one in pm_suspend()
+
+From: Dan Carpenter <dan.carpenter@oracle.com>
+
+commit 528f7ce6e439edeac38f6b3f8561f1be129b5e91 upstream.
+
+In enter_state() we use "state" as an offset for the pm_states[]
+array.  The pm_states[] array only has PM_SUSPEND_MAX elements so
+this test is off by one.
+
+Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
+Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
+Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
+
+
+---
+ kernel/power/suspend.c |    2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+--- a/kernel/power/suspend.c
++++ b/kernel/power/suspend.c
+@@ -315,7 +315,7 @@ int enter_state(suspend_state_t state)
+  */
+ int pm_suspend(suspend_state_t state)
+ {
+-      if (state > PM_SUSPEND_ON && state <= PM_SUSPEND_MAX)
++      if (state > PM_SUSPEND_ON && state < PM_SUSPEND_MAX)
+               return enter_state(state);
+       return -EINVAL;
+ }
index 16ddb983f5b0f88a5902823e27245a0aaa3e4010..df35c16e1444b9cf319d5efdb4b110ec235f79ee 100644 (file)
@@ -248,3 +248,5 @@ mtd-mtdchar-add-missing-initializer-on-raw-write.patch
 mtd-provide-an-alias-for-the-redboot-module-name.patch
 mtd-pxa3xx_nand-fix-nand-detection-issue.patch
 mtd-pxa3xx_nand-fix-blank-page-ecc-mismatch.patch
+pm-suspend-off-by-one-in-pm_suspend.patch
+crypto-cryptd-use-subsys_initcall-to-prevent-races-with-aesni.patch