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: <11395630.65iIH9RknS@localhost.localdomain>
Date:   Mon, 2 Mar 2020 18:11:41 +0000
From:   <Tudor.Ambarus@...rochip.com>
To:     <j.neuschaefer@....net>
CC:     <linux-mtd@...ts.infradead.org>, <miquel.raynal@...tlin.com>,
        <richard@....at>, <vigneshr@...com>, <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH v2] mtd: spi-nor: Refactor spi_nor_read_id()

On Sunday, February 23, 2020 7:37:13 PM EET Jonathan Neuschäfer wrote:
> EXTERNAL EMAIL: Do not click links or open attachments unless you know the
> content is safe
> 
> - Don't use `tmp` for two purposes (return value, loop counter).
>   Instead, use `i` for the loop counter, and `ret` for the return value.
> - Don't use tabs between type and name in variable declarations,
>   for consistency with other functions in spi-nor.c.
> - Rewrite nested `if`s as `if (a && b)`.
> - Remove `info` variable, and use spi_nor_ids[i] directly.
> 
> Signed-off-by: Jonathan Neuschäfer <j.neuschaefer@....net>
> ---
> 
> v2:
> - As suggested by Tudor Ambarus:
>   - rename tmp to ret
>   - remove tabs between variable type and name
>   - remove `info` variable
> 
> v1:
> - https://lore.kernel.org/lkml/20200218151034.24744-1-j.neuschaefer@gmx.net/
> ---
>  drivers/mtd/spi-nor/spi-nor.c | 25 +++++++++++--------------
>  1 file changed, 11 insertions(+), 14 deletions(-)
> 

Changed i's type from int to unsigned int, reordered local variables and 
applied to spi-nor/next. Thanks,
ta

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ