From 281996110c1f42b5476e43040798cb38169b6119 Mon Sep 17 00:00:00 2001 From: Simon Glass Date: Wed, 13 Jul 2022 06:06:58 -0600 Subject: addrmap: Support on sandbox Update this feature so that it works on sandbox, using a basic identity mapping. This allows us to run the 'ut addrmap' test. Also fix up the test to use the correct macros to access the linker list, so that the 'ut addrmap' command actually works. Signed-off-by: Simon Glass --- board/sandbox/sandbox.c | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'board/sandbox/sandbox.c') diff --git a/board/sandbox/sandbox.c b/board/sandbox/sandbox.c index e054f300c4..ca9a2ca5b1 100644 --- a/board/sandbox/sandbox.c +++ b/board/sandbox/sandbox.c @@ -4,6 +4,7 @@ */ #include +#include #include #include #include @@ -155,3 +156,11 @@ int board_late_init(void) return 0; } #endif + +int init_addr_map(void) +{ + if (IS_ENABLED(CONFIG_ADDR_MAP)) + addrmap_set_entry(0, 0, CONFIG_SYS_SDRAM_SIZE, 0); + + return 0; +} -- cgit v1.2.3