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:   Tue, 23 Apr 2019 20:40:15 +0200
From:   Andrew Lunn <andrew@...n.ch>
To:     Grygorii Strashko <grygorii.strashko@...com>
Cc:     netdev@...r.kernel.org,
        Ilias Apalodimas <ilias.apalodimas@...aro.org>,
        "David S . Miller" <davem@...emloft.net>,
        Ivan Khoronzhuk <ivan.khoronzhuk@...aro.org>,
        Florian Fainelli <f.fainelli@...il.com>,
        Sekhar Nori <nsekhar@...com>, linux-kernel@...r.kernel.org,
        linux-omap@...r.kernel.org, Murali Karicheri <m-karicheri2@...com>
Subject: Re: [PATCH net-next 05/19] net: ethernet: ti: cpsw: use local var
 dev in probe

>On Tue, Apr 23, 2019 at 04:08:56PM +0300, Grygorii Strashko wrote:
> Use local variable struct device *dev in probe to simplify code.
> 
> Signed-off-by: Grygorii Strashko <grygorii.strashko@...com>
> ---
>  drivers/net/ethernet/ti/cpsw.c | 65 +++++++++++++++++-----------------
>  1 file changed, 33 insertions(+), 32 deletions(-)
> 
> diff --git a/drivers/net/ethernet/ti/cpsw.c b/drivers/net/ethernet/ti/cpsw.c
> index 13a339c64892..0b8cc4e6d9cd 100644
> --- a/drivers/net/ethernet/ti/cpsw.c
> +++ b/drivers/net/ethernet/ti/cpsw.c
> @@ -3458,6 +3458,7 @@ static const struct soc_device_attribute cpsw_soc_devices[] = {
>  
>  static int cpsw_probe(struct platform_device *pdev)
>  {
> +	struct device *dev = &pdev->dev;
>  	struct clk			*clk;
>  	struct cpsw_platform_data	*data;
>  	struct net_device		*ndev;

It seems odd not to keep with the column layout?
Plus it would make it reverse Christmas tree.

     Andrew

Powered by blists - more mailing lists