Skip to content

Commit 58c7821

Browse files
Radu CristescuJeff Garzik
authored andcommitted
atl1: relax eeprom mac address error check
The atl1 driver tries to determine the MAC address thusly: - If an EEPROM exists, read the MAC address from EEPROM and validate it. - If an EEPROM doesn't exist, try to read a MAC address from SPI flash. - If that fails, try to read a MAC address directly from the MAC Station Address register. - If that fails, assign a random MAC address provided by the kernel. We now have a report of a system fitted with an EEPROM containing all zeros where we expect the MAC address to be, and we currently handle this as an error condition. Turns out, on this system the BIOS writes a valid MAC address to the NIC's MAC Station Address register, but we never try to read it because we return an error when we find the all- zeros address in EEPROM. This patch relaxes the error check and continues looking for a MAC address even if it finds an illegal one in EEPROM. Signed-off-by: Radu Cristescu <[email protected]> Signed-off-by: Jay Cliburn <[email protected]> Signed-off-by: Jeff Garzik <[email protected]>
1 parent 7dac6f8 commit 58c7821

File tree

1 file changed

+0
-1
lines changed

1 file changed

+0
-1
lines changed

drivers/net/atlx/atl1.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -471,7 +471,6 @@ static int atl1_get_permanent_address(struct atl1_hw *hw)
471471
memcpy(hw->perm_mac_addr, eth_addr, ETH_ALEN);
472472
return 0;
473473
}
474-
return 1;
475474
}
476475

477476
/* see if SPI FLAGS exist ? */

0 commit comments

Comments
 (0)