Skip to content

Commit 9d279b9

Browse files
Di ZhuUlrich Hecht
authored andcommitted
netdev: preserve NETIF_F_ALL_FOR_ALL across TSO updates
[ Upstream commit 02d1e1a3f9239cdb3ecf2c6d365fb959d1bf39df ] Directly increment the TSO features incurs a side effect: it will also directly clear the flags in NETIF_F_ALL_FOR_ALL on the master device, which can cause issues such as the inability to enable the nocache copy feature on the bonding driver. The fix is to include NETIF_F_ALL_FOR_ALL in the update mask, thereby preventing it from being cleared. Fixes: b0ce350 ("bonding: allow TSO being set on bonding master") Signed-off-by: Di Zhu <zhud@hygon.cn> Link: https://patch.msgid.link/20251224012224.56185-1-zhud@hygon.cn Signed-off-by: Jakub Kicinski <kuba@kernel.org> Signed-off-by: Sasha Levin <sashal@kernel.org> Signed-off-by: Ulrich Hecht <uli@kernel.org>
1 parent 8e8e5bb commit 9d279b9

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

include/linux/netdevice.h

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4473,7 +4473,8 @@ netdev_features_t netdev_increment_features(netdev_features_t all,
44734473
static inline netdev_features_t netdev_add_tso_features(netdev_features_t features,
44744474
netdev_features_t mask)
44754475
{
4476-
return netdev_increment_features(features, NETIF_F_ALL_TSO, mask);
4476+
return netdev_increment_features(features, NETIF_F_ALL_TSO |
4477+
NETIF_F_ALL_FOR_ALL, mask);
44774478
}
44784479

44794480
int __netdev_update_features(struct net_device *dev);

0 commit comments

Comments
 (0)