Skip to contentSkip to conversation

net: dsa: sja1105: fix lastused timestamp in flower stats

PATCH Applied David Yang 2 participants 2 messages Jun 14 – Jun 16

Subsystems (4)
lore
Share & tools
lore

David Yang

author
#0 lore raw

PATCH 1/1 net: dsa: sja1105: fix lastused timestamp in flower stats

flow_stats_update() takes an absolute timestamp for lastused, not delta. Fix that.

---
 drivers/net/dsa/sja1105/sja1105_vl.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
drivers/net/dsa/sja1105/sja1105_vl.c +1 -2
index 0ae9cb5ea8d1..e6ba9d4f8d1e 100644
@@ -791,8 +791,7 @@ int sja1105_vl_stats(struct sja1105_private *priv, int port,
 	pkts = timingerr + unreleased + lengtherr;
 
 	flow_stats_update(stats, 0, pkts - rule->vl.stats.pkts, 0,
-			  jiffies - rule->vl.stats.lastused,
-			  FLOW_ACTION_HW_STATS_IMMEDIATE);
+			  jiffies, FLOW_ACTION_HW_STATS_IMMEDIATE);
 
 	rule->vl.stats.pkts = pkts;
 	rule->vl.stats.lastused = jiffies;
Signature · 1 line
2.53.0
#1 lore raw
This patch was applied to netdev/net-next.git (main) by Jakub Kicinski <[email protected]>:

Hello:

This patch was applied to netdev/net-next.git (main) by Jakub Kicinski <[email protected]>:

Quoted 7 lines · On Sun, 14 Jun 2026 22:13:16 +0800 you wrote:

flow_stats_update() takes an absolute timestamp for lastused, not delta. Fix that.

---
 drivers/net/dsa/sja1105/sja1105_vl.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

Here is the summary with links:
- [net-next] net: dsa: sja1105: fix lastused timestamp in flower stats

    https://git.kernel.org/netdev/net-next/c/72dfa4700f78

You are awesome, thank you!

Signature · 2 lines
Deet-doot-dot, I am a bot.
https://korg.docs.kernel.org/patchwork/pwbot.html