diff options
Diffstat (limited to 'drivers/net/macvlan.c')
-rw-r--r-- | drivers/net/macvlan.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/drivers/net/macvlan.c b/drivers/net/macvlan.c index d5334b41e4b4..99eed9f37c84 100644 --- a/drivers/net/macvlan.c +++ b/drivers/net/macvlan.c | |||
@@ -232,7 +232,7 @@ static int macvlan_open(struct net_device *dev) | |||
232 | if (macvlan_addr_busy(vlan->port, dev->dev_addr)) | 232 | if (macvlan_addr_busy(vlan->port, dev->dev_addr)) |
233 | goto out; | 233 | goto out; |
234 | 234 | ||
235 | err = dev_unicast_add(lowerdev, dev->dev_addr, ETH_ALEN); | 235 | err = dev_unicast_add(lowerdev, dev->dev_addr); |
236 | if (err < 0) | 236 | if (err < 0) |
237 | goto out; | 237 | goto out; |
238 | if (dev->flags & IFF_ALLMULTI) { | 238 | if (dev->flags & IFF_ALLMULTI) { |
@@ -244,7 +244,7 @@ static int macvlan_open(struct net_device *dev) | |||
244 | return 0; | 244 | return 0; |
245 | 245 | ||
246 | del_unicast: | 246 | del_unicast: |
247 | dev_unicast_delete(lowerdev, dev->dev_addr, ETH_ALEN); | 247 | dev_unicast_delete(lowerdev, dev->dev_addr); |
248 | out: | 248 | out: |
249 | return err; | 249 | return err; |
250 | } | 250 | } |
@@ -258,7 +258,7 @@ static int macvlan_stop(struct net_device *dev) | |||
258 | if (dev->flags & IFF_ALLMULTI) | 258 | if (dev->flags & IFF_ALLMULTI) |
259 | dev_set_allmulti(lowerdev, -1); | 259 | dev_set_allmulti(lowerdev, -1); |
260 | 260 | ||
261 | dev_unicast_delete(lowerdev, dev->dev_addr, ETH_ALEN); | 261 | dev_unicast_delete(lowerdev, dev->dev_addr); |
262 | 262 | ||
263 | macvlan_hash_del(vlan); | 263 | macvlan_hash_del(vlan); |
264 | return 0; | 264 | return 0; |
@@ -282,10 +282,11 @@ static int macvlan_set_mac_address(struct net_device *dev, void *p) | |||
282 | if (macvlan_addr_busy(vlan->port, addr->sa_data)) | 282 | if (macvlan_addr_busy(vlan->port, addr->sa_data)) |
283 | return -EBUSY; | 283 | return -EBUSY; |
284 | 284 | ||
285 | if ((err = dev_unicast_add(lowerdev, addr->sa_data, ETH_ALEN))) | 285 | err = dev_unicast_add(lowerdev, addr->sa_data); |
286 | if (err) | ||
286 | return err; | 287 | return err; |
287 | 288 | ||
288 | dev_unicast_delete(lowerdev, dev->dev_addr, ETH_ALEN); | 289 | dev_unicast_delete(lowerdev, dev->dev_addr); |
289 | 290 | ||
290 | macvlan_hash_change_addr(vlan, addr->sa_data); | 291 | macvlan_hash_change_addr(vlan, addr->sa_data); |
291 | } | 292 | } |
@@ -358,6 +359,7 @@ static int macvlan_init(struct net_device *dev) | |||
358 | (lowerdev->state & MACVLAN_STATE_MASK); | 359 | (lowerdev->state & MACVLAN_STATE_MASK); |
359 | dev->features = lowerdev->features & MACVLAN_FEATURES; | 360 | dev->features = lowerdev->features & MACVLAN_FEATURES; |
360 | dev->iflink = lowerdev->ifindex; | 361 | dev->iflink = lowerdev->ifindex; |
362 | dev->hard_header_len = lowerdev->hard_header_len; | ||
361 | 363 | ||
362 | macvlan_set_lockdep_class(dev); | 364 | macvlan_set_lockdep_class(dev); |
363 | 365 | ||