From 7d58e6263fc8578c77f604aa5b8857d9502aaf53 Mon Sep 17 00:00:00 2001 From: Huang Qi Date: Sun, 13 Mar 2022 22:52:54 +0800 Subject: [PATCH] drivers/note: Add macro guard for instrumention switch Signed-off-by: Huang Qi --- drivers/note/notelog_driver.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/drivers/note/notelog_driver.c b/drivers/note/notelog_driver.c index cba8be643f..a0a222c3bc 100644 --- a/drivers/note/notelog_driver.c +++ b/drivers/note/notelog_driver.c @@ -91,6 +91,7 @@ void sched_note_stop(FAR struct tcb_s *tcb) #endif } +#ifdef CONFIG_SCHED_INSTRUMENTATION_SWITCH void sched_note_suspend(FAR struct tcb_s *tcb) { #ifdef CONFIG_SMP @@ -132,6 +133,7 @@ void sched_note_resume(FAR struct tcb_s *tcb) #endif #endif } +#endif #ifdef CONFIG_SMP void sched_note_cpu_start(FAR struct tcb_s *tcb, int cpu) @@ -156,6 +158,7 @@ void sched_note_cpu_started(FAR struct tcb_s *tcb) #endif } +#ifdef CONFIG_SCHED_INSTRUMENTATION_SWITCH void sched_note_cpu_pause(FAR struct tcb_s *tcb, int cpu) { #if CONFIG_TASK_NAME_SIZE > 0 @@ -200,6 +203,7 @@ void sched_note_cpu_resumed(FAR struct tcb_s *tcb) #endif } #endif +#endif #ifdef CONFIG_SCHED_INSTRUMENTATION_PREEMPTION /* This does not work well... it interferes with the operation of the