aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/net/bonding/bond_main.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/net/bonding/bond_main.c b/drivers/net/bonding/bond_main.c
index 4798d30c9545..1aeb36c51478 100644
--- a/drivers/net/bonding/bond_main.c
+++ b/drivers/net/bonding/bond_main.c
@@ -1331,6 +1331,7 @@ static int bond_compute_features(struct bonding *bond)
1331 struct slave *slave; 1331 struct slave *slave;
1332 struct net_device *bond_dev = bond->dev; 1332 struct net_device *bond_dev = bond->dev;
1333 unsigned long features = bond_dev->features; 1333 unsigned long features = bond_dev->features;
1334 unsigned long vlan_features = 0;
1334 unsigned short max_hard_header_len = max((u16)ETH_HLEN, 1335 unsigned short max_hard_header_len = max((u16)ETH_HLEN,
1335 bond_dev->hard_header_len); 1336 bond_dev->hard_header_len);
1336 int i; 1337 int i;
@@ -1343,10 +1344,14 @@ static int bond_compute_features(struct bonding *bond)
1343 1344
1344 features &= ~NETIF_F_ONE_FOR_ALL; 1345 features &= ~NETIF_F_ONE_FOR_ALL;
1345 1346
1347 vlan_features = bond->first_slave->dev->vlan_features;
1346 bond_for_each_slave(bond, slave, i) { 1348 bond_for_each_slave(bond, slave, i) {
1347 features = netdev_increment_features(features, 1349 features = netdev_increment_features(features,
1348 slave->dev->features, 1350 slave->dev->features,
1349 NETIF_F_ONE_FOR_ALL); 1351 NETIF_F_ONE_FOR_ALL);
1352 vlan_features = netdev_increment_features(vlan_features,
1353 slave->dev->vlan_features,
1354 NETIF_F_ONE_FOR_ALL);
1350 if (slave->dev->hard_header_len > max_hard_header_len) 1355 if (slave->dev->hard_header_len > max_hard_header_len)
1351 max_hard_header_len = slave->dev->hard_header_len; 1356 max_hard_header_len = slave->dev->hard_header_len;
1352 } 1357 }
@@ -1354,6 +1359,7 @@ static int bond_compute_features(struct bonding *bond)
1354done: 1359done:
1355 features |= (bond_dev->features & BOND_VLAN_FEATURES); 1360 features |= (bond_dev->features & BOND_VLAN_FEATURES);
1356 bond_dev->features = netdev_fix_features(features, NULL); 1361 bond_dev->features = netdev_fix_features(features, NULL);
1362 bond_dev->vlan_features = netdev_fix_features(vlan_features, NULL);
1357 bond_dev->hard_header_len = max_hard_header_len; 1363 bond_dev->hard_header_len = max_hard_header_len;
1358 1364
1359 return 0; 1365 return 0;