From aef7260c96e22007d806c794c5511bb7980088db Mon Sep 17 00:00:00 2001 From: Giovanni Di Sirio Date: Tue, 16 Nov 2021 14:27:19 +0000 Subject: [PATCH] Fixed shell regression because chCoreGetStatusX() change. git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@15094 27425a3e-05d8-49a3-a47f-9c15f0e5edd8 --- os/various/shell/shell_cmd.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/os/various/shell/shell_cmd.c b/os/various/shell/shell_cmd.c index faa682b8b..df85e3ad8 100644 --- a/os/various/shell/shell_cmd.c +++ b/os/various/shell/shell_cmd.c @@ -130,6 +130,7 @@ static void cmd_systime(BaseSequentialStream *chp, int argc, char *argv[]) { #if (SHELL_CMD_MEM_ENABLED == TRUE) || defined(__DOXYGEN__) static void cmd_mem(BaseSequentialStream *chp, int argc, char *argv[]) { size_t n, total, largest; + memory_region_t region; (void)argv; if (argc > 0) { @@ -137,7 +138,8 @@ static void cmd_mem(BaseSequentialStream *chp, int argc, char *argv[]) { return; } n = chHeapStatus(NULL, &total, &largest); - chprintf(chp, "core free memory : %u bytes" SHELL_NEWLINE_STR, chCoreGetStatusX()); + chCoreGetStatusX(®ion); + chprintf(chp, "core free memory : %u bytes" SHELL_NEWLINE_STR, region.size); chprintf(chp, "heap fragments : %u" SHELL_NEWLINE_STR, n); chprintf(chp, "heap free total : %u bytes" SHELL_NEWLINE_STR, total); chprintf(chp, "heap free largest: %u bytes" SHELL_NEWLINE_STR, largest);