summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--zephyr/shim/src/tasks.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/zephyr/shim/src/tasks.c b/zephyr/shim/src/tasks.c
index 709af852c0..2f1fec16d6 100644
--- a/zephyr/shim/src/tasks.c
+++ b/zephyr/shim/src/tasks.c
@@ -6,6 +6,7 @@
#include <kernel.h>
#include <init.h>
#include <sys/atomic.h>
+#include <shell/shell.h>
#include "common.h"
#include "timer.h"
@@ -342,3 +343,11 @@ inline int in_interrupt_context(void)
{
return k_is_in_isr();
}
+
+#if IS_ENABLED(CONFIG_KERNEL_SHELL) && IS_ENABLED(CONFIG_THREAD_MONITOR)
+static int taskinfo(const struct shell *shell, size_t argc, char **argv)
+{
+ return shell_execute_cmd(shell, "kernel threads");
+}
+SHELL_CMD_REGISTER(taskinfo, NULL, "Threads statistics", taskinfo);
+#endif