From: Tobias Klauser <tklauser@distanz.ch>
To: netdev@vger.kernel.org
Subject: [PATCH net-next 01/14] net: cxgb: Use net_device_stats from struct net_device
Date: Fri, 7 Apr 2017 10:17:26 +0200 [thread overview]
Message-ID: <20170407081739.5243-2-tklauser@distanz.ch> (raw)
In-Reply-To: <20170407081739.5243-1-tklauser@distanz.ch>
Instead of using a private copy of struct net_device_stats in struct
port_info, use stats from struct net_device.
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
---
drivers/net/ethernet/chelsio/cxgb/common.h | 1 -
drivers/net/ethernet/chelsio/cxgb/cxgb2.c | 2 +-
2 files changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/net/ethernet/chelsio/cxgb/common.h b/drivers/net/ethernet/chelsio/cxgb/common.h
index 6916c62f2487..94b9482f14a5 100644
--- a/drivers/net/ethernet/chelsio/cxgb/common.h
+++ b/drivers/net/ethernet/chelsio/cxgb/common.h
@@ -223,7 +223,6 @@ struct port_info {
struct cmac *mac;
struct cphy *phy;
struct link_config link_config;
- struct net_device_stats netstats;
};
struct sge;
diff --git a/drivers/net/ethernet/chelsio/cxgb/cxgb2.c b/drivers/net/ethernet/chelsio/cxgb/cxgb2.c
index d8aff7a4b3c7..8623be13bf86 100644
--- a/drivers/net/ethernet/chelsio/cxgb/cxgb2.c
+++ b/drivers/net/ethernet/chelsio/cxgb/cxgb2.c
@@ -296,7 +296,7 @@ static struct net_device_stats *t1_get_stats(struct net_device *dev)
{
struct adapter *adapter = dev->ml_priv;
struct port_info *p = &adapter->port[dev->if_port];
- struct net_device_stats *ns = &p->netstats;
+ struct net_device_stats *ns = &dev->stats;
const struct cmac_statistics *pstats;
/* Do a full update of the MAC stats */
--
2.12.2
next prev parent reply other threads:[~2017-04-07 8:17 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-04-07 8:17 [PATCH net-next 00/14] Use net_device_stats from struct net_device Tobias Klauser
2017-04-07 8:17 ` Tobias Klauser [this message]
2017-04-07 8:17 ` [PATCH net-next 02/14] net: cxgb3: " Tobias Klauser
2017-04-07 8:17 ` [PATCH net-next 03/14] net: dl2k: " Tobias Klauser
2017-04-07 8:17 ` [PATCH net-next 04/14] net: emac: " Tobias Klauser
2017-04-07 8:17 ` [PATCH net-next 05/14] net: macb: " Tobias Klauser
2017-04-07 8:29 ` Nicolas Ferre
2017-04-07 8:57 ` Tobias Klauser
2017-04-07 14:08 ` David Miller
2017-04-07 8:17 ` [PATCH net-next 06/14] net: moxa: " Tobias Klauser
2017-04-07 8:17 ` [PATCH net-next 07/14] net: nmlan_cs: " Tobias Klauser
2017-04-07 8:17 ` [PATCH net-next 08/14] net: nuvoton: " Tobias Klauser
2017-04-07 8:17 ` [PATCH net-next 09/14] net: sunbmac: " Tobias Klauser
2017-04-07 8:17 ` [PATCH net-next 10/14] net: sunhme: " Tobias Klauser
2017-04-07 8:17 ` [PATCH net-next 11/14] net: tulip: de2104x: " Tobias Klauser
2017-04-07 8:17 ` [PATCH net-next 12/14] net: typhoon: " Tobias Klauser
[not found] ` <20170407081739.5243-1-tklauser-93Khv+1bN0NyDzI6CaY1VQ@public.gmane.org>
2017-04-07 8:17 ` [PATCH net-next 13/14] usbnet: kaweth: " Tobias Klauser
[not found] ` <20170407081739.5243-14-tklauser-93Khv+1bN0NyDzI6CaY1VQ@public.gmane.org>
2017-04-11 9:15 ` Oliver Neukum
2017-04-07 8:17 ` [PATCH net-next 14/14] usbnet: pegasus: " Tobias Klauser
2017-04-11 8:30 ` Petko Manolov
2017-04-07 14:06 ` [PATCH net-next 00/14] " David Miller
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20170407081739.5243-2-tklauser@distanz.ch \
--to=tklauser@distanz.ch \
--cc=netdev@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.