tracing_test.h 41 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663
  1. /*
  2. * Copyright (c) 2021 Intel corporation
  3. *
  4. * SPDX-License-Identifier: Apache-2.0
  5. */
  6. #ifndef ZEPHYR_TRACE_TEST_H
  7. #define ZEPHYR_TRACE_TEST_H
  8. #include <kernel.h>
  9. #include <init.h>
  10. #define sys_port_trace_k_thread_foreach_enter() sys_trace_k_thread_foreach_enter(user_cb, user_data)
  11. #define sys_port_trace_k_thread_foreach_exit() sys_trace_k_thread_foreach_exit(user_cb, user_data)
  12. #define sys_port_trace_k_thread_foreach_unlocked_enter() \
  13. sys_trace_k_thread_foreach_unlocked_enter(user_cb, user_data)
  14. #define sys_port_trace_k_thread_foreach_unlocked_exit() \
  15. sys_trace_k_thread_foreach_unlocked_exit(user_cb, user_data)
  16. #define sys_port_trace_k_thread_create(new_thread) \
  17. sys_trace_k_thread_create(new_thread, stack_size, prio)
  18. #define sys_port_trace_k_thread_user_mode_enter() \
  19. sys_trace_k_thread_user_mode_enter(entry, p1, p2, p3)
  20. #define sys_port_trace_k_thread_heap_assign(thread, heap) \
  21. sys_trace_k_thread_heap_assign(thread, heap)
  22. #define sys_port_trace_k_thread_join_enter(thread, timeout) \
  23. sys_trace_k_thread_join_blocking(thread, timeout)
  24. #define sys_port_trace_k_thread_join_blocking(thread, timeout) \
  25. sys_trace_k_thread_join_blocking(thread, timeout)
  26. #define sys_port_trace_k_thread_join_exit(thread, timeout, ret) \
  27. sys_trace_k_thread_join_exit(thread, timeout, ret)
  28. #define sys_port_trace_k_thread_sleep_enter(timeout) sys_trace_k_thread_sleep_enter(timeout)
  29. #define sys_port_trace_k_thread_sleep_exit(timeout, ret) sys_trace_k_thread_sleep_exit(timeout, ret)
  30. #define sys_port_trace_k_thread_msleep_enter(ms) sys_trace_k_thread_msleep_enter(ms)
  31. #define sys_port_trace_k_thread_msleep_exit(ms, ret) sys_trace_k_thread_msleep_exit(ms, ret)
  32. #define sys_port_trace_k_thread_usleep_enter(us) sys_trace_k_thread_usleep_enter(us)
  33. #define sys_port_trace_k_thread_usleep_exit(us, ret) sys_trace_k_thread_usleep_exit(us, ret)
  34. #define sys_port_trace_k_thread_busy_wait_enter(usec_to_wait)
  35. #define sys_port_trace_k_thread_busy_wait_exit(usec_to_wait)
  36. #define sys_port_trace_k_thread_yield() sys_trace_k_thread_yield()
  37. #define sys_port_trace_k_thread_wakeup(thread) sys_trace_k_thread_wakeup(thread)
  38. #define sys_port_trace_k_thread_start(thread) sys_trace_k_thread_start(thread)
  39. #define sys_port_trace_k_thread_abort(thread) sys_trace_k_thread_abort(thread)
  40. #define sys_port_trace_k_thread_priority_set(thread) sys_trace_k_thread_priority_set(thread)
  41. #define sys_port_trace_k_thread_suspend_enter(thread) sys_trace_k_thread_suspend(thread)
  42. #define sys_port_trace_k_thread_suspend_exit(thread)
  43. #define sys_port_trace_k_thread_resume_enter(thread) sys_trace_k_thread_resume(thread)
  44. #define sys_port_trace_k_thread_sched_lock(...) sys_trace_k_thread_sched_lock()
  45. #define sys_port_trace_k_thread_sched_unlock(...) sys_trace_k_thread_sched_unlock()
  46. #define sys_port_trace_k_thread_name_set(thread, ret) sys_trace_k_thread_name_set(thread, ret)
  47. #define sys_port_trace_k_thread_switched_out() sys_trace_k_thread_switched_out()
  48. #define sys_port_trace_k_thread_switched_in() sys_trace_k_thread_switched_in()
  49. #define sys_port_trace_k_thread_info(thread) sys_trace_k_thread_info(thread)
  50. #define sys_port_trace_k_thread_sched_wakeup(thread) sys_trace_k_thread_sched_wakeup(thread)
  51. #define sys_port_trace_k_thread_sched_abort(thread) sys_trace_k_thread_sched_abort(thread)
  52. #define sys_port_trace_k_thread_sched_priority_set(thread, prio) \
  53. sys_trace_k_thread_sched_set_priority(thread, prio)
  54. #define sys_port_trace_k_thread_sched_ready(thread) sys_trace_k_thread_sched_ready(thread)
  55. #define sys_port_trace_k_thread_sched_pend(thread) sys_trace_k_thread_sched_pend(thread)
  56. #define sys_port_trace_k_thread_sched_resume(thread) sys_trace_k_thread_sched_resume(thread)
  57. #define sys_port_trace_k_thread_sched_suspend(thread) sys_trace_k_thread_sched_suspend(thread)
  58. #define sys_port_trace_k_work_init(work)
  59. #define sys_port_trace_k_work_submit_to_queue_enter(queue, work)
  60. #define sys_port_trace_k_work_submit_to_queue_exit(queue, work, ret)
  61. #define sys_port_trace_k_work_submit_enter(work)
  62. #define sys_port_trace_k_work_submit_exit(work, ret)
  63. #define sys_port_trace_k_work_flush_enter(work)
  64. #define sys_port_trace_k_work_flush_blocking(work, timeout)
  65. #define sys_port_trace_k_work_flush_exit(work, ret)
  66. #define sys_port_trace_k_work_cancel_enter(work)
  67. #define sys_port_trace_k_work_cancel_exit(work, ret)
  68. #define sys_port_trace_k_work_cancel_sync_enter(work, sync)
  69. #define sys_port_trace_k_work_cancel_sync_blocking(work, sync)
  70. #define sys_port_trace_k_work_cancel_sync_exit(work, sync, ret)
  71. #define sys_port_trace_k_work_queue_init(queue)
  72. #define sys_port_trace_k_work_queue_start_enter(queue)
  73. #define sys_port_trace_k_work_queue_start_exit(queue)
  74. #define sys_port_trace_k_work_queue_drain_enter(queue)
  75. #define sys_port_trace_k_work_queue_drain_exit(queue, ret)
  76. #define sys_port_trace_k_work_queue_unplug_enter(queue)
  77. #define sys_port_trace_k_work_queue_unplug_exit(queue, ret)
  78. #define sys_port_trace_k_work_delayable_init(dwork)
  79. #define sys_port_trace_k_work_schedule_for_queue_enter(queue, dwork, delay)
  80. #define sys_port_trace_k_work_schedule_for_queue_exit(queue, dwork, delay, ret)
  81. #define sys_port_trace_k_work_schedule_enter(dwork, delay)
  82. #define sys_port_trace_k_work_schedule_exit(dwork, delay, ret)
  83. #define sys_port_trace_k_work_reschedule_for_queue_enter(queue, dwork, delay)
  84. #define sys_port_trace_k_work_reschedule_for_queue_exit(queue, dwork, delay, ret)
  85. #define sys_port_trace_k_work_reschedule_enter(dwork, delay)
  86. #define sys_port_trace_k_work_reschedule_exit(dwork, delay, ret)
  87. #define sys_port_trace_k_work_flush_delayable_enter(dwork, sync)
  88. #define sys_port_trace_k_work_flush_delayable_exit(dwork, sync, ret)
  89. #define sys_port_trace_k_work_cancel_delayable_enter(dwork)
  90. #define sys_port_trace_k_work_cancel_delayable_exit(dwork, ret)
  91. #define sys_port_trace_k_work_cancel_delayable_sync_enter(dwork, sync)
  92. #define sys_port_trace_k_work_cancel_delayable_sync_exit(dwork, sync, ret)
  93. #define sys_port_trace_k_work_poll_init_enter(work)
  94. #define sys_port_trace_k_work_poll_init_exit(work)
  95. #define sys_port_trace_k_work_poll_submit_to_queue_enter(work_q, work, timeout)
  96. #define sys_port_trace_k_work_poll_submit_to_queue_blocking(work_q, work, timeout)
  97. #define sys_port_trace_k_work_poll_submit_to_queue_exit(work_q, work, timeout, ret)
  98. #define sys_port_trace_k_work_poll_submit_enter(work, timeout)
  99. #define sys_port_trace_k_work_poll_submit_exit(work, timeout, ret)
  100. #define sys_port_trace_k_work_poll_cancel_enter(work)
  101. #define sys_port_trace_k_work_poll_cancel_exit(work, ret)
  102. #define sys_port_trace_k_poll_api_event_init(event)
  103. #define sys_port_trace_k_poll_api_poll_enter(events)
  104. #define sys_port_trace_k_poll_api_poll_exit(events, ret)
  105. #define sys_port_trace_k_poll_api_signal_init(signal)
  106. #define sys_port_trace_k_poll_api_signal_reset(signal)
  107. #define sys_port_trace_k_poll_api_signal_check(signal)
  108. #define sys_port_trace_k_poll_api_signal_raise(signal, ret)
  109. #define sys_port_trace_k_sem_init(sem, ret) sys_trace_k_sem_init(sem, ret)
  110. #define sys_port_trace_k_sem_give_enter(sem) sys_trace_k_sem_give_enter(sem)
  111. #define sys_port_trace_k_sem_give_exit(sem)
  112. #define sys_port_trace_k_sem_take_enter(sem, timeout) sys_trace_k_sem_take_enter(sem, timeout)
  113. #define sys_port_trace_k_sem_take_blocking(sem, timeout) sys_trace_k_sem_take_blocking(sem, timeout)
  114. #define sys_port_trace_k_sem_take_exit(sem, timeout, ret) \
  115. sys_trace_k_sem_take_exit(sem, timeout, ret)
  116. #define sys_port_trace_k_sem_reset(sem) sys_trace_k_sem_reset(sem)
  117. #define sys_port_trace_k_mutex_init(mutex, ret) sys_trace_k_mutex_init(mutex, ret)
  118. #define sys_port_trace_k_mutex_lock_enter(mutex, timeout) \
  119. sys_trace_k_mutex_lock_enter(mutex, timeout)
  120. #define sys_port_trace_k_mutex_lock_blocking(mutex, timeout) \
  121. sys_trace_k_mutex_lock_blocking(mutex, timeout)
  122. #define sys_port_trace_k_mutex_lock_exit(mutex, timeout, ret) \
  123. sys_trace_k_mutex_lock_exit(mutex, timeout, ret)
  124. #define sys_port_trace_k_mutex_unlock_enter(mutex) sys_trace_k_mutex_unlock_enter(mutex)
  125. #define sys_port_trace_k_mutex_unlock_exit(mutex, ret) sys_trace_k_mutex_unlock_exit(mutex, ret)
  126. #define sys_port_trace_k_condvar_init(condvar, ret) sys_trace_k_condvar_init(condvar, ret)
  127. #define sys_port_trace_k_condvar_signal_enter(condvar) sys_trace_k_condvar_signal_enter(condvar)
  128. #define sys_port_trace_k_condvar_signal_blocking(condvar, timeout) \
  129. sys_trace_k_condvar_signal_blocking(condvar)
  130. #define sys_port_trace_k_condvar_signal_exit(condvar, ret) \
  131. sys_trace_k_condvar_signal_exit(condvar, ret)
  132. #define sys_port_trace_k_condvar_broadcast_enter(condvar) \
  133. sys_trace_k_condvar_broadcast_enter(condvar)
  134. #define sys_port_trace_k_condvar_broadcast_exit(condvar, ret) \
  135. sys_trace_k_condvar_broadcast_exit(condvar, ret)
  136. #define sys_port_trace_k_condvar_wait_enter(condvar) \
  137. sys_trace_k_condvar_wait_enter(condvar, mutex, timeout)
  138. #define sys_port_trace_k_condvar_wait_exit(condvar, ret) \
  139. sys_trace_k_condvar_wait_exit(condvar, mutex, timeout, ret)
  140. #define sys_port_trace_k_queue_init(queue) sys_trace_k_queue_init(queue)
  141. #define sys_port_trace_k_queue_cancel_wait(queue) sys_trace_k_queue_cancel_wait(queue)
  142. #define sys_port_trace_k_queue_queue_insert_enter(queue, alloc) \
  143. sys_trace_k_queue_queue_insert_enter(queue, alloc, data);
  144. #define sys_port_trace_k_queue_queue_insert_blocking(queue, alloc, timeout) \
  145. sys_trace_k_queue_queue_insert_enter(queue, alloc, data);
  146. #define sys_port_trace_k_queue_queue_insert_exit(queue, alloc, ret) \
  147. sys_trace_k_queue_queue_insert_exit(queue, alloc, data, ret);
  148. #define sys_port_trace_k_queue_append_enter(queue) sys_trace_k_queue_append_enter(queue, data)
  149. #define sys_port_trace_k_queue_append_exit(queue) sys_trace_k_queue_append_exit(queue, data)
  150. #define sys_port_trace_k_queue_alloc_append_enter(queue) \
  151. sys_trace_k_queue_alloc_append_enter(queue, data)
  152. #define sys_port_trace_k_queue_alloc_append_exit(queue, ret) \
  153. sys_trace_k_queue_alloc_append_exit(queue, data, ret)
  154. #define sys_port_trace_k_queue_prepend_enter(queue) sys_trace_k_queue_prepend_enter(queue, data)
  155. #define sys_port_trace_k_queue_prepend_exit(queue) sys_trace_k_queue_prepend_exit(queue, data)
  156. #define sys_port_trace_k_queue_alloc_prepend_enter(queue) \
  157. sys_trace_k_queue_alloc_prepend_enter(queue, data)
  158. #define sys_port_trace_k_queue_alloc_prepend_exit(queue, ret) \
  159. sys_trace_k_queue_alloc_prepend_exit(queue, data, ret)
  160. #define sys_port_trace_k_queue_insert_enter(queue) sys_trace_k_queue_insert_enter(queue, prev, data)
  161. #define sys_port_trace_k_queue_insert_blocking(queue, timeout) \
  162. sys_trace_k_queue_insert_blocking(queue, prev, data)
  163. #define sys_port_trace_k_queue_insert_exit(queue) sys_trace_k_queue_insert_exit(queue, prev, data)
  164. #define sys_port_trace_k_queue_append_list_enter(queue)
  165. #define sys_port_trace_k_queue_append_list_exit(queue, ret) \
  166. sys_trace_k_queue_append_list_exit(queue, head, tail, ret)
  167. #define sys_port_trace_k_queue_merge_slist_enter(queue) \
  168. sys_trace_k_queue_merge_slist_enter(queue, list)
  169. #define sys_port_trace_k_queue_merge_slist_exit(queue, ret) \
  170. sys_trace_k_queue_merge_slist_exit(queue, list, ret)
  171. #define sys_port_trace_k_queue_get_enter(queue, timeout)
  172. #define sys_port_trace_k_queue_get_blocking(queue, timeout) \
  173. sys_trace_k_queue_get_blocking(queue, timeout)
  174. #define sys_port_trace_k_queue_get_exit(queue, timeout, ret) \
  175. sys_trace_k_queue_get_exit(queue, timeout, ret)
  176. #define sys_port_trace_k_queue_remove_enter(queue) sys_trace_k_queue_remove_enter(queue, data)
  177. #define sys_port_trace_k_queue_remove_exit(queue, ret) \
  178. sys_trace_k_queue_remove_exit(queue, data, ret)
  179. #define sys_port_trace_k_queue_unique_append_enter(queue) \
  180. sys_trace_k_queue_unique_append_enter(queue, data)
  181. #define sys_port_trace_k_queue_unique_append_exit(queue, ret) \
  182. sys_trace_k_queue_unique_append_exit(queue, data, ret)
  183. #define sys_port_trace_k_queue_peek_head(queue, ret) sys_trace_k_queue_peek_head(queue, ret)
  184. #define sys_port_trace_k_queue_peek_tail(queue, ret) sys_trace_k_queue_peek_tail(queue, ret)
  185. /* FIFO */
  186. #define sys_port_trace_k_fifo_init_enter(fifo) sys_trace_k_fifo_init_enter(fifo)
  187. #define sys_port_trace_k_fifo_init_exit(fifo) sys_trace_k_fifo_init_exit(fifo)
  188. #define sys_port_trace_k_fifo_cancel_wait_enter(fifo) sys_trace_k_fifo_cancel_wait_enter(fifo)
  189. #define sys_port_trace_k_fifo_cancel_wait_exit(fifo) sys_trace_k_fifo_cancel_wait_exit(fifo)
  190. #define sys_port_trace_k_fifo_put_enter(fifo, data) sys_trace_k_fifo_put_enter(fifo, data)
  191. #define sys_port_trace_k_fifo_put_exit(fifo, data) sys_trace_k_fifo_put_exit(fifo, data)
  192. #define sys_port_trace_k_fifo_alloc_put_enter(fifo, data) \
  193. sys_trace_k_fifo_alloc_put_enter(fifo, data)
  194. #define sys_port_trace_k_fifo_alloc_put_exit(fifo, data, ret) \
  195. sys_trace_k_fifo_alloc_put_exit(fifo, data, ret)
  196. #define sys_port_trace_k_fifo_put_list_enter(fifo, head, tail) \
  197. sys_trace_k_fifo_put_list_enter(fifo, head, tail)
  198. #define sys_port_trace_k_fifo_put_list_exit(fifo, head, tail) \
  199. sys_trace_k_fifo_put_list_exit(fifo, head, tail)
  200. #define sys_port_trace_k_fifo_put_slist_enter(fifo, list) \
  201. sys_trace_k_fifo_put_slist_enter(fifo, list)
  202. #define sys_port_trace_k_fifo_put_slist_exit(fifo, list) sys_trace_k_fifo_put_slist_exit(fifo, list)
  203. #define sys_port_trace_k_fifo_get_enter(fifo, timeout) sys_trace_k_fifo_get_enter(fifo, timeout)
  204. #define sys_port_trace_k_fifo_get_exit(fifo, timeout, ret) \
  205. sys_trace_k_fifo_get_exit(fifo, timeout, ret)
  206. #define sys_port_trace_k_fifo_peek_head_enter(fifo) sys_trace_k_fifo_peek_head_enter(fifo)
  207. #define sys_port_trace_k_fifo_peek_head_exit(fifo, ret) sys_trace_k_fifo_peek_head_exit(fifo, ret)
  208. #define sys_port_trace_k_fifo_peek_tail_enter(fifo) sys_trace_k_fifo_peek_tail_enter(fifo)
  209. #define sys_port_trace_k_fifo_peek_tail_exit(fifo, ret) sys_trace_k_fifo_peek_tail_exit(fifo, ret)
  210. /* LIFO */
  211. #define sys_port_trace_k_lifo_init_enter(lifo) sys_trace_k_lifo_init_enter(lifo)
  212. #define sys_port_trace_k_lifo_init_exit(lifo) sys_trace_k_lifo_init_exit(lifo)
  213. #define sys_port_trace_k_lifo_put_enter(lifo, data) sys_trace_k_lifo_put_enter(lifo, data)
  214. #define sys_port_trace_k_lifo_put_exit(lifo, data) sys_trace_k_lifo_put_exit(lifo, data)
  215. #define sys_port_trace_k_lifo_alloc_put_enter(lifo, data) \
  216. sys_trace_k_lifo_alloc_put_enter(lifo, data)
  217. #define sys_port_trace_k_lifo_alloc_put_exit(lifo, data, ret) \
  218. sys_trace_k_lifo_alloc_put_exit(lifo, data, ret)
  219. #define sys_port_trace_k_lifo_get_enter(lifo, timeout) sys_trace_k_lifo_get_enter(lifo, timeout)
  220. #define sys_port_trace_k_lifo_get_exit(lifo, timeout, ret) \
  221. sys_trace_k_lifo_get_exit(lifo, timeout, ret)
  222. /* Stack */
  223. #define sys_port_trace_k_stack_init(stack) sys_trace_k_stack_init(stack, buffer, num_entries)
  224. #define sys_port_trace_k_stack_alloc_init_enter(stack) \
  225. sys_trace_k_stack_alloc_init_enter(stack, num_entries)
  226. #define sys_port_trace_k_stack_alloc_init_exit(stack, ret) \
  227. sys_trace_k_stack_alloc_init_exit(stack, num_entries, ret)
  228. #define sys_port_trace_k_stack_cleanup_enter(stack) sys_trace_k_stack_cleanup_enter(stack)
  229. #define sys_port_trace_k_stack_cleanup_exit(stack, ret) sys_trace_k_stack_cleanup_exit(stack, ret)
  230. #define sys_port_trace_k_stack_push_enter(stack) sys_trace_k_stack_push_enter(stack, data)
  231. #define sys_port_trace_k_stack_push_exit(stack, ret) sys_trace_k_stack_push_exit(stack, data, ret)
  232. #define sys_port_trace_k_stack_pop_enter(stack, timeout)
  233. #define sys_port_trace_k_stack_pop_blocking(stack, timeout) \
  234. sys_trace_k_stack_pop_blocking(stack, data, timeout)
  235. #define sys_port_trace_k_stack_pop_exit(stack, timeout, ret) \
  236. sys_trace_k_stack_pop_exit(stack, data, timeout, ret)
  237. /* Message Queue */
  238. #define sys_port_trace_k_msgq_init(msgq) sys_trace_k_msgq_init(msgq)
  239. #define sys_port_trace_k_msgq_alloc_init_enter(msgq) \
  240. sys_trace_k_msgq_alloc_init_enter(msgq, msg_size, max_msgs)
  241. #define sys_port_trace_k_msgq_alloc_init_exit(msgq, ret) \
  242. sys_trace_k_msgq_alloc_init_exit(msgq, msg_size, max_msgs, ret)
  243. #define sys_port_trace_k_msgq_cleanup_enter(msgq) sys_trace_k_msgq_cleanup_enter(msgq)
  244. #define sys_port_trace_k_msgq_cleanup_exit(msgq, ret) sys_trace_k_msgq_cleanup_exit(msgq, ret)
  245. #define sys_port_trace_k_msgq_put_enter(msgq, timeout) \
  246. sys_trace_k_msgq_put_enter(msgq, data, timeout)
  247. #define sys_port_trace_k_msgq_put_blocking(msgq, timeout) \
  248. sys_trace_k_msgq_put_blocking(msgq, data, timeout)
  249. #define sys_port_trace_k_msgq_put_exit(msgq, timeout, ret) \
  250. sys_trace_k_msgq_put_exit(msgq, data, timeout, ret)
  251. #define sys_port_trace_k_msgq_get_enter(msgq, timeout) \
  252. sys_trace_k_msgq_get_enter(msgq, data, timeout)
  253. #define sys_port_trace_k_msgq_get_blocking(msgq, timeout) \
  254. sys_trace_k_msgq_get_blocking(msgq, data, timeout)
  255. #define sys_port_trace_k_msgq_get_exit(msgq, timeout, ret) \
  256. sys_trace_k_msgq_get_exit(msgq, data, timeout, ret)
  257. #define sys_port_trace_k_msgq_peek(msgq, ret) sys_trace_k_msgq_peek(msgq, data, ret)
  258. #define sys_port_trace_k_msgq_purge(msgq) sys_trace_k_msgq_purge(msgq)
  259. #define sys_port_trace_k_mbox_init(mbox) sys_trace_k_mbox_init(mbox)
  260. #define sys_port_trace_k_mbox_message_put_enter(mbox, timeout) \
  261. sys_trace_k_mbox_message_put_enter(mbox, tx_msg, timeout)
  262. #define sys_port_trace_k_mbox_message_put_blocking(mbox, timeout) \
  263. sys_trace_k_mbox_message_put_blocking(mbox, tx_msg, timeout)
  264. #define sys_port_trace_k_mbox_message_put_exit(mbox, timeout, ret) \
  265. sys_trace_k_mbox_message_put_exit(mbox, tx_msg, timeout, ret)
  266. #define sys_port_trace_k_mbox_put_enter(mbox, timeout) \
  267. sys_trace_k_mbox_put_enter(mbox, tx_msg, timeout)
  268. #define sys_port_trace_k_mbox_put_exit(mbox, timeout, ret) \
  269. sys_trace_k_mbox_put_exit(mbox, tx_msg, timeout, ret)
  270. #define sys_port_trace_k_mbox_async_put_enter(mbox, sem) sys_trace_k_mbox_async_put_enter(mbox, sem)
  271. #define sys_port_trace_k_mbox_async_put_exit(mbox, sem) sys_trace_k_mbox_async_put_exit(mbox, sem)
  272. #define sys_port_trace_k_mbox_get_enter(mbox, timeout) \
  273. sys_trace_k_mbox_get_enter(mbox, rx_msg, buffer, timeout)
  274. #define sys_port_trace_k_mbox_get_blocking(mbox, timeout) \
  275. sys_trace_k_mbox_get_blocking(mbox, rx_msg, buffer, timeout)
  276. #define sys_port_trace_k_mbox_get_exit(mbox, timeout, ret) \
  277. sys_trace_k_mbox_get_exit(mbox, rx_msg, buffer, timeout, ret)
  278. #define sys_port_trace_k_mbox_data_get(rx_msg) sys_trace_k_mbox_data_get(mbox, rx_msg, buffer)
  279. #define sys_port_trace_k_pipe_init(pipe) sys_trace_k_pipe_init(pipe, buffer, size)
  280. #define sys_port_trace_k_pipe_cleanup_enter(pipe) sys_trace_k_pipe_cleanup_enter(pipe)
  281. #define sys_port_trace_k_pipe_cleanup_exit(pipe, ret) sys_trace_k_pipe_cleanup_exit(pipe, ret)
  282. #define sys_port_trace_k_pipe_alloc_init_enter(pipe) sys_trace_k_pipe_alloc_init_enter(pipe, size)
  283. #define sys_port_trace_k_pipe_alloc_init_exit(pipe, ret) \
  284. sys_trace_k_pipe_alloc_init_exit(pipe, size, ret)
  285. #define sys_port_trace_k_pipe_put_enter(pipe, timeout) \
  286. sys_trace_k_pipe_put_enter(pipe, data, bytes_to_write, bytes_written, min_xfer, timeout)
  287. #define sys_port_trace_k_pipe_put_blocking(pipe, timeout) \
  288. sys_trace_k_pipe_put_blocking(pipe, data, bytes_to_write, bytes_written, min_xfer, timeout)
  289. #define sys_port_trace_k_pipe_put_exit(pipe, timeout, ret) \
  290. sys_trace_k_pipe_put_exit(pipe, data, bytes_to_write, bytes_written, min_xfer, timeout, ret)
  291. #define sys_port_trace_k_pipe_get_enter(pipe, timeout) \
  292. sys_trace_k_pipe_get_enter(pipe, data, bytes_to_read, bytes_read, min_xfer, timeout)
  293. #define sys_port_trace_k_pipe_get_blocking(pipe, timeout) \
  294. sys_trace_k_pipe_get_blocking(pipe, data, bytes_to_read, bytes_read, min_xfer, timeout)
  295. #define sys_port_trace_k_pipe_get_exit(pipe, timeout, ret) \
  296. sys_trace_k_pipe_get_exit(pipe, data, bytes_to_read, bytes_read, min_xfer, timeout, ret)
  297. #define sys_port_trace_k_pipe_block_put_enter(pipe, sem) \
  298. sys_trace_k_pipe_block_put_enter(pipe, block, bytes_to_write, sem)
  299. #define sys_port_trace_k_pipe_block_put_exit(pipe, sem) \
  300. sys_trace_k_pipe_block_put_exit(pipe, block, bytes_to_write, sem)
  301. #define sys_port_trace_k_heap_init(h) sys_trace_k_heap_init(h, mem, bytes)
  302. #define sys_port_trace_k_heap_aligned_alloc_enter(h, timeout) \
  303. sys_trace_k_heap_aligned_alloc_enter(h, bytes, timeout)
  304. #define sys_port_trace_k_heap_aligned_alloc_blocking(h, timeout) \
  305. sys_trace_k_heap_aligned_alloc_blocking(h, bytes, timeout)
  306. #define sys_port_trace_k_heap_aligned_alloc_exit(h, timeout, ret) \
  307. sys_trace_k_heap_aligned_alloc_exit(h, bytes, timeout, ret)
  308. #define sys_port_trace_k_heap_alloc_enter(h, timeout) \
  309. sys_trace_k_heap_alloc_enter(h, bytes, timeout)
  310. #define sys_port_trace_k_heap_alloc_exit(h, timeout, ret) \
  311. sys_trace_k_heap_alloc_exit(h, bytes, timeout, ret)
  312. #define sys_port_trace_k_heap_free(h) sys_trace_k_heap_free(h, mem)
  313. #define sys_port_trace_k_heap_sys_k_aligned_alloc_enter(heap) \
  314. sys_trace_k_heap_sys_k_aligned_alloc_enter(heap, align, size)
  315. #define sys_port_trace_k_heap_sys_k_aligned_alloc_exit(heap, ret) \
  316. sys_trace_k_heap_sys_k_aligned_alloc_exit(heap, align, size, ret)
  317. #define sys_port_trace_k_heap_sys_k_malloc_enter(heap) \
  318. sys_trace_k_heap_sys_k_malloc_enter(heap, size)
  319. #define sys_port_trace_k_heap_sys_k_malloc_exit(heap, ret) \
  320. sys_trace_k_heap_sys_k_malloc_exit(heap, size, ret)
  321. #define sys_port_trace_k_heap_sys_k_free_enter(heap) sys_trace_k_heap_sys_k_free_enter(heap)
  322. #define sys_port_trace_k_heap_sys_k_free_exit(heap) sys_trace_k_heap_sys_k_free_exit(heap)
  323. #define sys_port_trace_k_heap_sys_k_calloc_enter(heap) \
  324. sys_trace_k_heap_sys_k_calloc_enter(heap, nmemb, size)
  325. #define sys_port_trace_k_heap_sys_k_calloc_exit(heap, ret) \
  326. sys_trace_k_heap_sys_k_calloc_exit(heap, nmemb, size, ret)
  327. #define sys_port_trace_k_mem_slab_init(slab, rc) \
  328. sys_trace_k_mem_slab_init(slab, buffer, block_size, num_blocks, rc)
  329. #define sys_port_trace_k_mem_slab_alloc_enter(slab, timeout) \
  330. sys_trace_k_mem_slab_alloc_enter(slab, mem, timeout)
  331. #define sys_port_trace_k_mem_slab_alloc_blocking(slab, timeout) \
  332. sys_trace_k_mem_slab_alloc_blocking(slab, mem, timeout)
  333. #define sys_port_trace_k_mem_slab_alloc_exit(slab, timeout, ret) \
  334. sys_trace_k_mem_slab_alloc_exit(slab, mem, timeout, ret)
  335. #define sys_port_trace_k_mem_slab_free_enter(slab)
  336. #define sys_port_trace_k_mem_slab_free_exit(slab) sys_trace_k_mem_slab_free_exit(slab, mem)
  337. #define sys_port_trace_k_timer_init(timer) sys_trace_k_timer_init(timer, expiry_fn, stop_fn)
  338. #define sys_port_trace_k_timer_start(timer) sys_trace_k_timer_start(timer, duration, period)
  339. #define sys_port_trace_k_timer_stop(timer) sys_trace_k_timer_stop(timer)
  340. #define sys_port_trace_k_timer_status_sync_enter(timer)
  341. #define sys_port_trace_k_timer_status_sync_blocking(timer, timeout) \
  342. sys_trace_k_timer_status_sync_blocking(timer)
  343. #define sys_port_trace_k_timer_status_sync_exit(timer, result) \
  344. sys_trace_k_timer_status_sync_exit(timer, result)
  345. #define sys_port_trace_k_thread_abort_exit(thread) sys_trace_k_thread_abort_exit(thread)
  346. #define sys_port_trace_k_thread_abort_enter(thread) sys_trace_k_thread_abort_enter(thread)
  347. #define sys_port_trace_k_thread_resume_exit(thread) sys_trace_k_thread_resume_exit(thread)
  348. #define sys_port_trace_syscall_enter() sys_trace_syscall_enter()
  349. #define sys_port_trace_syscall_exit() sys_trace_syscall_exit()
  350. #define sys_port_trace_pm_system_suspend_enter(ticks)
  351. #define sys_port_trace_pm_system_suspend_exit(ticks, ret)
  352. #define sys_port_trace_pm_device_request_enter(dev, target_state)
  353. #define sys_port_trace_pm_device_request_exit(dev, ret)
  354. #define sys_port_trace_pm_device_enable_enter(dev)
  355. #define sys_port_trace_pm_device_enable_exit(dev)
  356. #define sys_port_trace_pm_device_disable_enter(dev)
  357. #define sys_port_trace_pm_device_disable_exit(dev)
  358. void sys_trace_syscall_enter(void);
  359. void sys_trace_syscall_exit(void);
  360. void sys_trace_idle(void);
  361. void sys_trace_isr_enter(void);
  362. void sys_trace_isr_exit(void);
  363. void sys_trace_k_thread_abort_exit(struct k_thread *thread);
  364. void sys_trace_k_thread_abort_enter(struct k_thread *thread);
  365. void sys_trace_k_thread_resume_exit(struct k_thread *thread);
  366. void sys_trace_k_thread_sched_wakeup(struct k_thread *thread);
  367. void sys_trace_k_thread_sched_abort(struct k_thread *thread);
  368. void sys_trace_k_thread_sched_set_priority(struct k_thread *thread, int prio);
  369. void sys_trace_k_thread_sched_ready(struct k_thread *thread);
  370. void sys_trace_k_thread_sched_pend(struct k_thread *thread);
  371. void sys_trace_k_thread_sched_resume(struct k_thread *thread);
  372. void sys_trace_k_thread_sched_suspend(struct k_thread *thread);
  373. void sys_trace_k_thread_foreach_enter(k_thread_user_cb_t user_cb, void *user_data);
  374. void sys_trace_k_thread_foreach_exit(k_thread_user_cb_t user_cb, void *user_data);
  375. void sys_trace_k_thread_foreach_unlocked_enter(k_thread_user_cb_t user_cb, void *user_data);
  376. void sys_trace_k_thread_foreach_unlocked_exit(k_thread_user_cb_t user_cb, void *user_data);
  377. void sys_trace_k_thread_create(struct k_thread *new_thread, size_t stack_size, int prio);
  378. void sys_trace_k_thread_user_mode_enter(k_thread_entry_t entry, void *p1, void *p2, void *p3);
  379. void sys_trace_k_thread_heap_assign(struct k_thread *thread, struct k_heap *heap);
  380. void sys_trace_k_thread_join_blocking(struct k_thread *thread, k_timeout_t timeout);
  381. void sys_trace_k_thread_join_exit(struct k_thread *thread, k_timeout_t timeout, int ret);
  382. void sys_trace_k_thread_sleep_enter(k_timeout_t timeout);
  383. void sys_trace_k_thread_sleep_exit(k_timeout_t timeout, int ret);
  384. void sys_trace_k_thread_msleep_enter(int32_t ms);
  385. void sys_trace_k_thread_msleep_exit(int32_t ms, int ret);
  386. void sys_trace_k_thread_usleep_enter(int32_t us);
  387. void sys_trace_k_thread_usleep_exit(int32_t us, int ret);
  388. void sys_trace_k_thread_yield(void);
  389. void sys_trace_k_thread_wakeup(struct k_thread *thread);
  390. void sys_trace_k_thread_abort(struct k_thread *thread);
  391. void sys_trace_k_thread_start(struct k_thread *thread);
  392. void sys_trace_k_thread_priority_set(struct k_thread *thread);
  393. void sys_trace_k_thread_suspend(struct k_thread *thread);
  394. void sys_trace_k_thread_resume(struct k_thread *thread);
  395. void sys_trace_k_thread_sched_lock(void);
  396. void sys_trace_k_thread_sched_unlock(void);
  397. void sys_trace_k_thread_name_set(struct k_thread *thread, int ret);
  398. void sys_trace_k_thread_switched_out(void);
  399. void sys_trace_k_thread_switched_in(void);
  400. void sys_trace_k_thread_ready(struct k_thread *thread);
  401. void sys_trace_k_thread_pend(struct k_thread *thread);
  402. void sys_trace_k_thread_info(struct k_thread *thread);
  403. void sys_trace_k_sem_init(struct k_sem *sem, int ret);
  404. void sys_trace_k_sem_give_enter(struct k_sem *sem);
  405. void sys_trace_k_sem_take_enter(struct k_sem *sem, k_timeout_t timeout);
  406. void sys_trace_k_sem_take_blocking(struct k_sem *sem, k_timeout_t timeout);
  407. void sys_trace_k_sem_take_exit(struct k_sem *sem, k_timeout_t timeout, int ret);
  408. void sys_trace_k_sem_reset(struct k_sem *sem);
  409. void sys_trace_k_mutex_init(struct k_mutex *mutex, int ret);
  410. void sys_trace_k_mutex_lock_enter(struct k_mutex *mutex, k_timeout_t timeout);
  411. void sys_trace_k_mutex_lock_blocking(struct k_mutex *mutex, k_timeout_t timeout);
  412. void sys_trace_k_mutex_lock_exit(struct k_mutex *mutex, k_timeout_t timeout, int ret);
  413. void sys_trace_k_mutex_unlock_enter(struct k_mutex *mutex);
  414. void sys_trace_k_mutex_unlock_exit(struct k_mutex *mutex, int ret);
  415. void sys_trace_k_condvar_init(struct k_condvar *condvar, int ret);
  416. void sys_trace_k_condvar_signal_enter(struct k_condvar *condvar);
  417. void sys_trace_k_condvar_signal_blocking(struct k_condvar *condvar);
  418. void sys_trace_k_condvar_signal_exit(struct k_condvar *condvar, int ret);
  419. void sys_trace_k_condvar_broadcast_enter(struct k_condvar *condvar);
  420. void sys_trace_k_condvar_broadcast_exit(struct k_condvar *condvar, int ret);
  421. void sys_trace_k_condvar_wait_enter(struct k_condvar *condvar, struct k_mutex *mutex,
  422. k_timeout_t timeout);
  423. void sys_trace_k_condvar_wait_exit(struct k_condvar *condvar, struct k_mutex *mutex,
  424. k_timeout_t timeout, int ret);
  425. void sys_trace_k_queue_init(struct k_queue *queue);
  426. void sys_trace_k_queue_cancel_wait(struct k_queue *queue);
  427. void sys_trace_k_queue_queue_insert_enter(struct k_queue *queue, bool alloc, void *data);
  428. void sys_trace_k_queue_queue_insert_blocking(struct k_queue *queue, bool alloc, void *data);
  429. void sys_trace_k_queue_queue_insert_exit(struct k_queue *queue, bool alloc, void *data, int ret);
  430. void sys_trace_k_queue_append_enter(struct k_queue *queue, void *data);
  431. void sys_trace_k_queue_append_exit(struct k_queue *queue, void *data);
  432. void sys_trace_k_queue_alloc_append_enter(struct k_queue *queue, void *data);
  433. void sys_trace_k_queue_alloc_append_exit(struct k_queue *queue, void *data, int ret);
  434. void sys_trace_k_queue_prepend_enter(struct k_queue *queue, void *data);
  435. void sys_trace_k_queue_prepend_exit(struct k_queue *queue, void *data);
  436. void sys_trace_k_queue_alloc_prepend_enter(struct k_queue *queue, void *data);
  437. void sys_trace_k_queue_alloc_prepend_exit(struct k_queue *queue, void *data, int ret);
  438. void sys_trace_k_queue_insert_enter(struct k_queue *queue, void *prev, void *data);
  439. void sys_trace_k_queue_insert_exit(struct k_queue *queue, void *prev, void *data);
  440. void sys_trace_k_queue_append_list_exit(struct k_queue *queue, void *head, void *tail, int ret);
  441. void sys_trace_k_queue_merge_slist_enter(struct k_queue *queue, sys_slist_t *list);
  442. void sys_trace_k_queue_merge_slist_exit(struct k_queue *queue, sys_slist_t *list, int ret);
  443. void sys_trace_k_queue_get_blocking(struct k_queue *queue, k_timeout_t timeout);
  444. void sys_trace_k_queue_get_exit(struct k_queue *queue, k_timeout_t timeout, void *ret);
  445. void sys_trace_k_queue_remove_enter(struct k_queue *queue, void *data);
  446. void sys_trace_k_queue_remove_exit(struct k_queue *queue, void *data, bool ret);
  447. void sys_trace_k_queue_unique_append_enter(struct k_queue *queue, void *data);
  448. void sys_trace_k_queue_unique_append_exit(struct k_queue *queue, void *data, bool ret);
  449. void sys_trace_k_queue_peek_head(struct k_queue *queue, void *ret);
  450. void sys_trace_k_queue_peek_tail(struct k_queue *queue, void *ret);
  451. void sys_trace_k_fifo_init_enter(struct k_fifo *fifo);
  452. void sys_trace_k_fifo_init_exit(struct k_fifo *fifo);
  453. void sys_trace_k_fifo_cancel_wait_enter(struct k_fifo *fifo);
  454. void sys_trace_k_fifo_cancel_wait_exit(struct k_fifo *fifo);
  455. void sys_trace_k_fifo_put_enter(struct k_fifo *fifo, void *data);
  456. void sys_trace_k_fifo_put_exit(struct k_fifo *fifo, void *data);
  457. void sys_trace_k_fifo_alloc_put_enter(struct k_fifo *fifo, void *data);
  458. void sys_trace_k_fifo_alloc_put_exit(struct k_fifo *fifo, void *data, int ret);
  459. void sys_trace_k_fifo_put_list_enter(struct k_fifo *fifo, void *head, void *tail);
  460. void sys_trace_k_fifo_put_list_exit(struct k_fifo *fifo, void *head, void *tail);
  461. void sys_trace_k_fifo_put_slist_enter(struct k_fifo *fifo, sys_slist_t *list);
  462. void sys_trace_k_fifo_put_slist_exit(struct k_fifo *fifo, sys_slist_t *list);
  463. void sys_trace_k_fifo_get_enter(struct k_fifo *fifo, k_timeout_t timeout);
  464. void sys_trace_k_fifo_get_exit(struct k_fifo *fifo, k_timeout_t timeout, void *ret);
  465. void sys_trace_k_fifo_peek_head_enter(struct k_fifo *fifo);
  466. void sys_trace_k_fifo_peek_head_exit(struct k_fifo *fifo, void *ret);
  467. void sys_trace_k_fifo_peek_tail_enter(struct k_fifo *fifo);
  468. void sys_trace_k_fifo_peek_tail_exit(struct k_fifo *fifo, void *ret);
  469. void sys_trace_k_lifo_init_enter(struct k_lifo *lifo);
  470. void sys_trace_k_lifo_init_exit(struct k_lifo *lifo);
  471. void sys_trace_k_lifo_put_enter(struct k_lifo *lifo, void *data);
  472. void sys_trace_k_lifo_put_exit(struct k_lifo *lifo, void *data);
  473. void sys_trace_k_lifo_alloc_put_enter(struct k_lifo *lifo, void *data);
  474. void sys_trace_k_lifo_alloc_put_exit(struct k_lifo *lifo, void *data, int ret);
  475. void sys_trace_k_lifo_get_enter(struct k_lifo *lifo, k_timeout_t timeout);
  476. void sys_trace_k_lifo_get_exit(struct k_lifo *lifo, k_timeout_t timeout, void *ret);
  477. void sys_trace_k_stack_init(struct k_stack *stack, stack_data_t *buffer, uint32_t num_entries);
  478. void sys_trace_k_stack_alloc_init_enter(struct k_stack *stack, uint32_t num_entries);
  479. void sys_trace_k_stack_alloc_init_exit(struct k_stack *stack, uint32_t num_entries, int ret);
  480. void sys_trace_k_stack_cleanup_enter(struct k_stack *stack);
  481. void sys_trace_k_stack_cleanup_exit(struct k_stack *stack, int ret);
  482. void sys_trace_k_stack_push_enter(struct k_stack *stack, stack_data_t data);
  483. void sys_trace_k_stack_push_exit(struct k_stack *stack, stack_data_t data, int ret);
  484. void sys_trace_k_stack_pop_blocking(struct k_stack *stack, stack_data_t *data, k_timeout_t timeout);
  485. void sys_trace_k_stack_pop_exit(struct k_stack *stack, stack_data_t *data, k_timeout_t timeout,
  486. int ret);
  487. void sys_trace_k_mbox_init(struct k_mbox *mbox);
  488. void sys_trace_k_mbox_message_put_enter(struct k_mbox *mbox, struct k_mbox_msg *tx_msg,
  489. k_timeout_t timeout);
  490. void sys_trace_k_mbox_message_put_blocking(struct k_mbox *mbox, struct k_mbox_msg *tx_msg,
  491. k_timeout_t timeout);
  492. void sys_trace_k_mbox_message_put_exit(struct k_mbox *mbox, struct k_mbox_msg *tx_msg,
  493. k_timeout_t timeout, int ret);
  494. void sys_trace_k_mbox_put_enter(struct k_mbox *mbox, struct k_mbox_msg *tx_msg,
  495. k_timeout_t timeout);
  496. void sys_trace_k_mbox_put_exit(struct k_mbox *mbox, struct k_mbox_msg *tx_msg, k_timeout_t timeout,
  497. int ret);
  498. void sys_trace_k_mbox_async_put_enter(struct k_mbox *mbox, struct k_sem *sem);
  499. void sys_trace_k_mbox_async_put_exit(struct k_mbox *mbox, struct k_sem *sem);
  500. void sys_trace_k_mbox_get_enter(struct k_mbox *mbox, struct k_mbox_msg *rx_msg, void *buffer,
  501. k_timeout_t timeout);
  502. void sys_trace_k_mbox_get_blocking(struct k_mbox *mbox, struct k_mbox_msg *rx_msg, void *buffer,
  503. k_timeout_t timeout);
  504. void sys_trace_k_mbox_get_exit(struct k_mbox *mbox, struct k_mbox_msg *rx_msg, void *buffer,
  505. k_timeout_t timeout, int ret);
  506. void sys_trace_k_mbox_data_get(struct k_mbox *mbox, struct k_mbox_msg *rx_msg, void *buffer);
  507. void sys_trace_k_pipe_init(struct k_pipe *pipe, unsigned char *buffer, size_t size);
  508. void sys_trace_k_pipe_cleanup_enter(struct k_pipe *pipe);
  509. void sys_trace_k_pipe_cleanup_exit(struct k_pipe *pipe, int ret);
  510. void sys_trace_k_pipe_alloc_init_enter(struct k_pipe *pipe, size_t size);
  511. void sys_trace_k_pipe_alloc_init_exit(struct k_pipe *pipe, size_t size, int ret);
  512. void sys_trace_k_pipe_put_enter(struct k_pipe *pipe, void *data, size_t bytes_to_write,
  513. size_t *bytes_written, size_t min_xfer, k_timeout_t timeout);
  514. void sys_trace_k_pipe_put_blocking(struct k_pipe *pipe, void *data, size_t bytes_to_write,
  515. size_t *bytes_written, size_t min_xfer, k_timeout_t timeout);
  516. void sys_trace_k_pipe_put_exit(struct k_pipe *pipe, void *data, size_t bytes_to_write,
  517. size_t *bytes_written, size_t min_xfer, k_timeout_t timeout,
  518. int ret);
  519. void sys_trace_k_pipe_get_enter(struct k_pipe *pipe, void *data, size_t bytes_to_read,
  520. size_t *bytes_read, size_t min_xfer, k_timeout_t timeout);
  521. void sys_trace_k_pipe_get_blocking(struct k_pipe *pipe, void *data, size_t bytes_to_read,
  522. size_t *bytes_read, size_t min_xfer, k_timeout_t timeout);
  523. void sys_trace_k_pipe_get_exit(struct k_pipe *pipe, void *data, size_t bytes_to_read,
  524. size_t *bytes_read, size_t min_xfer, k_timeout_t timeout, int ret);
  525. void sys_trace_k_pipe_block_put_enter(struct k_pipe *pipe, struct k_mem_block *block, size_t size,
  526. struct k_sem *sem);
  527. void sys_trace_k_pipe_block_put_exit(struct k_pipe *pipe, struct k_mem_block *block, size_t size,
  528. struct k_sem *sem);
  529. void sys_trace_k_msgq_init(struct k_msgq *msgq);
  530. void sys_trace_k_msgq_alloc_init_enter(struct k_msgq *msgq, size_t msg_size, uint32_t max_msgs);
  531. void sys_trace_k_msgq_alloc_init_exit(struct k_msgq *msgq, size_t msg_size, uint32_t max_msgs,
  532. int ret);
  533. void sys_trace_k_msgq_cleanup_enter(struct k_msgq *msgq);
  534. void sys_trace_k_msgq_cleanup_exit(struct k_msgq *msgq, int ret);
  535. void sys_trace_k_msgq_put_enter(struct k_msgq *msgq, const void *data, k_timeout_t timeout);
  536. void sys_trace_k_msgq_put_blocking(struct k_msgq *msgq, const void *data, k_timeout_t timeout);
  537. void sys_trace_k_msgq_put_exit(struct k_msgq *msgq, const void *data, k_timeout_t timeout, int ret);
  538. void sys_trace_k_msgq_get_enter(struct k_msgq *msgq, const void *data, k_timeout_t timeout);
  539. void sys_trace_k_msgq_get_blocking(struct k_msgq *msgq, const void *data, k_timeout_t timeout);
  540. void sys_trace_k_msgq_get_exit(struct k_msgq *msgq, const void *data, k_timeout_t timeout, int ret);
  541. void sys_trace_k_msgq_peek(struct k_msgq *msgq, void *data, int ret);
  542. void sys_trace_k_msgq_purge(struct k_msgq *msgq);
  543. void sys_trace_k_heap_init(struct k_heap *h, void *mem, size_t bytes);
  544. void sys_trace_k_heap_alloc_enter(struct k_heap *h, size_t bytes, k_timeout_t timeout);
  545. void sys_trace_k_heap_alloc_exit(struct k_heap *h, size_t bytes, k_timeout_t timeout, void *ret);
  546. void sys_trace_k_heap_aligned_alloc_enter(struct k_heap *h, size_t bytes, k_timeout_t timeout);
  547. void sys_trace_k_heap_aligned_alloc_blocking(struct k_heap *h, size_t bytes, k_timeout_t timeout);
  548. void sys_trace_k_heap_aligned_alloc_exit(struct k_heap *h, size_t bytes, k_timeout_t timeout,
  549. void *ret);
  550. void sys_trace_k_heap_free(struct k_heap *h, void *mem);
  551. void sys_trace_k_heap_sys_k_aligned_alloc_enter(struct k_heap *h, size_t align, size_t size);
  552. void sys_trace_k_heap_sys_k_aligned_alloc_exit(struct k_heap *h, size_t align, size_t size,
  553. void *ret);
  554. void sys_trace_k_heap_sys_k_malloc_enter(struct k_heap *h, size_t size);
  555. void sys_trace_k_heap_sys_k_malloc_exit(struct k_heap *h, size_t size, void *ret);
  556. void sys_trace_k_heap_sys_k_free_enter(struct k_heap *h);
  557. void sys_trace_k_heap_sys_k_free_exit(struct k_heap *h);
  558. void sys_trace_k_heap_sys_k_calloc_enter(struct k_heap *h, size_t nmemb, size_t size);
  559. void sys_trace_k_heap_sys_k_calloc_exit(struct k_heap *h, size_t nmemb, size_t size, void *ret);
  560. void sys_trace_k_mem_slab_init(struct k_mem_slab *slab, void *buffer, size_t block_size,
  561. uint32_t num_blocks, int ret);
  562. void sys_trace_k_mem_slab_alloc_enter(struct k_mem_slab *slab, void **mem, k_timeout_t timeout);
  563. void sys_trace_k_mem_slab_alloc_blocking(struct k_mem_slab *slab, void **mem, k_timeout_t timeout);
  564. void sys_trace_k_mem_slab_alloc_exit(struct k_mem_slab *slab, void **mem, k_timeout_t timeout,
  565. int ret);
  566. void sys_trace_k_mem_slab_free_exit(struct k_mem_slab *slab, void **mem);
  567. void sys_trace_k_timer_init(struct k_timer *timer, k_timer_expiry_t expiry_fn,
  568. k_timer_expiry_t stop_fn);
  569. void sys_trace_k_timer_start(struct k_timer *timer, k_timeout_t duration, k_timeout_t period);
  570. void sys_trace_k_timer_stop(struct k_timer *timer);
  571. void sys_trace_k_timer_status_sync_blocking(struct k_timer *timer);
  572. void sys_trace_k_timer_status_sync_exit(struct k_timer *timer, uint32_t result);
  573. #endif /* ZEPHYR_TRACE_TEST_H */