Skip to content

net: centralize master device offload feature computation

Hangbin Liu bridge lkml netdev 3 versions – In review

Get series with b4
b4 am [email protected] change-id 20260310-offload_compute-4c0bafa2e022

Versions newest first

  1. v3 Latest5 patches 9 repliesIn review
  2. v24 patches 2 repliesSuperseded
  3. v13 patches 10 repliesSuperseded

Changes in v3 from the cover letter

- ndo_set_features may be skipped when no feature change, fallback to
use ndo_update_offloads for offload computation (Simon Horman)
- Link to v2: https://lore.kernel.org/r/[email protected]

Patches in v3 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/5net: add ndo_update_offloads for offload computationinclude/linux/netdevice.h net/core/dev.c+10 -04 replies
2/5net: use ndo_update_offloads to set offload features for bonding/bridge/teamdrivers/net/bonding/bond_main.c drivers/net/team/team_core.c net/bridge/br_device.c +2 more+26 -131 reply
3/5macsec: move netdev_upper_dev_link() after macsec_changelink_common()drivers/net/macsec.c+12 -111 reply
4/5failover: use ndo_update_offloads for failover offload computedrivers/net/net_failover.c include/net/net_failover.h+7 -660 replies
5/5net: no need to disable LRO specificallydrivers/net/bonding/bond_main.c drivers/net/team/team_core.c net/8021q/vlan.c +2 more+0 -110 replies

Reviews trailers per patch

1 of 5 patches has a Reviewed-by or Acked-by.

PatchSabrina Dubroca
1/5
2/5
3/5R-b
4/5
5/5

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v3 thread

Cover letter [PATCH net-next v3 0/5] net: centralize master device offload feature computation

Currently, master devices (bonding, bridge, team) manually call netdev_compute_master_upper_features() scattered throughout their port add/remove operations. This approach requires each driver to remember to update features at the right times and leads to code duplication.

The series adds a new ndo_update_offloads callback that is automatically invoked during feature updates when upper/lower device relationships change. This centralizes the feature computation flow and removes the burden from individual drivers.

---
Changes in v3:
- ndo_set_features may be skipped when no feature change, fallback to
use ndo_update_offloads for offload computation (Simon Horman)
- Link to v2: https://lore.kernel.org/r/[email protected]

Changes in v2:
- Fix macsec Security Entity uninitialized issue (Sabrina Dubroca)
- Tested with macsec-offload.sh, rtnetlink.sh, link_netns.py, all pssed
- Link to v1: https://lore.kernel.org/r/[email protected]

---
Hangbin Liu (5):
net: add ndo_update_offloads for offload computation
net: use ndo_update_offloads to set offload features for bonding/bridge/team
macsec: move netdev_upper_dev_link() after macsec_changelink_common()
failover: use ndo_update_offloads for failover offload compute
net: no need to disable LRO specifically

 drivers/net/bonding/bond_main.c | 13 ++++----
 drivers/net/macsec.c            | 23 +++++++-------
 drivers/net/net_failover.c      | 66 +++++------------------------------------
 drivers/net/team/team_core.c    | 14 ++++-----
 include/linux/netdevice.h       |  7 +++++
 include/net/net_failover.h      |  7 -----
 net/8021q/vlan.c                |  2 --
 net/bridge/br_device.c          |  6 ++++
 net/bridge/br_if.c              |  6 ----
 net/core/dev.c                  | 11 +++++--
 net/hsr/hsr_slave.c             |  1 -
 11 files changed, 55 insertions(+), 101 deletions(-)

---
base-commit: 5446b8691eb8278f10deca92048fad84ffd1e4d5
change-id: 20260310-offload_compute-4c0bafa2e022

Best regards,

Signature · 1 line
Hangbin Liu <[email protected]>