lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Tue, 26 Oct 2010 16:25:31 -0700
From:	Joe Perches <joe@...ches.com>
To:	Dmitry Torokhov <dmitry.torokhov@...il.com>
Cc:	Jiri Kosina <trivial@...nel.org>, linux-input@...r.kernel.org,
	linux-kernel@...r.kernel.org
Subject: Re: [PATCH 06/10] drivers/input/serio/i8042: Use pr_<level>,
 pr_fmt. Fix dbg and __FILE__ use

On Tue, 2010-10-26 at 08:50 -0700, Dmitry Torokhov wrote:
> Hi Joe,

Hi Dmitry.

> On Mon, Oct 25, 2010 at 07:44:24PM -0700, Joe Perches wrote:
> > Standardized message logging prefixes.
> > Removed \n from dbg macro, added \n to each dbg call site.
> Did you test it? It looks for call like:
> > +             dbg("%02x <- i8042 (flush, %s)\n",
> > +                 data, str & I8042_STR_AUXDATA ? "aux" : "kbd");
> the result will be:
> printk(KERN_DEBUG "i8042: %02x <- i8042 (flush, %s)\n [%d]", ...)
> which is not exactly what you want...

Right.  My mistake.
I compile tested only and didn't notice the badly formed string.

Mind if I move the time to the front like this?

+#define dbg(format, arg...)                                            \
+do {									\
+	if (i8042_debug)						\
+		printk(KERN_DEBUG KBUILD_MODNAME ": [%d]" format),	\
+                      (int)(jiffies - i8042_start_time), ##arg);	\
+} while (0)

> >  
> > @@ -1268,7 +1262,7 @@ static void __init i8042_register_ports(void)
> >  
> >  	for (i = 0; i < I8042_NUM_PORTS; i++) {
> >  		if (i8042_ports[i].serio) {
> > -			printk(KERN_INFO "serio: %s at %#lx,%#lx irq %d\n",
> > +			pr_info("%s at %#lx,%#lx irq %d\n",
> >  				i8042_ports[i].serio->name,
> >  				(unsigned long) I8042_DATA_REG,
> >  				(unsigned long) I8042_COMMAND_REG,
> 
> Not quite equivalent conversion, right now every port is registered with
> message "serio: XXX at YYY". I would be OK with having driver prefix
> going in front but I'd like to keep word serio in (like "i8042: serio
> XXX at YYY").

I'll resubmit a pr_<level> series for drivers/input/serio
today/tomorrow with this change.

cheers, Joe

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ