diff options
author | Ahmad Fatoum <a.fatoum@pengutronix.de> | 2020-07-06 08:28:05 +0200 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2020-07-14 20:28:09 +0200 |
commit | 94fb245bd6946b24639e5c374b36bc41d8833fdb (patch) | |
tree | 31b49fc693f5e61c19fca3d7d050fe7110f86dc7 /arch/sandbox/Makefile | |
parent | 4c0809a21073af2d482683ec5327f59b31c355ff (diff) | |
download | barebox-94fb245bd6946b24639e5c374b36bc41d8833fdb.tar.gz barebox-94fb245bd6946b24639e5c374b36bc41d8833fdb.tar.xz |
sandbox: add libc memory allocator
While we typically want to reuse as much barebox functionality as
possible in sandbox, using system malloc(3) instead can be very
useful when using external memory integrity tools. This is even
useful for AddressSanitizer, because the reports resulting from
the memory poisoning API are less detailed than the built-in
support for the libc malloc(3).
Note that a barebox "heap" is still allocated upfront. It's only
used for request_sdram_region now though. Whatever is allocated by
means of malloc and memalign will be ina disjunct heap.
Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'arch/sandbox/Makefile')
-rw-r--r-- | arch/sandbox/Makefile | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/arch/sandbox/Makefile b/arch/sandbox/Makefile index c08ea0cf83..27021222dc 100644 --- a/arch/sandbox/Makefile +++ b/arch/sandbox/Makefile @@ -12,6 +12,7 @@ lds-y := $(BOARD)/barebox.lds TEXT_BASE = $(CONFIG_TEXT_BASE) KBUILD_CFLAGS += -Dmalloc=barebox_malloc -Dcalloc=barebox_calloc \ + -Dmalloc_stats=barebox_malloc_stats -Dmemalign=barebox_memalign \ -Dfree=barebox_free -Drealloc=barebox_realloc \ -Dread=barebox_read -Dwrite=barebox_write \ -Dopen=barebox_open -Dclose=barebox_close \ |