# \[PATCH net-next v2 0/3\] net/sched: let hardware only actions drop per CPU stats

- From: Alexandre Cassen \<hidden\>
- Date: 2026-11-04 21:46:18 
- List: netdev
- Page: https://ratatoskr.run/netdev/2026/11/17865185
- Thread: https://ratatoskr.run/netdev/2026/11/17865185/t.md

```text
This series lets hardware only actions drop their per CPU stats and
the tunnel_key dst cache:

- skbedit, police, mpls and sample honor TCA_ACT_FLAGS_NO_PERCPU_STATS.
- Action init sees the offload flags of the filter, so a skip_sw filter
  alone now satisfies the skbedit queue_mapping check.
- tunnel_key skips the dst cache for skip_sw actions.

v2:
- Add patch 2 so that a skip_sw filter is enough for patch 3 (Sashiko
  [1], Jakub).
- Give the memory saving in patch 3 (Sashiko [1], Jakub) and patch 1.
- Drop the race note from patch 1. Commit 1800f27a5ef8 ("net/sched:
  act_api: take tcfa_lock for hardware stats updates") fixes this race,
  which Sashiko [1] also flags.
- Add Jamal's Reviewed-by to patches 1 and 3.

v1: https://lore.kernel.org/netdev/20261009051930.3619697-1-acassen@corp.free.fr/
[1] https://netdev-ai.bots.linux.dev/sashiko/#/patchset/20261009051930.3619697-1-acassen%40corp.free.fr

Alexandre Cassen (3):
  net/sched: honor TCA_ACT_FLAGS_NO_PERCPU_STATS in more actions
  net/sched: act_api: pass the filter offload flags to action init
  net/sched: act_tunnel_key: skip dst cache for skip_sw actions

 net/sched/act_api.c        | 17 +++++++----------
 net/sched/act_mpls.c       |  8 ++++----
 net/sched/act_police.c     | 10 +++++-----
 net/sched/act_sample.c     |  6 +++---
 net/sched/act_skbedit.c    |  9 +++++----
 net/sched/act_tunnel_key.c | 10 +++++++---
 6 files changed, 31 insertions(+), 29 deletions(-)

-- 
2.43.0

```
