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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <2f6dfc4920694035bf630fccc4f3a943@realtek.com>
Date: Thu, 13 Jun 2024 03:16:27 +0000
From: Justin Lai <justinlai0215@...ltek.com>
To: Jakub Kicinski <kuba@...nel.org>
CC: "davem@...emloft.net" <davem@...emloft.net>,
        "edumazet@...gle.com"
	<edumazet@...gle.com>,
        "pabeni@...hat.com" <pabeni@...hat.com>,
        "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
        "netdev@...r.kernel.org" <netdev@...r.kernel.org>,
        "andrew@...n.ch"
	<andrew@...n.ch>,
        "jiri@...nulli.us" <jiri@...nulli.us>,
        "horms@...nel.org"
	<horms@...nel.org>,
        "rkannoth@...vell.com" <rkannoth@...vell.com>,
        "Ping-Ke
 Shih" <pkshih@...ltek.com>,
        Larry Chiu <larry.chiu@...ltek.com>
Subject: RE: [PATCH net-next v20 08/13] rtase: Implement net_device_ops

> On Fri, 7 Jun 2024 16:43:16 +0800 Justin Lai wrote:
> > +static void rtase_get_stats64(struct net_device *dev,
> > +                           struct rtnl_link_stats64 *stats) {
> > +     const struct rtase_private *tp = netdev_priv(dev);
> > +     const struct rtase_counters *counters;
> > +
> > +     counters = tp->tally_vaddr;
> > +
> > +     if (!counters)
> > +             return;
> 
> Same question about how this can be null as in the ethtool patch..

This check seems unnecessary, I will remove it.

> 
> > +     netdev_stats_to_stats64(stats, &dev->stats);
> 
> Please dont use this field, there is a comment on it:
> 
>         struct net_device_stats stats; /* not used by modern drivers */
> 
> You can store the fields you need for counters in struct rtase_private

Ok, I will remove all parts that use struct net_device_stats stats.

> 
> > +     dev_fetch_sw_netstats(stats, dev->tstats);

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ