Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 290199
b: refs/heads/master
c: 43aabec
h: refs/heads/master
i:
  290197: 789b891
  290195: 46cdb7d
  290191: d0325cd
v: v3
  • Loading branch information
Danny Kukawka authored and David S. Miller committed Feb 17, 2012
1 parent 51d1d80 commit ed6e850
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 7718f2c27dbdae0b22b2268a9c1b38edf0d8fa16
refs/heads/master: 43aabec51e0ab5d71c30530eec55963673354033
7 changes: 7 additions & 0 deletions trunk/drivers/net/ethernet/lantiq_etop.c
Original file line number Diff line number Diff line change
Expand Up @@ -634,6 +634,7 @@ ltq_etop_init(struct net_device *dev)
struct ltq_etop_priv *priv = netdev_priv(dev);
struct sockaddr mac;
int err;
bool random_mac = false;

ether_setup(dev);
dev->watchdog_timeo = 10 * HZ;
Expand All @@ -646,11 +647,17 @@ ltq_etop_init(struct net_device *dev)
if (!is_valid_ether_addr(mac.sa_data)) {
pr_warn("etop: invalid MAC, using random\n");
random_ether_addr(mac.sa_data);
random_mac = true;
}

err = ltq_etop_set_mac_address(dev, &mac);
if (err)
goto err_netdev;

/* Set addr_assign_type here, ltq_etop_set_mac_address would reset it. */
if (random_mac)
dev->addr_assign_type |= NET_ADDR_RANDOM;

ltq_etop_set_multicast_list(dev);
err = ltq_etop_mdio_init(dev);
if (err)
Expand Down

0 comments on commit ed6e850

Please sign in to comment.