diff mbox series

[RFC,net-next,16/19] net: dsa: tag_qca: fix doubled Tx statistics

Message ID 20191230143028.27313-17-alobakin@dlink.ru (mailing list archive)
State New, archived
Headers show
Series net: dsa: add GRO support | expand

Commit Message

Alexander Lobakin Dec. 30, 2019, 2:30 p.m. UTC
DSA core updates Tx stats for slaves in dsa_slave_xmit(), no need to do
it manually in .xmit() tagger callback.

Signed-off-by: Alexander Lobakin <alobakin@dlink.ru>
---
 net/dsa/tag_qca.c | 3 ---
 1 file changed, 3 deletions(-)

Comments

Andrew Lunn Dec. 30, 2019, 5:23 p.m. UTC | #1
On Mon, Dec 30, 2019 at 05:30:24PM +0300, Alexander Lobakin wrote:
> DSA core updates Tx stats for slaves in dsa_slave_xmit(), no need to do
> it manually in .xmit() tagger callback.
> 
> Signed-off-by: Alexander Lobakin <alobakin@dlink.ru>

Reviewed-by: Andrew Lunn <andrew@lunn.ch>

    Andrew
Florian Fainelli Jan. 14, 2020, 9:57 p.m. UTC | #2
On 12/30/19 9:23 AM, Andrew Lunn wrote:
> On Mon, Dec 30, 2019 at 05:30:24PM +0300, Alexander Lobakin wrote:
>> DSA core updates Tx stats for slaves in dsa_slave_xmit(), no need to do
>> it manually in .xmit() tagger callback.
>>
>> Signed-off-by: Alexander Lobakin <alobakin@dlink.ru>
> 
> Reviewed-by: Andrew Lunn <andrew@lunn.ch>

Alexander, can you submit that separately from your GRO series and add a
Fixes tag for this?

Thanks!
diff mbox series

Patch

diff --git a/net/dsa/tag_qca.c b/net/dsa/tag_qca.c
index 8e2dbaaffe59..e1c4dd04734a 100644
--- a/net/dsa/tag_qca.c
+++ b/net/dsa/tag_qca.c
@@ -33,9 +33,6 @@  static struct sk_buff *qca_tag_xmit(struct sk_buff *skb, struct net_device *dev)
 	struct dsa_port *dp = dsa_slave_to_port(dev);
 	u16 *phdr, hdr;
 
-	dev->stats.tx_packets++;
-	dev->stats.tx_bytes += skb->len;
-
 	if (skb_cow_head(skb, 0) < 0)
 		return NULL;