diff --git a/src/modules/systemlib/cpuload.c b/src/modules/systemlib/cpuload.c index b41896abd9..ffbeb608b5 100644 --- a/src/modules/systemlib/cpuload.c +++ b/src/modules/systemlib/cpuload.c @@ -78,8 +78,6 @@ void cpuload_initialize_once() system_load.tasks[i].valid = false; } - uint64_t now = hrt_absolute_time(); - int static_tasks_count = 2; // there are at least 2 threads that should be initialized statically - "idle" and "init" #ifdef CONFIG_PAGING @@ -94,7 +92,6 @@ void cpuload_initialize_once() // perform static initialization of "system" threads for (system_load.total_count = 0; system_load.total_count < static_tasks_count; system_load.total_count++) { - system_load.tasks[system_load.total_count].start_time = now; system_load.tasks[system_load.total_count].total_runtime = 0; system_load.tasks[system_load.total_count].curr_start_time = 0; system_load.tasks[system_load.total_count].tcb = sched_gettcb( @@ -111,7 +108,6 @@ void sched_note_start(FAR struct tcb_s *tcb) for (i = 1; i < CONFIG_MAX_TASKS; i++) { if (!system_load.tasks[i].valid) { /* slot is available */ - system_load.tasks[i].start_time = hrt_absolute_time(); system_load.tasks[i].total_runtime = 0; system_load.tasks[i].curr_start_time = 0; system_load.tasks[i].tcb = tcb; diff --git a/src/modules/systemlib/cpuload.h b/src/modules/systemlib/cpuload.h index 16d132fdb8..adc60671ec 100644 --- a/src/modules/systemlib/cpuload.h +++ b/src/modules/systemlib/cpuload.h @@ -42,7 +42,6 @@ __BEGIN_DECLS struct system_load_taskinfo_s { uint64_t total_runtime; ///< Runtime since start (start_time - total_runtime)/(start_time - current_time) = load uint64_t curr_start_time; ///< Start time of the current scheduling slot - uint64_t start_time; ///< FIRST start time of task FAR struct tcb_s *tcb; ///< bool valid; ///< Task is currently active / valid };