summaryrefslogtreecommitdiffstats
path: root/include/memory.h
diff options
context:
space:
mode:
authorSascha Hauer <s.hauer@pengutronix.de>2018-03-14 16:14:02 +0100
committerSascha Hauer <s.hauer@pengutronix.de>2018-04-04 07:44:26 +0200
commitd4ff9c40baf3cf64565c423d6f7622f27ec48a84 (patch)
tree5d11a4d0d51da1ed725392dc23f2a17d84a238aa /include/memory.h
parent41dd040d2cc4d248a63f316f90118560437a4abc (diff)
downloadbarebox-d4ff9c40baf3cf64565c423d6f7622f27ec48a84.tar.gz
barebox-d4ff9c40baf3cf64565c423d6f7622f27ec48a84.tar.xz
common: Add functions to find free RAM
The bootm code needs to put the Kernel image and initrd into free RAM. Add some functions to find free RAM chunks to help this code. Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'include/memory.h')
-rw-r--r--include/memory.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/include/memory.h b/include/memory.h
index 165d2dc52a..56d16d20c8 100644
--- a/include/memory.h
+++ b/include/memory.h
@@ -27,4 +27,9 @@ struct resource *request_sdram_region(const char *name, resource_size_t start,
resource_size_t size);
int release_sdram_region(struct resource *res);
+void memory_bank_find_space(struct memory_bank *bank, resource_size_t *retstart,
+ resource_size_t *retend);
+int memory_bank_first_find_space(resource_size_t *retstart,
+ resource_size_t *retend);
+
#endif