feat(versal2): update platform version to versal2
Extend board detection with saving information about PS,
PMC and RTL versions. Variables can be use to cover
different behavior based on version and version
information is also printed for chip identification.
Change-Id: Ia37418f6a31426a5763fb89fc76fef91d09df155
Signed-off-by: Saivardhan Thatikonda <saivardhan.thatikonda@amd.com>
diff --git a/plat/amd/versal2/include/def.h b/plat/amd/versal2/include/def.h
index 0c43d1b..938b118 100644
--- a/plat/amd/versal2/include/def.h
+++ b/plat/amd/versal2/include/def.h
@@ -45,6 +45,9 @@
/* For platform detection */
#define PMC_TAP U(0xF11A0000)
#define PMC_TAP_VERSION (PMC_TAP + 0x4U)
+# define PMC_VERSION GENMASK(7U, 0U)
+# define PS_VERSION GENMASK(15U, 8U)
+# define RTL_VERSION GENMASK(23U, 16U)
# define PLATFORM_MASK GENMASK(27U, 24U)
# define PLATFORM_VERSION_MASK GENMASK(31U, 28U)
diff --git a/plat/amd/versal2/include/plat_private.h b/plat/amd/versal2/include/plat_private.h
index 5a2e5bd..4be2061 100644
--- a/plat/amd/versal2/include/plat_private.h
+++ b/plat/amd/versal2/include/plat_private.h
@@ -41,6 +41,7 @@
void plat_gic_redistif_off(void);
extern uint32_t cpu_clock, platform_id, platform_version;
+extern uint32_t rtlversion, psversion, pmcversion;
void board_detection(void);
const char *board_name_decode(void);
uint64_t smc_handler(uint32_t smc_fid, uint64_t x1, uint64_t x2, uint64_t x3,