From 42139bb9b7dc10dcf5432cc34eb1bf2e233ef359 Mon Sep 17 00:00:00 2001 From: Anup Patel Date: Tue, 9 Dec 2025 19:22:34 +0530 Subject: lib: sbi: Replace sbi_hart_pmp_xyz() and sbi_hart_map/unmap_addr() The sbi_hart_pmp_xyz() and sbi_hart_map/unmap_addr() functions can now be replaced by various sbi_hart_protection_xyz() functions. Signed-off-by: Anup Patel Link: https://lore.kernel.org/r/20251209135235.423391-5-apatel@ventanamicro.com Signed-off-by: Anup Patel --- include/sbi/sbi_hart.h | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) (limited to 'include') diff --git a/include/sbi/sbi_hart.h b/include/sbi/sbi_hart.h index d313527..bbd8026 100644 --- a/include/sbi/sbi_hart.h +++ b/include/sbi/sbi_hart.h @@ -117,8 +117,8 @@ enum sbi_hart_csrs { * When shared memory access is required, the physical address * should be programmed into the first PMP entry with R/W * permissions to the M-mode. Once the work is done, it should be - * unmapped. sbi_hart_map_saddr/sbi_hart_unmap_saddr function - * pair should be used to map/unmap the shared memory. + * unmapped. sbi_hart_protection_map_range/sbi_hart_protection_unmap_range + * function pair should be used to map/unmap the shared memory. */ #define SBI_SMEPMP_RESV_ENTRY 0 @@ -149,10 +149,6 @@ unsigned int sbi_hart_pmp_log2gran(struct sbi_scratch *scratch); unsigned int sbi_hart_pmp_addrbits(struct sbi_scratch *scratch); unsigned int sbi_hart_mhpm_bits(struct sbi_scratch *scratch); bool sbi_hart_smepmp_is_fw_region(unsigned int pmp_idx); -int sbi_hart_pmp_configure(struct sbi_scratch *scratch); -void sbi_hart_pmp_unconfigure(struct sbi_scratch *scratch); -int sbi_hart_map_saddr(unsigned long base, unsigned long size); -int sbi_hart_unmap_saddr(void); int sbi_hart_priv_version(struct sbi_scratch *scratch); void sbi_hart_get_priv_version_str(struct sbi_scratch *scratch, char *version_str, int nvstr); -- cgit v1.1