module_param: make bool parameters really bool (drivers & misc)
module_param(bool) used to counter-intuitively take an int. In
fddd5201
(mid-2009) we allowed bool or int/unsigned int using a messy
trick.
It's time to remove the int/unsigned int option. For this version
it'll simply give a warning, but it'll break next kernel version.
Acked-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
@@ -31,7 +31,7 @@
|
||||
/* There is only one motion sensor per machine */
|
||||
struct ams ams_info;
|
||||
|
||||
static unsigned int verbose;
|
||||
static bool verbose;
|
||||
module_param(verbose, bool, 0644);
|
||||
MODULE_PARM_DESC(verbose, "Show free falls and shocks in kernel output");
|
||||
|
||||
|
@@ -19,11 +19,11 @@
|
||||
|
||||
#include "ams.h"
|
||||
|
||||
static unsigned int joystick;
|
||||
static bool joystick;
|
||||
module_param(joystick, bool, S_IRUGO);
|
||||
MODULE_PARM_DESC(joystick, "Enable the input class device on module load");
|
||||
|
||||
static unsigned int invert;
|
||||
static bool invert;
|
||||
module_param(invert, bool, S_IWUSR | S_IRUGO);
|
||||
MODULE_PARM_DESC(invert, "Invert input data on X and Y axis");
|
||||
|
||||
|
مرجع در شماره جدید
Block a user