bonding: remove useless assignment
authorNicolas de Pesloüan <nicolas.2p.debian@free.fr>
Wed, 7 Oct 2009 21:11:00 +0000 (14:11 -0700)
committerDavid S. Miller <davem@davemloft.net>
Wed, 7 Oct 2009 21:11:00 +0000 (14:11 -0700)
The variable old_active is first set to bond->curr_active_slave.
Then, it is unconditionally set to new_active, without being used in between.

The first assignment, having no side effect, is useless.

Signed-off-by: Nicolas de Pesloüan <nicolas.2p.debian@free.fr>
Reviewed-by: Jiri Pirko <jpirko@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/bonding/bond_main.c

index 05877cb182e781edc2301a5e6e64360869f74ccd..ef6af1cb7d391fb2b909dd1d8cfa23dc0bb3adff 100644 (file)
@@ -1119,7 +1119,7 @@ static struct slave *bond_find_best_slave(struct bonding *bond)
        int mintime = bond->params.updelay;
        int i;
 
-       new_active = old_active = bond->curr_active_slave;
+       new_active = bond->curr_active_slave;
 
        if (!new_active) { /* there were no active slaves left */
                if (bond->slave_cnt > 0)   /* found one slave */