From 022041edba2874d877aeeef7419e0ab896d445ae Mon Sep 17 00:00:00 2001 From: Yong Cong Sin Date: Mon, 16 Sep 2024 13:45:24 +0800 Subject: [PATCH] soc: riscv: andes_v5: fix PMA compilation warnings These static functions in the `pma.c` are used only when `CONFIG_NOCACHE_MEMORY` is enabled, so guard them accordingly. Signed-off-by: Yong Cong Sin Signed-off-by: Yong Cong Sin --- soc/andestech/ae350/pma.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/soc/andestech/ae350/pma.c b/soc/andestech/ae350/pma.c index 0fb162cc959..71da2248b72 100644 --- a/soc/andestech/ae350/pma.c +++ b/soc/andestech/ae350/pma.c @@ -70,6 +70,7 @@ struct pma_region { struct pma_region_attr attr; }; +#ifdef CONFIG_NOCACHE_MEMORY /* * Write value to CSRs pmaaddr{i} */ @@ -165,7 +166,6 @@ static int pma_region_is_valid(const struct pma_region *region) return 0; } -#ifdef CONFIG_NOCACHE_MEMORY static void configure_nocache_region(void) { const struct pma_region nocache_region = {