summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2017-03-08 10:34:24 +0100
committerSebastian Huber <sebastian.huber@embedded-brains.de>2017-03-08 10:35:36 +0100
commit6584eb2830b179e77da54f41388f57575315a2e8 (patch)
treec010bd4254c76a992de0c0e7a5bc6efaac304c7f
parentbsps: Provide <bsp/fdt.h> for every BSP (diff)
downloadrtems-6584eb2830b179e77da54f41388f57575315a2e8.tar.bz2
bsp/qoriq: Fix memory configuration
Take nocache section into account which may reside after the workspace.
-rw-r--r--c/src/lib/libbsp/powerpc/qoriq/startup/mmu-config.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/c/src/lib/libbsp/powerpc/qoriq/startup/mmu-config.c b/c/src/lib/libbsp/powerpc/qoriq/startup/mmu-config.c
index 3c12be84fb..3f385aa999 100644
--- a/c/src/lib/libbsp/powerpc/qoriq/startup/mmu-config.c
+++ b/c/src/lib/libbsp/powerpc/qoriq/startup/mmu-config.c
@@ -179,7 +179,12 @@ static void TEXT config_fdt_adjust(void)
size = MIN(size, 0x80000000U);
- if (begin == 0 && size > (uintptr_t) bsp_section_work_end) {
+ if (
+ begin == 0
+ && size > (uintptr_t) bsp_section_work_end
+ && (uintptr_t) bsp_section_nocache_end
+ < (uintptr_t) bsp_section_work_end
+ ) {
config[WORKSPACE_ENTRY_INDEX].size += (uintptr_t) size
- (uintptr_t) bsp_section_work_end;
}