aboutsummaryrefslogtreecommitdiffstats
path: root/os/rt/src/chsys.c
diff options
context:
space:
mode:
Diffstat (limited to 'os/rt/src/chsys.c')
-rw-r--r--os/rt/src/chsys.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/os/rt/src/chsys.c b/os/rt/src/chsys.c
index fd47664a5..a22a66482 100644
--- a/os/rt/src/chsys.c
+++ b/os/rt/src/chsys.c
@@ -132,6 +132,12 @@ void chSysInit(void) {
adjacent to its stack area.*/
currp->p_stklimit = &__main_thread_stack_base__;
#endif
+
+#if CH_DBG_STATISTICS == TRUE
+ /* Starting measurement for this thread.*/
+ chTMStartMeasurementX(&currp->p_stats);
+#endif
+
chSysEnable();
#if CH_CFG_USE_REGISTRY == TRUE