tracing: Allow disabling idle traces
This change allows for enabling/disabling the idle traces by setting the CONFIG_TRACING_IDLE config. Signed-off-by: Krzysztof Sychla <ksychla@antmicro.com>
This commit is contained in:
parent
f503313fdf
commit
dcdc7d315e
@ -354,6 +354,12 @@ config TRACING_GPIO
|
||||
help
|
||||
Enable tracing GPIO.
|
||||
|
||||
config TRACING_IDLE
|
||||
bool "Tracing Idle"
|
||||
default y
|
||||
help
|
||||
Enable tracing Idle state.
|
||||
|
||||
endmenu # Tracing Configuration
|
||||
|
||||
endif
|
||||
|
||||
@ -189,7 +189,9 @@ void sys_trace_isr_exit_to_scheduler(void)
|
||||
|
||||
void sys_trace_idle(void)
|
||||
{
|
||||
#ifdef CONFIG_TRACING_IDLE
|
||||
ctf_top_idle();
|
||||
#endif
|
||||
if (IS_ENABLED(CONFIG_CPU_LOAD)) {
|
||||
cpu_load_on_enter_idle();
|
||||
}
|
||||
|
||||
@ -64,7 +64,9 @@ void sys_trace_isr_exit_to_scheduler(void)
|
||||
|
||||
void sys_trace_idle(void)
|
||||
{
|
||||
#ifdef CONFIG_TRACING_IDLE
|
||||
SEGGER_SYSVIEW_OnIdle();
|
||||
#endif
|
||||
|
||||
if (IS_ENABLED(CONFIG_CPU_LOAD)) {
|
||||
cpu_load_on_enter_idle();
|
||||
|
||||
@ -201,12 +201,16 @@ void sys_trace_isr_exit_to_scheduler(void)
|
||||
|
||||
void sys_trace_idle(void)
|
||||
{
|
||||
#ifdef CONFIG_TRACING_IDLE
|
||||
TRACING_STRING("%s\n", __func__);
|
||||
#endif
|
||||
}
|
||||
|
||||
void sys_trace_idle_exit(void)
|
||||
{
|
||||
#ifdef CONFIG_TRACING_IDLE
|
||||
TRACING_STRING("%s\n", __func__);
|
||||
#endif
|
||||
}
|
||||
|
||||
void sys_trace_k_condvar_broadcast_enter(struct k_condvar *condvar)
|
||||
|
||||
Loading…
Reference in New Issue
Block a user