From: Heiner Kallweit <hkallweit1@gmail.com> To: Roopa Prabhu <roopa@nvidia.com>, Nikolay Aleksandrov <nikolay@nvidia.com>, David Miller <davem@davemloft.net>, Jakub Kicinski <kuba@kernel.org> Cc: "netdev@vger.kernel.org" <netdev@vger.kernel.org>, bridge@lists.linux-foundation.org Subject: [PATCH net] net: bridge: add missing counters to ndo_get_stats64 callback Date: Fri, 13 Nov 2020 10:27:27 +0100 [thread overview] Message-ID: <58ea9963-77ad-a7cf-8dfd-fc95ab95f606@gmail.com> (raw) In br_forward.c and br_input.c fields dev->stats.tx_dropped and dev->stats.multicast are populated, but they are ignored in ndo_get_stats64. Fixes: 28172739f0a2 ("net: fix 64 bit counters on 32 bit arches") Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com> --- Patch will not apply cleanly on kernel versions that don't have dev_fetch_sw_netstats() yet. --- net/bridge/br_device.c | 1 + 1 file changed, 1 insertion(+) diff --git a/net/bridge/br_device.c b/net/bridge/br_device.c index 387403931..77bcc8487 100644 --- a/net/bridge/br_device.c +++ b/net/bridge/br_device.c @@ -207,6 +207,7 @@ static void br_get_stats64(struct net_device *dev, { struct net_bridge *br = netdev_priv(dev); + netdev_stats_to_stats64(stats, &dev->stats); dev_fetch_sw_netstats(stats, br->stats); } -- 2.29.2
WARNING: multiple messages have this Message-ID (diff)
From: Heiner Kallweit <hkallweit1@gmail.com> To: Roopa Prabhu <roopa@nvidia.com>, Nikolay Aleksandrov <nikolay@nvidia.com>, David Miller <davem@davemloft.net>, Jakub Kicinski <kuba@kernel.org> Cc: "netdev@vger.kernel.org" <netdev@vger.kernel.org>, bridge@lists.linux-foundation.org Subject: [Bridge] [PATCH net] net: bridge: add missing counters to ndo_get_stats64 callback Date: Fri, 13 Nov 2020 10:27:27 +0100 [thread overview] Message-ID: <58ea9963-77ad-a7cf-8dfd-fc95ab95f606@gmail.com> (raw) In br_forward.c and br_input.c fields dev->stats.tx_dropped and dev->stats.multicast are populated, but they are ignored in ndo_get_stats64. Fixes: 28172739f0a2 ("net: fix 64 bit counters on 32 bit arches") Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com> --- Patch will not apply cleanly on kernel versions that don't have dev_fetch_sw_netstats() yet. --- net/bridge/br_device.c | 1 + 1 file changed, 1 insertion(+) diff --git a/net/bridge/br_device.c b/net/bridge/br_device.c index 387403931..77bcc8487 100644 --- a/net/bridge/br_device.c +++ b/net/bridge/br_device.c @@ -207,6 +207,7 @@ static void br_get_stats64(struct net_device *dev, { struct net_bridge *br = netdev_priv(dev); + netdev_stats_to_stats64(stats, &dev->stats); dev_fetch_sw_netstats(stats, br->stats); } -- 2.29.2
next reply other threads:[~2020-11-13 9:27 UTC|newest] Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top 2020-11-13 9:27 Heiner Kallweit [this message] 2020-11-13 9:27 ` [Bridge] [PATCH net] net: bridge: add missing counters to ndo_get_stats64 callback Heiner Kallweit 2020-11-16 23:50 ` Jakub Kicinski 2020-11-16 23:50 ` [Bridge] " Jakub Kicinski
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=58ea9963-77ad-a7cf-8dfd-fc95ab95f606@gmail.com \ --to=hkallweit1@gmail.com \ --cc=bridge@lists.linux-foundation.org \ --cc=davem@davemloft.net \ --cc=kuba@kernel.org \ --cc=netdev@vger.kernel.org \ --cc=nikolay@nvidia.com \ --cc=roopa@nvidia.com \ /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: linkBe 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.