Skip to content

Commit

Permalink
[PATCH] bcm43xx: check for valid MAC address in SPROM
Browse files Browse the repository at this point in the history
Check for valid MAC address in SPROM fields instead of relying on
PHY type while setting the MAC address in the networking subsystem,
as some devices have multiple PHYs.

Signed-off-by: Stefano Brivio <stefano.brivio@polimi.it>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
  • Loading branch information
Stefano Brivio authored and John W. Linville committed May 5, 2006
1 parent f21709d commit f9f7b96
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/net/wireless/bcm43xx/bcm43xx_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -3482,7 +3482,7 @@ static int bcm43xx_attach_board(struct bcm43xx_private *bcm)
bcm43xx_pctl_set_crystal(bcm, 0);

/* Set the MAC address in the networking subsystem */
if (bcm43xx_current_phy(bcm)->type == BCM43xx_PHYTYPE_A)
if (is_valid_ether_addr(bcm->sprom.et1macaddr))
memcpy(bcm->net_dev->dev_addr, bcm->sprom.et1macaddr, 6);
else
memcpy(bcm->net_dev->dev_addr, bcm->sprom.il0macaddr, 6);
Expand Down

0 comments on commit f9f7b96

Please sign in to comment.