aboutsummaryrefslogtreecommitdiff
path: root/task.c
diff options
context:
space:
mode:
Diffstat (limited to 'task.c')
-rw-r--r--task.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/task.c b/task.c
index e156940..b0028e7 100644
--- a/task.c
+++ b/task.c
@@ -81,7 +81,7 @@ static tcb_t *cur_task = NULL;
#define STACK_GUARD_WORD 0x55AA5A5A
-#ifdef TASK_METRICS
+#ifdef DO_TASK_METRICS
static uint32_t tick_start = 0;
static uint32_t tick_prev = 0;
static uint32_t tick_idle = 0;
@@ -188,7 +188,7 @@ void task_yield(void)
if (tail == NULL)
return;
-#ifdef TASK_METRICS
+#ifdef DO_TASK_METRICS
uint32_t tick0 = HAL_GetTick();
#endif
@@ -209,7 +209,7 @@ void task_yield(void)
* } while (next == NULL);
*/
-#ifdef TASK_METRICS
+#ifdef DO_TASK_METRICS
uint32_t tick = HAL_GetTick();
tick_idle += (tick - tick0);
if (tick_start == 0)
@@ -381,7 +381,7 @@ void task_mutex_unlock(task_mutex_t *mutex)
mutex->locked = 0;
}
-#ifdef TASK_METRICS
+#ifdef DO_TASK_METRICS
void task_get_metrics(struct task_metrics *tm)
{
if (tm != NULL) {