[U-Boot] where is malloc()?

I can find malloc.h describing that it uses a specific malloc. But I can't seem to find where the u-boot source keeps the malloc implementation.
I see that in include/_exports.h it is defined:
EXPORT_FUNC(malloc)
Also there seems to be a dlmalloc.c that should define a void* malloc(size) function but I can't seem to find it in here. Is there some macro magic here?
-- View this message in context: http://u-boot.10912.n7.nabble.com/where-is-malloc-tp246389.html Sent from the U-Boot mailing list archive at Nabble.com.

depending on your config it's either in common/malloc_simple.c (#define malloc malloc_simple) or in common/dlmalloc.c (Void_t* mALLOc(size_t bytes) and # define mALLOc malloc).
Michael
On Fri, Feb 19, 2016 at 2:52 AM, quantumlight peter.feifan.chen@gmail.com wrote:
I can find malloc.h describing that it uses a specific malloc. But I can't seem to find where the u-boot source keeps the malloc implementation.
I see that in include/_exports.h it is defined:
EXPORT_FUNC(malloc)
Also there seems to be a dlmalloc.c that should define a void* malloc(size) function but I can't seem to find it in here. Is there some macro magic here?
-- View this message in context: http://u-boot.10912.n7.nabble.com/where-is-malloc-tp246389.html Sent from the U-Boot mailing list archive at Nabble.com. _______________________________________________ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot

Thanks I see it now.
-- View this message in context: http://u-boot.10912.n7.nabble.com/where-is-malloc-tp246389p246393.html Sent from the U-Boot mailing list archive at Nabble.com.
participants (2)
-
Michael Zimmermann
-
quantumlight