aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
Diffstat (limited to 'drivers')
-rw-r--r--drivers/net/macvlan.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/drivers/net/macvlan.c b/drivers/net/macvlan.c
index a5d21893670d..1831fb7cd017 100644
--- a/drivers/net/macvlan.c
+++ b/drivers/net/macvlan.c
@@ -506,6 +506,9 @@ static int macvlan_change_mtu(struct net_device *dev, int new_mtu)
506static struct lock_class_key macvlan_netdev_xmit_lock_key; 506static struct lock_class_key macvlan_netdev_xmit_lock_key;
507static struct lock_class_key macvlan_netdev_addr_lock_key; 507static struct lock_class_key macvlan_netdev_addr_lock_key;
508 508
509#define ALWAYS_ON_FEATURES \
510 (NETIF_F_SG | NETIF_F_GEN_CSUM | NETIF_F_GSO_SOFTWARE | NETIF_F_LLTX)
511
509#define MACVLAN_FEATURES \ 512#define MACVLAN_FEATURES \
510 (NETIF_F_SG | NETIF_F_ALL_CSUM | NETIF_F_HIGHDMA | NETIF_F_FRAGLIST | \ 513 (NETIF_F_SG | NETIF_F_ALL_CSUM | NETIF_F_HIGHDMA | NETIF_F_FRAGLIST | \
511 NETIF_F_GSO | NETIF_F_TSO | NETIF_F_UFO | NETIF_F_GSO_ROBUST | \ 514 NETIF_F_GSO | NETIF_F_TSO | NETIF_F_UFO | NETIF_F_GSO_ROBUST | \
@@ -539,7 +542,7 @@ static int macvlan_init(struct net_device *dev)
539 dev->state = (dev->state & ~MACVLAN_STATE_MASK) | 542 dev->state = (dev->state & ~MACVLAN_STATE_MASK) |
540 (lowerdev->state & MACVLAN_STATE_MASK); 543 (lowerdev->state & MACVLAN_STATE_MASK);
541 dev->features = lowerdev->features & MACVLAN_FEATURES; 544 dev->features = lowerdev->features & MACVLAN_FEATURES;
542 dev->features |= NETIF_F_LLTX; 545 dev->features |= ALWAYS_ON_FEATURES;
543 dev->gso_max_size = lowerdev->gso_max_size; 546 dev->gso_max_size = lowerdev->gso_max_size;
544 dev->iflink = lowerdev->ifindex; 547 dev->iflink = lowerdev->ifindex;
545 dev->hard_header_len = lowerdev->hard_header_len; 548 dev->hard_header_len = lowerdev->hard_header_len;
@@ -699,7 +702,7 @@ static netdev_features_t macvlan_fix_features(struct net_device *dev,
699 features = netdev_increment_features(vlan->lowerdev->features, 702 features = netdev_increment_features(vlan->lowerdev->features,
700 features, 703 features,
701 mask); 704 mask);
702 features |= NETIF_F_LLTX; 705 features |= ALWAYS_ON_FEATURES;
703 706
704 return features; 707 return features;
705} 708}