diff options
Diffstat (limited to 'firmware/malloc/bmalloc.c')
-rw-r--r-- | firmware/malloc/bmalloc.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/firmware/malloc/bmalloc.c b/firmware/malloc/bmalloc.c index c83bd09628..a26c5c68a0 100644 --- a/firmware/malloc/bmalloc.c +++ b/firmware/malloc/bmalloc.c | |||
@@ -238,12 +238,13 @@ static void bmalloc_failed(size_t size) | |||
238 | #define bmalloc_failed(x) | 238 | #define bmalloc_failed(x) |
239 | #endif | 239 | #endif |
240 | 240 | ||
241 | void bmalloc_status() | 241 | void bmalloc_status(void) |
242 | { | 242 | { |
243 | #ifdef DEBUG | ||
243 | struct BlockInfo *block = blockHead; | 244 | struct BlockInfo *block = blockHead; |
244 | long mem_free = 0; | 245 | long mem_free = 0; |
245 | long mem_used = 0; | 246 | long mem_used = 0; |
246 | #if 1 | 247 | |
247 | printf("List of BLOCKS (in address order):\n"); | 248 | printf("List of BLOCKS (in address order):\n"); |
248 | while(block) { | 249 | while(block) { |
249 | printf(" START %p END %p SIZE %ld FLAG %s\n", | 250 | printf(" START %p END %p SIZE %ld FLAG %s\n", |
@@ -259,10 +260,11 @@ void bmalloc_status() | |||
259 | } | 260 | } |
260 | printf(" Used mem: %ld , free mem: %ld (total %ld)\n", | 261 | printf(" Used mem: %ld , free mem: %ld (total %ld)\n", |
261 | mem_used, mem_free, mem_used + mem_free); | 262 | mem_used, mem_free, mem_used + mem_free); |
262 | #endif | ||
263 | bmalloc_print_sizes(); | 263 | bmalloc_print_sizes(); |
264 | #endif | ||
264 | } | 265 | } |
265 | 266 | ||
267 | |||
266 | void *bmalloc(size_t size) | 268 | void *bmalloc(size_t size) |
267 | { | 269 | { |
268 | void *mem; | 270 | void *mem; |