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: <5550CE4F.2070404@xilinx.com>
Date:	Mon, 11 May 2015 17:44:15 +0200
From:	Michal Simek <michal.simek@...inx.com>
To:	Joe Perches <joe@...ches.com>,
	Michal Simek <michal.simek@...inx.com>,
	Julia Lawall <julia.lawall@...6.fr>
CC:	<linux-kernel@...r.kernel.org>,
	Markus Elfring <elfring@...rs.sourceforge.net>
Subject: Re: [PATCH v2] net: ll_temac: Use one return statement instead of
 two

On 05/11/2015 05:39 PM, Joe Perches wrote:
> On Mon, 2015-05-11 at 17:26 +0200, Michal Simek wrote:
>> On 05/11/2015 04:42 PM, Joe Perches wrote:
>>> On Mon, 2015-05-11 at 16:05 +0200, Michal Simek wrote:
>>>> Use one return statement instead of two to simplify the code.
>>>> Both are returning the same value.
>>>
>>> trivia and FYI:
>>
>> But still correct right?
> 
> Yes.

Does this mean that you have added me your ACK?

>>> I think there are about 100 of these in kernel tree
>>> and I'm not going to submit patches.
>>>
>>> $ grep-2.5.4 -rP --include=*.[ch] -n "^([\t]+)\treturn[ \t]+([A-Za-z0-9\_\>\(\)\.\>\[\]\-]+);\n(\1}\n)?\1return[ \t]+\2;" * | \
>>>   grep -P "^[\w\/\.]+:\d+:"
>>
>> Are you suggesting that someone else should send patches for it?
> 
> I get enough grief for doing style oriented patches,
> so if someone else wants to, sure.

yep - the only reason I have submitted this was that this is the diff in
the xilinx tree compare to mainline and I don't want to simple revert it
because it is correct.

>> I expect that this is something what Julia can check with coccinelle
>> and can be added to scripts folder.
> 
> Maybe true.
> 
> A coccinelle script might be rather more complicated
> than the simpler grep above, but perhaps the script
> could be a bit more complete as it could likely look
> at more code indentation styles.

Julia: Any comment?

Thanks,
Michal
--
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