Commit 905949190d4df7fc5b7c4f3e96adf219e65cad78
Committed by
Tom Rini
1 parent
db910353a1
Exists in
v2017.01-smarct4x
and in
37 other branches
Make export interface support CONFIG_SYS_MALLOC_SIMPLE
When CONFIG_SYS_MALLOC_SIMPLE is defined, free() is a static inline. Make sure that the export interface still builds in this case. Signed-off-by: Simon Glass <sjg@chromium.org>
Showing 2 changed files with 4 additions and 0 deletions Side-by-side Diff
include/_exports.h
... | ... | @@ -23,7 +23,9 @@ |
23 | 23 | EXPORT_FUNC(dummy, void, free_hdlr, void) |
24 | 24 | #endif |
25 | 25 | EXPORT_FUNC(malloc, void *, malloc, size_t) |
26 | +#ifndef CONFIG_SYS_MALLOC_SIMPLE | |
26 | 27 | EXPORT_FUNC(free, void, free, void *) |
28 | +#endif | |
27 | 29 | EXPORT_FUNC(udelay, void, udelay, unsigned long) |
28 | 30 | EXPORT_FUNC(get_timer, unsigned long, get_timer, unsigned long) |
29 | 31 | EXPORT_FUNC(vprintf, int, vprintf, const char *, va_list) |
include/exports.h
... | ... | @@ -15,7 +15,9 @@ |
15 | 15 | void install_hdlr(int, interrupt_handler_t, void*); |
16 | 16 | void free_hdlr(int); |
17 | 17 | void *malloc(size_t); |
18 | +#ifndef CONFIG_SYS_MALLOC_SIMPLE | |
18 | 19 | void free(void*); |
20 | +#endif | |
19 | 21 | void __udelay(unsigned long); |
20 | 22 | unsigned long get_timer(unsigned long); |
21 | 23 | int vprintf(const char *, va_list); |