Skip to content

Commit

Permalink
sys/ps: Use correct define for TLSF information.
Browse files Browse the repository at this point in the history
The macro MODULE_TLSF_MALLOC indicates if tlsf is being used as the system-wide
allocator. MODULE_TLSF only incates if TLSF is present.
PS should check for MODULE_TLSF_MALLOC to decide if heap information should be
displayed.
  • Loading branch information
jcarrano committed May 30, 2018
1 parent b9a29ac commit 841c719
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions sys/ps/ps.c
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
#include "xtimer.h"
#endif

#ifdef MODULE_TLSF
#ifdef MODULE_TLSF_MALLOC
#include "tlsf.h"
#include "tlsf-malloc.h"
#endif
Expand Down Expand Up @@ -145,7 +145,7 @@ void ps(void)
#ifdef DEVELHELP
printf("\t%5s %-21s|%13s%6s %6i (%5i)\n", "|", "SUM", "|", "|",
overall_stacksz, overall_used);
# ifdef MODULE_TLSF
# ifdef MODULE_TLSF_MALLOC
puts("\nHeap usage:");
tlsf_walk_pool(tlsf_get_pool(_tlsf_get_global_control()), NULL, NULL);
# endif
Expand Down

0 comments on commit 841c719

Please sign in to comment.