implement minimalistic talloc_report(); add 't' command on UART

This helps when debugging the firmware, as it shows the current
utliization of the 10-msgb-talloc pool.

Change-Id: Ib10c4396cd4c9c4a6257cf45886e367214787927
Related: OS#4251
This commit is contained in:
Harald Welte
2019-12-14 21:11:39 +01:00
parent 7c1d85eb4d
commit 63c9e1f402
3 changed files with 21 additions and 0 deletions

View File

@@ -230,6 +230,7 @@ void board_exec_dbg_cmd(int ch)
printf("\t2\tGenerate 1ms reset pulse on WWAN2\n\r");
printf("\t!\tSwitch Channel A from physical -> remote\n\r");
printf("\t@\tSwitch Channel B from physical -> remote\n\r");
printf("\tt\t(pseudo)talloc report\n\r");
break;
case 'R':
printf("Asking NVIC to reset us\n\r");
@@ -292,6 +293,9 @@ void board_exec_dbg_cmd(int ch)
case '@':
sim_switch_use_physical(0, 0);
break;
case 't':
talloc_report(NULL, stdout);
break;
default:
if (!qmod_sam3_is_12())
printf("Unknown command '%c'\n\r", ch);