aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/bonding/bond_alb.c
diff options
context:
space:
mode:
authorStephen Hemminger <shemminger@vyatta.com>2008-11-20 00:56:05 -0500
committerDavid S. Miller <davem@davemloft.net>2008-11-20 01:42:42 -0500
commiteb7cc59a038b4e1914ae991d313f35904924759f (patch)
tree4f4af2bd1e4e86582b45e9ce18ca88fcff287665 /drivers/net/bonding/bond_alb.c
parent656299f706e52e0409733d704c2761f1b12d6954 (diff)
bonding: convert to net_device_ops
Convert to net_device_ops table. Note: for some operations move error checking into generic networking layer (rather than looking at pointers in bonding). A couple of gratituous style cleanups to get rid of extra {} Signed-off-by: Stephen Hemminger <shemminger@vyatta.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/bonding/bond_alb.c')
-rw-r--r--drivers/net/bonding/bond_alb.c8
1 files changed, 1 insertions, 7 deletions
diff --git a/drivers/net/bonding/bond_alb.c b/drivers/net/bonding/bond_alb.c
index 073d25f357bb..f0dde1888c71 100644
--- a/drivers/net/bonding/bond_alb.c
+++ b/drivers/net/bonding/bond_alb.c
@@ -1218,11 +1218,6 @@ static int alb_set_mac_address(struct bonding *bond, void *addr)
1218 } 1218 }
1219 1219
1220 bond_for_each_slave(bond, slave, i) { 1220 bond_for_each_slave(bond, slave, i) {
1221 if (slave->dev->set_mac_address == NULL) {
1222 res = -EOPNOTSUPP;
1223 goto unwind;
1224 }
1225
1226 /* save net_device's current hw address */ 1221 /* save net_device's current hw address */
1227 memcpy(tmp_addr, slave->dev->dev_addr, ETH_ALEN); 1222 memcpy(tmp_addr, slave->dev->dev_addr, ETH_ALEN);
1228 1223
@@ -1231,9 +1226,8 @@ static int alb_set_mac_address(struct bonding *bond, void *addr)
1231 /* restore net_device's hw address */ 1226 /* restore net_device's hw address */
1232 memcpy(slave->dev->dev_addr, tmp_addr, ETH_ALEN); 1227 memcpy(slave->dev->dev_addr, tmp_addr, ETH_ALEN);
1233 1228
1234 if (res) { 1229 if (res)
1235 goto unwind; 1230 goto unwind;
1236 }
1237 } 1231 }
1238 1232
1239 return 0; 1233 return 0;