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]
Date:   Wed, 5 Oct 2016 13:07:11 +0000
From:   David Laight <David.Laight@...LAB.COM>
To:     'Nelson Chang' <nelson.chang@...iatek.com>,
        "sergei.shtylyov@...entembedded.com" 
        <sergei.shtylyov@...entembedded.com>,
        "john@...ozen.org" <john@...ozen.org>,
        "davem@...emloft.net" <davem@...emloft.net>
CC:     "nbd@...nwrt.org" <nbd@...nwrt.org>,
        "netdev@...r.kernel.org" <netdev@...r.kernel.org>,
        "linux-mediatek@...ts.infradead.org" 
        <linux-mediatek@...ts.infradead.org>,
        "nelsonch.tw@...il.com" <nelsonch.tw@...il.com>
Subject: RE: [PATCH net-next v2 2/3] net: ethernet: mediatek: get hw lro
 capability by the chip id instead of by the dtsi

From: Nelson Chang
> Sent: 05 October 2016 13:46
> > +static bool mtk_is_hwlro_supported(struct mtk_eth *eth) {
> > +     if (eth->chip_id == MT7623_ETH)
> > +             return true;
> > +     else
> > +             return false;
> 
>         return eth->chip_id == MT7623_ETH;
> 
> => Since there will be more chips support hw lro in the future, keep the
> original codes to have the scalability like this:
> if (eth->chip_id == MTxxxx_ETH ||
>     eth->chip_id == MTyyyy_ETH ||
>     ....)
> 	return true;

Nothing wrong with:

	return eth->chip_id == MTxxxx_ETH ||
		eth->chip_id == MTyyyy_ETH;

	David

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ