From 9e8a8b4e85371e73d343e4ad7713ac37c949a599 Mon Sep 17 00:00:00 2001 From: Moritz Fischer Date: Tue, 8 Aug 2023 20:21:55 -0700 Subject: [PATCH] soc: arm: common: cortex_m: Move arm_mpu_mem_cfg.h Move arm_mpu_mem_cfg header to common include directory. The benefits are two-fold: - Allow for out of tree SoC definitions to use them to define mpu_regions. - Remove odd relative include path Signed-off-by: Moritz Fischer --- .../zephyr/arch/arm/aarch32}/cortex_m/arm_mpu_mem_cfg.h | 0 soc/arm/common/cortex_m/arm_mpu_regions.c | 2 +- soc/arm/nuvoton_npcx/npcx7/mpu_regions.c | 2 +- soc/arm/nxp_imx/mimx8ml8_m7/mpu_regions.c | 2 +- soc/arm/nxp_imx/rt/mpu_regions.c | 2 +- soc/arm/nxp_s32/s32k/mpu_regions.c | 2 +- soc/arm/st_stm32/stm32h7/mpu_regions.c | 2 +- 7 files changed, 6 insertions(+), 6 deletions(-) rename {soc/arm/common => include/zephyr/arch/arm/aarch32}/cortex_m/arm_mpu_mem_cfg.h (100%) diff --git a/soc/arm/common/cortex_m/arm_mpu_mem_cfg.h b/include/zephyr/arch/arm/aarch32/cortex_m/arm_mpu_mem_cfg.h similarity index 100% rename from soc/arm/common/cortex_m/arm_mpu_mem_cfg.h rename to include/zephyr/arch/arm/aarch32/cortex_m/arm_mpu_mem_cfg.h diff --git a/soc/arm/common/cortex_m/arm_mpu_regions.c b/soc/arm/common/cortex_m/arm_mpu_regions.c index 512cd4441cd..557079ef5bc 100644 --- a/soc/arm/common/cortex_m/arm_mpu_regions.c +++ b/soc/arm/common/cortex_m/arm_mpu_regions.c @@ -8,7 +8,7 @@ #include #include -#include "arm_mpu_mem_cfg.h" +#include static const struct arm_mpu_region mpu_regions[] = { /* Region 0 */ diff --git a/soc/arm/nuvoton_npcx/npcx7/mpu_regions.c b/soc/arm/nuvoton_npcx/npcx7/mpu_regions.c index b8a2cc2d025..7592a2e39a2 100644 --- a/soc/arm/nuvoton_npcx/npcx7/mpu_regions.c +++ b/soc/arm/nuvoton_npcx/npcx7/mpu_regions.c @@ -4,7 +4,7 @@ * SPDX-License-Identifier: Apache-2.0 */ -#include "../../common/cortex_m/arm_mpu_mem_cfg.h" +#include static const struct arm_mpu_region mpu_regions[] = { MPU_REGION_ENTRY("FLASH_0_0", diff --git a/soc/arm/nxp_imx/mimx8ml8_m7/mpu_regions.c b/soc/arm/nxp_imx/mimx8ml8_m7/mpu_regions.c index f2771d5e30d..7964712f646 100644 --- a/soc/arm/nxp_imx/mimx8ml8_m7/mpu_regions.c +++ b/soc/arm/nxp_imx/mimx8ml8_m7/mpu_regions.c @@ -5,7 +5,7 @@ */ #include -#include "../../common/cortex_m/arm_mpu_mem_cfg.h" +#include #define REGION_MASK_BASE_ADDRESS 0x00000000U #define REGION_ITCM_BASE_ADDRESS 0x00000000U diff --git a/soc/arm/nxp_imx/rt/mpu_regions.c b/soc/arm/nxp_imx/rt/mpu_regions.c index 5340200ba26..663e448f5dd 100644 --- a/soc/arm/nxp_imx/rt/mpu_regions.c +++ b/soc/arm/nxp_imx/rt/mpu_regions.c @@ -8,7 +8,7 @@ #include #include -#include "../../common/cortex_m/arm_mpu_mem_cfg.h" +#include static const struct arm_mpu_region mpu_regions[] = { /* Region 0 */ diff --git a/soc/arm/nxp_s32/s32k/mpu_regions.c b/soc/arm/nxp_s32/s32k/mpu_regions.c index cc52e0be30e..9c4316d0aa9 100644 --- a/soc/arm/nxp_s32/s32k/mpu_regions.c +++ b/soc/arm/nxp_s32/s32k/mpu_regions.c @@ -6,7 +6,7 @@ #include #include -#include "../../common/cortex_m/arm_mpu_mem_cfg.h" +#include #if !defined(CONFIG_XIP) extern char _rom_attr[]; diff --git a/soc/arm/st_stm32/stm32h7/mpu_regions.c b/soc/arm/st_stm32/stm32h7/mpu_regions.c index e253d70c7ae..16706e325eb 100644 --- a/soc/arm/st_stm32/stm32h7/mpu_regions.c +++ b/soc/arm/st_stm32/stm32h7/mpu_regions.c @@ -5,7 +5,7 @@ */ #include -#include "../../common/cortex_m/arm_mpu_mem_cfg.h" +#include static const struct arm_mpu_region mpu_regions[] = { MPU_REGION_ENTRY("FLASH", CONFIG_FLASH_BASE_ADDRESS,