]> git.baikalelectronics.ru Git - kernel.git/commit
bonding: fix vlan_features computing
authorMichal Kubeček <mkubecek@suse.cz>
Tue, 20 May 2014 06:29:35 +0000 (08:29 +0200)
committerDavid S. Miller <davem@davemloft.net>
Thu, 22 May 2014 19:07:23 +0000 (15:07 -0400)
commit091f927ef9f15d354994a730d132262294c67c56
tree242b31e68c1133f9b5e1eabecdc4d856a083b27f
parentf33c197506bde48d2ddc2c52bad2b35b82856527
bonding: fix vlan_features computing

bond_compute_features() uses netdev_increment_features() to
combine vlan_features of slaves into vlan_features of the bond.
As netdev_increment_features() only adds most features and we
start with BOND_VLAN_FEATURES, we can end up with features none
of the slaves provided.

If there is at least one slave, initialize vlan_features only
with the flags in NETIF_F_ALL_FOR_ALL. Right now there is none
in BOND_VLAN_FEATURES but stating it explicitely will make the
code more future proof.

Signed-off-by: Michal Kubecek <mkubecek@suse.cz>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/bonding/bond_main.c