information present in the device. The FRU Information is used
to primarily to provide "inventory" information about the boards
that the FRU Information Device is located on.
+
+config FRU_SC
+ bool "FRU system controller decoding"
+ help
+ Xilinx System Controller (SC) FRU format is describing boards from two
+ angles. One from DUT and then from SC. DUT is default option for
+ the main CPU. SC behaves more or less as slave and have different ID.
+ If you build U-Boot for SC you should enable this option to get proper
+ MAC address.
#define FRU_MULTIREC_MAC_OFFSET 4
#define FRU_LAST_REC BIT(7)
#define FRU_DUT_MACID 0x31
+#define FRU_SC_MACID 0x11
/* This should be minimum of fields */
#define FRU_BOARD_AREA_TOTAL_FIELDS 5
if (mrc.rec_type == FRU_MULTIREC_TYPE_OEM) {
struct fru_multirec_mac *mac = (void *)addr + hdr_len;
+ u32 type = FRU_DUT_MACID;
- if (mac->ver == FRU_DUT_MACID) {
+ if (CONFIG_IS_ENABLED(FRU_SC))
+ type = FRU_SC_MACID;
+
+ if (mac->ver == type) {
mac_len = mrc.len - FRU_MULTIREC_MAC_OFFSET;
memcpy(&fru_data.mac.macid, mac->macid, mac_len);
}