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]
Message-ID: <B0A7AF226B49A14897036E9B3A68CFFECB1AB0F77D@HQ-EXCH-7.corp.brocade.com>
Date:	Thu, 24 Sep 2009 10:38:53 -0700
From:	Jing Huang <huangj@...cade.COM>
To:	Daniel Walker <dwalker@...o99.com>
CC:	"James.Bottomley@...senPartnership.com" 
	<James.Bottomley@...senPartnership.com>,
	Krishna Gudipati <kgudipat@...cade.com>,
	"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
	"linux-scsi@...r.kernel.org" <linux-scsi@...r.kernel.org>,
	Ramkumar Vadivelu <rvadivel@...cade.COM>,
	Vinodh Ravindran <vravindr@...cade.COM>
Subject: RE: [PATCH 2/14] bfa: Brocade BFA FC SCSI driver (bfa1)

> On Wed, 2009-09-23 at 17:49 -0700, Jing Huang wrote:
> > +
> > +       return (*(union bfi_addr_u *) &addr);
> > +}
> 
> Have you run checkpatch on this code? It produces many errors due to
> your "return" usage for one.. The usual style of return is not to use
> parentheses since it's really not a function ..
> 
> The line I quoted above gives the following error,
> 
> ERROR: return is not a function, parentheses are not required
> #266: FILE: drivers/scsi/bfa/bfa_cb_ioim_macros.h:132:
> +       return (*(union bfi_addr_u *) &addr);
> 
> First of all I'd consider making your code consistent with respect to
> the return statements .. I noticed that you sometimes use the
> parentheses sometimes not .. Since it's more with Linux style I'd just
> remove all the extra parentheses..
> 
> Checkpatch produces many other errors in your code .. If you haven't
> already evaluated those errors, I'd do go through each patch and review
> the errors (and the warnings) that it produces since checkpatch can give
> you a fairly mechanical view into how well your code matches the Linux
> coding style. The less the output from checkpatch the better ..
> 
> Daniel
> 

Hi Daniel, 

I did run checkpatch.pl and it didn't report any ERROR or WARNING. Do you use any specific flags?

Thanks

Jing
--
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