On 2021/9/22 22:57, Jian Shen wrote:
Use netdev_feature_xxx helpers to replace the logical operation for netdev features.
Signed-off-by: Jian Shen shenjian15@huawei.com
net/l2tp/l2tp_eth.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/net/l2tp/l2tp_eth.c b/net/l2tp/l2tp_eth.c index 6cd97c75445c..1c5ed5ada9e6 100644 --- a/net/l2tp/l2tp_eth.c +++ b/net/l2tp/l2tp_eth.c @@ -117,7 +117,8 @@ static void l2tp_eth_dev_setup(struct net_device *dev) SET_NETDEV_DEVTYPE(dev, &l2tpeth_type); ether_setup(dev); dev->priv_flags &= ~IFF_TX_SKB_SHARING;
- dev->features |= NETIF_F_LLTX;
- netdev_feature_zero(&dev->features);
the origin line use “|=”, so it does not need initialize by netdev_feature_zero?
- netdev_feature_set_bit(NETIF_F_LLTX_BIT, &dev->features); dev->netdev_ops = &l2tp_eth_netdev_ops; dev->needs_free_netdev = true;
}