board: amd: Read an eeprom after relocation
authorPadmarao Begari <padmarao.begari@amd.com>
Wed, 9 Apr 2025 16:26:39 +0000 (21:56 +0530)
committerMichal Simek <michal.simek@amd.com>
Wed, 16 Apr 2025 13:39:48 +0000 (15:39 +0200)
Read an eeprom after relocation which also shows information from
eeprom wired via nvmem aliases.

When DTB reselection is enabled eeprom is read before relocation
too but information is not showed. The issue about two i2c reads
in this case will be address separately.

Signed-off-by: Padmarao Begari <padmarao.begari@amd.com>
Link: https://lore.kernel.org/r/20250409162639.588487-3-padmarao.begari@amd.com
Signed-off-by: Michal Simek <michal.simek@amd.com>
board/amd/versal2/board.c

index 24689d8..72967e6 100644 (file)
@@ -45,6 +45,9 @@ int board_init(void)
        fpga_add(fpga_xilinx, &versalpl);
 #endif
 
+       if (CONFIG_IS_ENABLED(DM_I2C) && CONFIG_IS_ENABLED(I2C_EEPROM))
+               xilinx_read_eeprom();
+
        return 0;
 }