]> git.ipfire.org Git - thirdparty/kernel/stable-queue.git/commitdiff
3.14-stable patches
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 2 May 2016 18:29:19 +0000 (11:29 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 2 May 2016 18:29:19 +0000 (11:29 -0700)
added patches:
paride-make-verbose-parameter-an-int-again.patch

queue-3.14/paride-make-verbose-parameter-an-int-again.patch [new file with mode: 0644]
queue-3.14/series

diff --git a/queue-3.14/paride-make-verbose-parameter-an-int-again.patch b/queue-3.14/paride-make-verbose-parameter-an-int-again.patch
new file mode 100644 (file)
index 0000000..845396d
--- /dev/null
@@ -0,0 +1,80 @@
+From dec63a4dec2d6d01346fd5d96062e67c0636852b Mon Sep 17 00:00:00 2001
+From: Arnd Bergmann <arnd@arndb.de>
+Date: Tue, 15 Mar 2016 14:53:29 -0700
+Subject: paride: make 'verbose' parameter an 'int' again
+
+From: Arnd Bergmann <arnd@arndb.de>
+
+commit dec63a4dec2d6d01346fd5d96062e67c0636852b upstream.
+
+gcc-6.0 found an ancient bug in the paride driver, which had a
+"module_param(verbose, bool, 0);" since before 2.6.12, but actually uses
+it to accept '0', '1' or '2' as arguments:
+
+  drivers/block/paride/pd.c: In function 'pd_init_dev_parms':
+  drivers/block/paride/pd.c:298:29: warning: comparison of constant '1' with boolean expression is always false [-Wbool-compare]
+   #define DBMSG(msg) ((verbose>1)?(msg):NULL)
+
+In 2012, Rusty did a cleanup patch that also changed the type of the
+variable to 'bool', which introduced what is now a gcc warning.
+
+This changes the type back to 'int' and adapts the module_param() line
+instead, so it should work as documented in case anyone ever cares about
+running the ancient driver with debugging.
+
+Fixes: 90ab5ee94171 ("module_param: make bool parameters really bool (drivers & misc)")
+Signed-off-by: Arnd Bergmann <arnd@arndb.de>
+Rusty Russell <rusty@rustcorp.com.au>
+Cc: Tim Waugh <tim@cyberelk.net>
+Cc: Sudip Mukherjee <sudipm.mukherjee@gmail.com>
+Cc: Jens Axboe <axboe@fb.com>
+Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
+Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
+Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
+
+---
+ drivers/block/paride/pd.c |    4 ++--
+ drivers/block/paride/pt.c |    4 ++--
+ 2 files changed, 4 insertions(+), 4 deletions(-)
+
+--- a/drivers/block/paride/pd.c
++++ b/drivers/block/paride/pd.c
+@@ -126,7 +126,7 @@
+ */
+ #include <linux/types.h>
+-static bool verbose = 0;
++static int verbose = 0;
+ static int major = PD_MAJOR;
+ static char *name = PD_NAME;
+ static int cluster = 64;
+@@ -161,7 +161,7 @@ enum {D_PRT, D_PRO, D_UNI, D_MOD, D_GEO,
+ static DEFINE_MUTEX(pd_mutex);
+ static DEFINE_SPINLOCK(pd_lock);
+-module_param(verbose, bool, 0);
++module_param(verbose, int, 0);
+ module_param(major, int, 0);
+ module_param(name, charp, 0);
+ module_param(cluster, int, 0);
+--- a/drivers/block/paride/pt.c
++++ b/drivers/block/paride/pt.c
+@@ -117,7 +117,7 @@
+ */
+-static bool verbose = 0;
++static int verbose = 0;
+ static int major = PT_MAJOR;
+ static char *name = PT_NAME;
+ static int disable = 0;
+@@ -152,7 +152,7 @@ static int (*drives[4])[6] = {&drive0, &
+ #include <asm/uaccess.h>
+-module_param(verbose, bool, 0);
++module_param(verbose, int, 0);
+ module_param(major, int, 0);
+ module_param(name, charp, 0);
+ module_param_array(drive0, int, NULL, 0);
index 32833b169b470216f3a05f494064ae9da7497b5e..5a83e2419c1dc778b78113d503fa91bf7cb513c6 100644 (file)
@@ -19,3 +19,4 @@ asoc-rt5640-correct-the-digital-interface-data-select.patch
 efi-fix-out-of-bounds-read-in-variable_matches.patch
 workqueue-fix-ghost-pending-flag-while-doing-mq-io.patch
 usb-usbip-fix-potential-out-of-bounds-write.patch
+paride-make-verbose-parameter-an-int-again.patch