diff options
| author | Prasad Kummari <[email protected]> | 2025-03-05 19:18:46 +0530 |
|---|---|---|
| committer | Michal Simek <[email protected]> | 2025-04-16 13:42:06 +0200 |
| commit | 5ffab6ee1279fe86ab21b529a04b1638a6664eaf (patch) | |
| tree | 7594d8021c3f6bf41a8cb0b85bf1b3d994a05fb3 /include | |
| parent | 253da1f0a2821bf741c8dc24ed2e568b7013f6e0 (diff) | |
xilinx: versal: add firmware access to PMC multi Boot mode register
Added extended support for retrieving the PMC muti boot mode
register via the firmware interface, which is preferred when
U-Boot runs in EL2 and cannot directly access PMC registers
via raw reads. Ideally, all secure registers should be accessed
via xilinx_pm_request(). Introduced the secure
zynqmp_pm_get_pmc_multi_boot_reg() call, which uses
xilinx_pm_request() to read the PMC multi boot mode register.
BootROM increments the MultiBoot register (PMC_MULTI_BOOT) read
address offset by 32 KB and retries. For SD and eMMC boot modes,
it can search up to 8191 FAT files for the identification string.
A 13-bit mask (0x1FFF) is applied to PMC_MULTI_BOOT_MASK to obtain
the correct values in BootROM.
Signed-off-by: Prasad Kummari <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Michal Simek <[email protected]>
Diffstat (limited to 'include')
| -rw-r--r-- | include/zynqmp_firmware.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/include/zynqmp_firmware.h b/include/zynqmp_firmware.h index e7275f72fac..82781dfd16b 100644 --- a/include/zynqmp_firmware.h +++ b/include/zynqmp_firmware.h @@ -458,6 +458,7 @@ int zynqmp_mmio_read(const u32 address, u32 *value); int zynqmp_mmio_write(const u32 address, const u32 mask, const u32 value); int zynqmp_pm_feature(const u32 api_id); u32 zynqmp_pm_get_bootmode_reg(void); +u32 zynqmp_pm_get_pmc_multi_boot_reg(void); /* Type of Config Object */ #define PM_CONFIG_OBJECT_TYPE_BASE 0x1U @@ -504,4 +505,7 @@ struct zynqmp_ipi_msg { #define CRP_BOOT_MODE_REG_NODE 0x30000001 #define CRP_BOOT_MODE_REG_OFFSET 0x200 +#define PM_REG_PMC_GLOBAL_NODE 0x30000004 +#define PMC_MULTI_BOOT_MODE_REG_OFFSET 0x4 + #endif /* _ZYNQMP_FIRMWARE_H_ */ |
