@@ -1420,7 +1420,7 @@ static netdev_features_t bond_fix_features(struct net_device *dev,
netdev_increment_features(&features, &features,
&slave->dev->features, &mask);
}
- features = netdev_add_tso_features(features, mask);
+ netdev_add_tso_features(&features, &mask);
return features;
}
@@ -2018,7 +2018,7 @@ static netdev_features_t team_fix_features(struct net_device *dev,
}
rcu_read_unlock();
- features = netdev_add_tso_features(features, mask);
+ netdev_add_tso_features(&features, &mask);
return features;
}
@@ -4899,11 +4899,10 @@ void netdev_increment_features(netdev_features_t *ret,
* Performing the GSO segmentation before last device
* is a performance improvement.
*/
-static inline netdev_features_t netdev_add_tso_features(netdev_features_t features,
- netdev_features_t mask)
+static inline void netdev_add_tso_features(netdev_features_t *features,
+ const netdev_features_t *mask)
{
- netdev_increment_features(&features, &features, &NETIF_F_ALL_TSO, &mask);
- return features;
+ netdev_increment_features(features, features, &NETIF_F_ALL_TSO, mask);
}
int __netdev_update_features(struct net_device *dev);
@@ -548,7 +548,7 @@ netdev_features_t br_features_recompute(struct net_bridge *br,
netdev_increment_features(&features, &features,
&p->dev->features, &mask);
}
- features = netdev_add_tso_features(features, mask);
+ netdev_add_tso_features(&features, &mask);
return features;
}
The function netdev_add_tos_features() using netdev_features_t as parameters, and returns netdev_features_t directly. For the prototype of netdev_features_t will be extended to be larger than 8 bytes, so change the prototype of the function, change the prototype of input features to ‘netdev_features_t *', and return the features pointer as output parameters. Signed-off-by: Jian Shen <shenjian15@huawei.com> --- drivers/net/bonding/bond_main.c | 2 +- drivers/net/team/team.c | 2 +- include/linux/netdevice.h | 7 +++---- net/bridge/br_if.c | 2 +- 4 files changed, 6 insertions(+), 7 deletions(-)