From c51f1fc52680f68f47eed6ba838683c1b78cb91a Mon Sep 17 00:00:00 2001 From: Christian Mauderer Date: Fri, 27 Dec 2019 22:08:11 +0100 Subject: bsps/arm: Define index of the workspace entry. The imx BSP contained a hack to change the workspace entry of the MMU table. This makes the used define visible for other BSPs too so that the same hack can be used for example in raspberry pi too. --- bsps/arm/imx/start/bspstarthooks.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'bsps/arm/imx') diff --git a/bsps/arm/imx/start/bspstarthooks.c b/bsps/arm/imx/start/bspstarthooks.c index f4c5350a52..30e03dd788 100644 --- a/bsps/arm/imx/start/bspstarthooks.c +++ b/bsps/arm/imx/start/bspstarthooks.c @@ -24,8 +24,6 @@ #include -#define WORKSPACE_ENTRY_INDEX 8 - BSP_START_DATA_SECTION static arm_cp15_start_section_config imx_mmu_config_table[] = { ARMV7_CP15_START_DEFAULT_SECTIONS, @@ -68,7 +66,8 @@ BSP_START_TEXT_SECTION static void setup_mmu_and_cache(void) size -= 4; } - imx_mmu_config_table[WORKSPACE_ENTRY_INDEX].end = begin + size; + imx_mmu_config_table[ARMV7_CP15_START_WORKSPACE_ENTRY_INDEX].end = + begin + size; } } @@ -112,8 +111,8 @@ void bsp_work_area_initialize(void) uintptr_t begin; uintptr_t end; - begin = imx_mmu_config_table[WORKSPACE_ENTRY_INDEX].begin; - end = imx_mmu_config_table[WORKSPACE_ENTRY_INDEX].end; + begin = imx_mmu_config_table[ARMV7_CP15_START_WORKSPACE_ENTRY_INDEX].begin; + end = imx_mmu_config_table[ARMV7_CP15_START_WORKSPACE_ENTRY_INDEX].end; bsp_work_area_initialize_default((void *) begin, end - begin); } -- cgit v1.2.3