Skip to contentSkip to conversation

ARM: dra7_evm: read mac address properly from e-fuse

PATCH New Mugunthan V N 2 participants 2 messages Jan 7, 2014 – Jan 8, 2014

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 ARM: dra7_evm: read mac address properly from e-fuse

Byte offset of Ethernet mac address read from e-fuse are wrong so DHCP is not working on some boards, modifying the offset to read properly.

---
 board/ti/dra7xx/evm.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)
board/ti/dra7xx/evm.c +4 -4
index 9ae88c5..1b60b8f 100644
@@ -202,12 +202,12 @@ int board_eth_init(bd_t *bis)
 	/* try reading mac address from efuse */
 	mac_lo = readl((*ctrl)->control_core_mac_id_0_lo);
 	mac_hi = readl((*ctrl)->control_core_mac_id_0_hi);
-	mac_addr[0] = mac_hi & 0xFF;
+	mac_addr[0] = (mac_hi & 0xFF0000) >> 16;
 	mac_addr[1] = (mac_hi & 0xFF00) >> 8;
-	mac_addr[2] = (mac_hi & 0xFF0000) >> 16;
-	mac_addr[3] = mac_lo & 0xFF;
+	mac_addr[2] = mac_hi & 0xFF;
+	mac_addr[3] = (mac_lo & 0xFF0000) >> 16;
 	mac_addr[4] = (mac_lo & 0xFF00) >> 8;
-	mac_addr[5] = (mac_lo & 0xFF0000) >> 16;
+	mac_addr[5] = mac_lo & 0xFF;
 
 	if (!getenv("ethaddr")) {
 		printf("<ethaddr> not set. Validating first E-fuse MAC\n");
Signature · 1 line
1.8.5.2.192.g7794a68
#1 lore raw

PATCH 1/1 ARM: dra7_evm: read mac address properly from e-fuse

Quoted 4 lines · Mugunthan V N

Byte offset of Ethernet mac address read from e-fuse are wrong so DHCP is not working on some boards, modifying the offset to read properly.

Applied to u-boot-ti/master, thanks!

Signature · 8 lines
Tom
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
URL: <http://lists.denx.de/pipermail/u-boot/attachments/20140108/8b911044/attachment.pgp>