1 /* 2 * Copyright (c) 2020 Lexmark International, Inc. 3 * Copyright (c) 2022 Qualcomm Innovation Center, Inc. 4 * 5 * SPDX-License-Identifier: Apache-2.0 6 */ 7 8 #include <tracing_user.h> 9 #include <zephyr/kernel.h> 10 sys_trace_thread_create_user(struct k_thread * thread)11void __weak sys_trace_thread_create_user(struct k_thread *thread) {} sys_trace_thread_abort_user(struct k_thread * thread)12void __weak sys_trace_thread_abort_user(struct k_thread *thread) {} sys_trace_thread_suspend_user(struct k_thread * thread)13void __weak sys_trace_thread_suspend_user(struct k_thread *thread) {} sys_trace_thread_resume_user(struct k_thread * thread)14void __weak sys_trace_thread_resume_user(struct k_thread *thread) {} sys_trace_thread_name_set_user(struct k_thread * thread)15void __weak sys_trace_thread_name_set_user(struct k_thread *thread) {} sys_trace_thread_switched_in_user(void)16void __weak sys_trace_thread_switched_in_user(void) {} sys_trace_thread_switched_out_user(void)17void __weak sys_trace_thread_switched_out_user(void) {} sys_trace_thread_info_user(struct k_thread * thread)18void __weak sys_trace_thread_info_user(struct k_thread *thread) {} sys_trace_thread_sched_ready_user(struct k_thread * thread)19void __weak sys_trace_thread_sched_ready_user(struct k_thread *thread) {} sys_trace_thread_pend_user(struct k_thread * thread)20void __weak sys_trace_thread_pend_user(struct k_thread *thread) {} sys_trace_thread_priority_set_user(struct k_thread * thread,int prio)21void __weak sys_trace_thread_priority_set_user(struct k_thread *thread, int prio) {} sys_trace_isr_enter_user(void)22void __weak sys_trace_isr_enter_user(void) {} sys_trace_isr_exit_user(void)23void __weak sys_trace_isr_exit_user(void) {} sys_trace_idle_user(void)24void __weak sys_trace_idle_user(void) {} 25 sys_trace_thread_create(struct k_thread * thread)26void sys_trace_thread_create(struct k_thread *thread) 27 { 28 sys_trace_thread_create_user(thread); 29 } 30 sys_trace_thread_abort(struct k_thread * thread)31void sys_trace_thread_abort(struct k_thread *thread) 32 { 33 sys_trace_thread_abort_user(thread); 34 } 35 sys_trace_thread_suspend(struct k_thread * thread)36void sys_trace_thread_suspend(struct k_thread *thread) 37 { 38 sys_trace_thread_suspend_user(thread); 39 } 40 sys_trace_thread_resume(struct k_thread * thread)41void sys_trace_thread_resume(struct k_thread *thread) 42 { 43 sys_trace_thread_resume_user(thread); 44 } 45 sys_trace_thread_name_set(struct k_thread * thread)46void sys_trace_thread_name_set(struct k_thread *thread) 47 { 48 sys_trace_thread_name_set_user(thread); 49 } 50 sys_trace_k_thread_switched_in(void)51void sys_trace_k_thread_switched_in(void) 52 { 53 sys_trace_thread_switched_in_user(); 54 } 55 sys_trace_k_thread_switched_out(void)56void sys_trace_k_thread_switched_out(void) 57 { 58 sys_trace_thread_switched_out_user(); 59 } 60 sys_trace_thread_info(struct k_thread * thread)61void sys_trace_thread_info(struct k_thread *thread) 62 { 63 sys_trace_thread_info_user(thread); 64 } 65 sys_trace_thread_sched_priority_set(struct k_thread * thread,int prio)66void sys_trace_thread_sched_priority_set(struct k_thread *thread, int prio) 67 { 68 sys_trace_thread_priority_set_user(thread, prio); 69 } 70 sys_trace_thread_sched_ready(struct k_thread * thread)71void sys_trace_thread_sched_ready(struct k_thread *thread) 72 { 73 sys_trace_thread_sched_ready_user(thread); 74 } 75 sys_trace_thread_pend(struct k_thread * thread)76void sys_trace_thread_pend(struct k_thread *thread) 77 { 78 sys_trace_thread_pend_user(thread); 79 } 80 sys_trace_isr_enter(void)81void sys_trace_isr_enter(void) 82 { 83 sys_trace_isr_enter_user(); 84 } 85 sys_trace_isr_exit(void)86void sys_trace_isr_exit(void) 87 { 88 sys_trace_isr_exit_user(); 89 } 90 sys_trace_idle(void)91void sys_trace_idle(void) 92 { 93 sys_trace_idle_user(); 94 } 95