bonding: wrap slave state work
transfers slave->state into slave->backup (that it's going to transfer into bitfield. Introduce wrapper inlines to do the work with it. Signed-off-by: Jiri Pirko <jpirko@redhat.com> Reviewed-by: Nicolas de Pesloüan <nicolas.2p.debian@free.fr> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:

committed by
David S. Miller

parent
0bd80dad57
commit
e30bc066ab
@@ -1582,7 +1582,7 @@ static ssize_t bonding_store_slaves_active(struct device *d,
|
||||
}
|
||||
|
||||
bond_for_each_slave(bond, slave, i) {
|
||||
if (slave->state == BOND_STATE_BACKUP) {
|
||||
if (!bond_is_active_slave(slave)) {
|
||||
if (new_value)
|
||||
slave->dev->priv_flags &= ~IFF_SLAVE_INACTIVE;
|
||||
else
|
||||
|
Reference in New Issue
Block a user