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: <538578A2.7060600@linaro.org>
Date:	Wed, 28 May 2014 13:48:18 +0800
From:	zhangfei <zhangfei.gao@...aro.org>
To:	Tobias Klauser <tklauser@...tanz.ch>
CC:	davem@...emloft.net, arnd@...db.de, f.fainelli@...il.com,
	sergei.shtylyov@...entembedded.com, mark.rutland@....com,
	David.Laight@...LAB.COM, eric.dumazet@...il.com,
	haifeng.yan@...aro.org, jchxue@...il.com,
	linux-arm-kernel@...ts.infradead.org, netdev@...r.kernel.org,
	devicetree@...r.kernel.org
Subject: Re: [PATCH v2 2/2] net: hisilicon: add hix5hd2 mac driver



On 05/27/2014 09:02 PM, Tobias Klauser wrote:
> On 2014-05-27 at 14:44:27 +0200, Zhangfei Gao <zhangfei.gao@...aro.org> wrote:
>
>> +static struct net_device_stats *hix5hd2_net_get_stats(struct net_device *dev)
>> +{
>> +	return &dev->stats;
>> +}
>
> This function can be omitted, since it corresponds to the default
> behavior if neither .ndo_get_stats or .ndo_get_stats64 is set.
>
>> +
>> +static const struct net_device_ops hix5hd2_netdev_ops = {
>> +	.ndo_open		= hix5hd2_net_open,
>> +	.ndo_stop		= hix5hd2_net_close,
>> +	.ndo_start_xmit		= hix5hd2_net_xmit,
>> +	.ndo_tx_timeout		= hix5hd2_net_timeout,
>> +	.ndo_set_mac_address	= hix5hd2_net_set_mac_address,
>> +	.ndo_get_stats		= hix5hd2_net_get_stats,
>
> Thus the line above can then be omitted as well.

Thanks Tobias.

Have double checked dev_get_stats, the .ndo_get_stats can be removed here.
Thanks for the remainder.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ