struct ti_common_eeprom *ep;
ep = TI_EEPROM_DATA;
+#ifndef CONFIG_SPL_BUILD
if (ep->header == TI_EEPROM_HEADER_MAGIC)
- goto already_read;
+ return 0; /* EEPROM has already been read */
+#endif
/* Initialize with a known bad marker for i2c fails.. */
ep->header = TI_DEAD_EEPROM_MAGIC;
memcpy(ep->mac_addr, am_ep.mac_addr,
TI_EEPROM_HDR_NO_OF_MAC_ADDR * TI_EEPROM_HDR_ETH_ALEN);
-already_read:
return 0;
}
struct ti_common_eeprom *ep;
ep = TI_EEPROM_DATA;
+#ifndef CONFIG_SPL_BUILD
if (ep->header == DRA7_EEPROM_HEADER_MAGIC)
- goto already_read;
+ return 0; /* EEPROM has already been read */
+#endif
/* Initialize with a known bad marker for i2c fails.. */
ep->header = TI_DEAD_EEPROM_MAGIC;
strlcpy(ep->config, dra7_ep.config, TI_EEPROM_HDR_CONFIG_LEN + 1);
ti_eeprom_string_cleanup(ep->config);
-already_read:
return 0;
}