From: Thierry Reding <treding@nvidia.com>
Date: Tue, 26 Aug 2014 15:34:22 +0000 (+0200)
Subject: malloc: Output region when debugging
X-Git-Tag: v2025.01-rc5-pxa1908~14313^2~2
X-Git-Url: http://git.dujemihanovic.xyz/img/static/gitweb.css?a=commitdiff_plain;h=868de51ddee75d65f3ca4235f97900410f424def;p=u-boot.git

malloc: Output region when debugging

When DEBUG is set, output memory region used for malloc().

Signed-off-by: Thierry Reding <treding@nvidia.com>
Acked-by: Simon Glass <sjg@chromium.org>
---

diff --git a/common/dlmalloc.c b/common/dlmalloc.c
index d87834df67..991229d5f7 100644
--- a/common/dlmalloc.c
+++ b/common/dlmalloc.c
@@ -1533,6 +1533,9 @@ void mem_malloc_init(ulong start, ulong size)
 	mem_malloc_end = start + size;
 	mem_malloc_brk = start;
 
+	debug("using memory %#lx-%#lx for malloc()\n", mem_malloc_start,
+	      mem_malloc_end);
+
 	memset((void *)mem_malloc_start, 0, size);
 
 	malloc_bin_reloc();