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] [day] [month] [year] [list]
Message-ID: <20140727174049.GA5580@ubuntu>
Date:	Sun, 27 Jul 2014 19:40:49 +0200
From:	Nicolas Thery <nthery@...il.com>
To:	Greg KH <gregkh@...uxfoundation.org>
Cc:	Joe Perches <joe@...ches.com>, marek.belisko@...il.com,
	devel@...verdev.osuosl.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] staging: ft1000: fix some checkpatch complaints

On Sun, Jul 27, 2014 at 10:35:38AM -0700, Greg KH wrote:
> On Sun, Jul 27, 2014 at 10:23:53AM -0700, Joe Perches wrote:
> > On Sun, 2014-07-27 at 19:08 +0200, Nicolas Thery wrote:
> > > This patch fixes the following errors and warnings:
> > []
> > > diff --git a/drivers/staging/ft1000/ft1000-pcmcia/ft1000_proc.c b/drivers/staging/ft1000/ft1000-pcmcia/ft1000_proc.c
> > []
> > > @@ -23,34 +23,38 @@
> > []
> > > -#define seq_putx(m, message, size, var) \
> > > +#define seq_putx(m, message, size, var) do { \
> > >  	seq_printf(m, message);	\
> > >  	for (i = 0; i < (size - 1); i++) { \
> > >  		seq_printf(m, "%02x:", var[i]); \
> > >  	} \
> > > -	seq_printf(m, "%02x\n", var[i])
> > > +	seq_printf(m, "%02x\n", var[i]); \
> > > +} while (0)
> > 
> > Ideally, these wouldn't depend on an external
> > i variable.
> > 
> > Maybe something like:
> > 
> > #define seq_putx(m, message, size, var) \
> > do { \
> > 	int _i; \
> >  	seq_printf(m, message);	\
> >  	for (_i = 0; _i < (size - 1); _i++) \
> >  		seq_printf(m, "%02x:", var[_i]); \
> > 	seq_printf(m, "%02x\n", var[_i]); \
> > } while (0)
> >  
> > > -#define seq_putd(m, message, size, var) \
> > > +#define seq_putd(m, message, size, var) do { \
> > >  	seq_printf(m, message); \
> > >  	for (i = 0; i < (size - 1); i++) { \
> > >  		seq_printf(m, "%d.", var[i]); \
> > >  	} \
> > > -	seq_printf(m, "%d\n", var[i])
> > > +	seq_printf(m, "%d\n", var[i]); \
> > > +} while (0)
> > 
> > Maybe later change these to use the recently introduced
> > seq_hex_dump: https://lkml.org/lkml/2014/7/11/269
> > 
> 
> How about removing the proc files entirely, as I doubt they are really
> needed :)

Okay.  I'll do this.

Thanks to both of you for the review.
--
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