@@ -1341,6 +1341,7 @@ static int bond_compute_features(struct bonding *bond)
struct slave *slave;
struct net_device *bond_dev = bond->dev;
unsigned long features = bond_dev->features;
+ unsigned long vlan_features = 0;
unsigned short max_hard_header_len = max((u16)ETH_HLEN,
bond_dev->hard_header_len);
int i;
@@ -1352,11 +1353,18 @@ static int bond_compute_features(struct bonding *bond)
goto done;
features &= ~NETIF_F_ONE_FOR_ALL;
-
+ vlan_features = bond->first_slave->dev->vlan_features;
+ printk("vf %lx\n", vlan_features);
bond_for_each_slave(bond, slave, i) {
features = netdev_increment_features(features,
slave->dev->features,
NETIF_F_ONE_FOR_ALL);
+ vlan_features = netdev_increment_features(vlan_features,
+ slave->dev->vlan_features,
+ NETIF_F_ONE_FOR_ALL);
+ printk("slave %s (f %lx vf %lx) new f %lx vf %lx\n",
+ slave->dev->name, slave->dev->features,
+ slave->dev->vlan_features, features, vlan_features);
if (slave->dev->hard_header_len > max_hard_header_len)
max_hard_header_len = slave->dev->hard_header_len;
}
@@ -1364,6 +1372,8 @@ static int bond_compute_features(struct bonding *bond)
done:
features |= (bond_dev->features & BOND_VLAN_FEATURES);
bond_dev->features = netdev_fix_features(features, NULL);
+ bond_dev->vlan_features = netdev_fix_features(vlan_features, NULL);
+ printk("bd->vf %lx\n", bond_dev->vlan_features);
bond_dev->hard_header_len = max_hard_header_len;
return 0;