From 4d3fa001e0891aa5a71b8547b0cb3f8f1bae4393 Mon Sep 17 00:00:00 2001 From: Stefan Kalkowski Date: Thu, 27 Nov 2014 09:45:45 +0100 Subject: [PATCH] hw: remove memory region duplicate (fix #1304) On the Versatile Express Cortex A9x4 platform the first memory region 0x0 - 0x4000000 is a hardware remapped memory area, containing flash and DDR RAM copies and thus should not be added in addition to all DDR RAM regions and the SRAM region. --- .../include/platform/vea9x4/drivers/trustzone.h | 4 ++-- .../src/core/spec/vea9x4/platform_support.cc | 3 +-- .../include/platform/vea9x4/drivers/board_base.h | 14 ++++++-------- 3 files changed, 9 insertions(+), 12 deletions(-) diff --git a/repos/base-hw/include/platform/vea9x4/drivers/trustzone.h b/repos/base-hw/include/platform/vea9x4/drivers/trustzone.h index 39afa8fae..e1e824719 100644 --- a/repos/base-hw/include/platform/vea9x4/drivers/trustzone.h +++ b/repos/base-hw/include/platform/vea9x4/drivers/trustzone.h @@ -20,8 +20,8 @@ namespace Trustzone { enum { - SECURE_RAM_BASE = Genode::Board_base::RAM_3_BASE, - SECURE_RAM_SIZE = Genode::Board_base::RAM_3_SIZE, + SECURE_RAM_BASE = Genode::Board_base::RAM_2_BASE, + SECURE_RAM_SIZE = Genode::Board_base::RAM_2_SIZE, NONSECURE_RAM_BASE = 0x80000000, NONSECURE_RAM_SIZE = 0x20000000, }; diff --git a/repos/base-hw/src/core/spec/vea9x4/platform_support.cc b/repos/base-hw/src/core/spec/vea9x4/platform_support.cc index 4c341acf1..1511a89dc 100644 --- a/repos/base-hw/src/core/spec/vea9x4/platform_support.cc +++ b/repos/base-hw/src/core/spec/vea9x4/platform_support.cc @@ -26,8 +26,7 @@ Native_region * Platform::_ram_regions(unsigned const i) { { Board::RAM_0_BASE, Board::RAM_0_SIZE }, { Board::RAM_1_BASE, Board::RAM_1_SIZE }, - { Board::RAM_2_BASE, Board::RAM_2_SIZE }, - { Board::RAM_3_BASE, Board::RAM_3_SIZE } + { Board::RAM_2_BASE, Board::RAM_2_SIZE } }; return i < sizeof(_regions)/sizeof(_regions[0]) ? &_regions[i] : 0; } diff --git a/repos/base/include/platform/vea9x4/drivers/board_base.h b/repos/base/include/platform/vea9x4/drivers/board_base.h index 62162c175..de7e0e4c6 100644 --- a/repos/base/include/platform/vea9x4/drivers/board_base.h +++ b/repos/base/include/platform/vea9x4/drivers/board_base.h @@ -32,14 +32,12 @@ namespace Genode MMIO_1_SIZE = 0x04000000, /* RAM */ - RAM_0_BASE = 0x00000000, - RAM_0_SIZE = 0x04000000, - RAM_1_BASE = 0x60000000, - RAM_1_SIZE = 0x20000000, - RAM_2_BASE = 0x84000000, - RAM_2_SIZE = 0x1c000000, - RAM_3_BASE = 0x48000000, - RAM_3_SIZE = 0x02000000, + RAM_0_BASE = 0x60000000, + RAM_0_SIZE = 0x20000000, + RAM_1_BASE = 0x84000000, + RAM_1_SIZE = 0x1c000000, + RAM_2_BASE = 0x48000000, + RAM_2_SIZE = 0x02000000, /* UART */ PL011_0_MMIO_BASE = MMIO_0_BASE + 0x9000,