summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2015-03-03 08:03:01 -0700
committerTom Rini <trini@konsulko.com>2015-03-04 14:55:04 -0500
commit905949190d4df7fc5b7c4f3e96adf219e65cad78 (patch)
treefe24d04428c8dfad404539e468f596846defdabf
parentdb910353a126d84fe8dff7a694ea792f50fcfb6a (diff)
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>
-rw-r--r--include/_exports.h2
-rw-r--r--include/exports.h2
2 files changed, 4 insertions, 0 deletions
diff --git a/include/_exports.h b/include/_exports.h
index 594470328ea..279017e87f6 100644
--- a/include/_exports.h
+++ b/include/_exports.h
@@ -23,7 +23,9 @@
EXPORT_FUNC(dummy, void, free_hdlr, void)
#endif
EXPORT_FUNC(malloc, void *, malloc, size_t)
+#ifndef CONFIG_SYS_MALLOC_SIMPLE
EXPORT_FUNC(free, void, free, void *)
+#endif
EXPORT_FUNC(udelay, void, udelay, unsigned long)
EXPORT_FUNC(get_timer, unsigned long, get_timer, unsigned long)
EXPORT_FUNC(vprintf, int, vprintf, const char *, va_list)
diff --git a/include/exports.h b/include/exports.h
index 205affe72d7..1a01e430bbc 100644
--- a/include/exports.h
+++ b/include/exports.h
@@ -15,7 +15,9 @@ int printf(const char* fmt, ...);
void install_hdlr(int, interrupt_handler_t, void*);
void free_hdlr(int);
void *malloc(size_t);
+#ifndef CONFIG_SYS_MALLOC_SIMPLE
void free(void*);
+#endif
void __udelay(unsigned long);
unsigned long get_timer(unsigned long);
int vprintf(const char *, va_list);