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:	Fri, 15 Jun 2007 12:26:03 +0100
From:	Keir Fraser <Keir.Fraser@...cam.ac.uk>
To:	Kieran Mansley <kmansley@...arflare.com>,
	<xen-devel@...ts.xensource.com>
CC:	<netdev@...r.kernel.org>, <herbert@...dor.apana.org.au>
Subject: Re: [Xen-devel] [PATCH 0/4] [Net] Support accelerated network
 plugin modules

On 15/6/07 11:46, "Kieran Mansley" <kmansley@...arflare.com> wrote:

> This is a repost of some earlier patches to the xen-devel mailing list,
> with a number of changes thanks to some useful suggestions from others.

The coding style needs fixing in various ways.

Hard tabs need to be used, no spaces inside brackets, but should include
spaces between if/while/for and bracket, and bracket and brace:
    if (foo) {
Not
    if( foo ){
    if(foo ) {
Or various other possibilities.

No use of the following please:
If (foo) return 1; else return 0;
Is clearer as:
Return foo;

There's a (good) idiom for error handling in Linux:
If (!error) {
    page of code;
} else {
    oh no, error, print and return;
}
Should be changed to:
If (error) {
    handle error, bail if necessary
}
Page of code, no longer indented by error check;

Apart from the various coding style bits, accelerator_probe_vifs_on_load()
walks the vif_states list with no lock held. Is this safe against the list
changing?

 -- Keir


-
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ