[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <F4CC6FACFEB3C54C9141D49AD221F7F91A8E7FB5@lhreml503-mbx>
Date: Fri, 31 Mar 2017 16:46:53 +0000
From: Salil Mehta <salil.mehta@...wei.com>
To: Joe Perches <joe@...ches.com>,
"davem@...emloft.net" <davem@...emloft.net>
CC: "Zhuangyuzeng (Yisen)" <yisen.zhuang@...wei.com>,
"mehta.salil.lnk@...il.com" <mehta.salil.lnk@...il.com>,
"netdev@...r.kernel.org" <netdev@...r.kernel.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
Linuxarm <linuxarm@...wei.com>
Subject: RE: [PATCH V2 net-next 18/18] net: hns: Some checkpatch.pl script &
warning fixes
> -----Original Message-----
> From: Joe Perches [mailto:joe@...ches.com]
> Sent: Friday, March 31, 2017 4:45 PM
> To: Salil Mehta; davem@...emloft.net
> Cc: Zhuangyuzeng (Yisen); mehta.salil.lnk@...il.com;
> netdev@...r.kernel.org; linux-kernel@...r.kernel.org; Linuxarm
> Subject: Re: [PATCH V2 net-next 18/18] net: hns: Some checkpatch.pl
> script & warning fixes
>
> On Fri, 2017-03-31 at 12:20 +0100, Salil Mehta wrote:
> > This patch fixes some checkpatch.pl script caught errors and
> > warnings during the compilation time.
> []
> > diff --git a/drivers/net/ethernet/hisilicon/hns/hns_enet.c
> b/drivers/net/ethernet/hisilicon/hns/hns_enet.c
> []
> > @@ -512,7 +512,8 @@ static void hns_nic_reuse_page(struct sk_buff
> *skb, int i,
> > int last_offset;
> > bool twobufs;
> >
> > - twobufs = ((PAGE_SIZE < 8192) && hnae_buf_size(ring) ==
> HNS_BUFFER_SIZE_2048);
> > + twobufs = ((PAGE_SIZE < 8192) && hnae_buf_size(ring)
> > + == HNS_BUFFER_SIZE_2048);
>
> This would read nicer without splitting a comparison test
> onto multiple lines
>
> twobufs = PAGE_SIZE < 8192 &&
> hnae_buf_size(ring) == HNS_BUFFER_SIZE_2048;
For sure, thanks for noticing. Will correct this!
Best regards
Salil
>
Powered by blists - more mailing lists