On Thu, 2015-06-25 at 15:25 -0400, cpaul@xxxxxxxxxx wrote: > From: Stephen Chandler Paul <cpaul@xxxxxxxxxx> > > A big problem with the current i8042 debugging option is that it outputs > data going to and from the keyboard by default. As a result, many dmesg > logs uploaded by users will unintentionally contain sensitive information > such as their password, as such it's probably a good idea not to output > data coming from the keyboard unless specifically enabled by the user. Seems sensible. Coupla trivial bits: > diff --git a/drivers/input/serio/i8042.c b/drivers/input/serio/i8042.c [] > @@ -88,6 +88,23 @@ MODULE_PARM_DESC(nopnp, "Do not use PNP to detect controller settings"); > static bool i8042_debug; > module_param_named(debug, i8042_debug, bool, 0600); > MODULE_PARM_DESC(debug, "Turn i8042 debugging mode on and off"); > + > +static bool i8042_debug_kbd; > +module_param_named(debug_kbd, i8042_debug_kbd, bool, 0600); > +MODULE_PARM_DESC(i8042_kbd, "Turn i8042 kbd debugging output on or off"); It's unclear this depends on i8042_debug. Maybe add something like " (enabling requires i8042_debug=1)" > +#define str_dbg(str, data, format, args...) \ > + do { \ > + if (!i8042_debug) \ > + break; \ > + \ > + if (str & I8042_STR_AUXDATA || i8042_debug_kbd) \ > + dbg("%02x " format, data, ##args); \ > + else \ > + dbg("** " format, ##args); \ > + } while (0) > +#else > +#define str_dbg(str, data, format, args...) do { } while (0) > #endif This should probably go into i8042.h where the dbg macro is #defined -- To unsubscribe from this list: send the line "unsubscribe linux-input" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html