62 EM_ESCOPE_HOOKS_REGISTER_ALLOC,
63 "EM API callback hooks disabled");
66 stat = hook_register(ALLOC_HOOK, hook_fn);
68 "Alloc hook register failed");
80 EM_ESCOPE_HOOKS_UNREGISTER_ALLOC,
81 "EM API callback hooks disabled");
84 stat = hook_unregister(ALLOC_HOOK, hook_fn);
86 "Alloc hook unregister failed");
98 EM_ESCOPE_HOOKS_REGISTER_FREE,
99 "EM API callback hooks disabled");
102 stat = hook_register(FREE_HOOK, hook_fn);
104 "Free hook register failed");
116 EM_ESCOPE_HOOKS_UNREGISTER_FREE,
117 "EM API callback hooks disabled");
120 stat = hook_unregister(FREE_HOOK, hook_fn);
122 "Free hook unregister failed");
134 EM_ESCOPE_HOOKS_REGISTER_SEND,
135 "EM API callback hooks disabled");
138 stat = hook_register(SEND_HOOK, hook_fn);
140 "Send hook register failed");
152 EM_ESCOPE_HOOKS_UNREGISTER_SEND,
153 "EM API callback hooks disabled");
156 stat = hook_unregister(SEND_HOOK, hook_fn);
158 "Send hook unregister failed");
170 EM_ESCOPE_HOOKS_REGISTER_TO_IDLE,
171 "EM IDLE callback hooks disabled");
173 hook_fn.to_idle = func;
174 stat = hook_register(TO_IDLE_HOOK, hook_fn);
176 "To_idle hook register failed");
188 EM_ESCOPE_HOOKS_UNREGISTER_TO_IDLE,
189 "EM IDLE callback hooks disabled");
191 hook_fn.to_idle = func;
192 stat = hook_unregister(TO_IDLE_HOOK, hook_fn);
194 "To_idle hook unregister failed");
206 EM_ESCOPE_HOOKS_REGISTER_TO_ACTIVE,
207 "EM IDLE callback hooks disabled");
209 hook_fn.to_active = func;
210 stat = hook_register(TO_ACTIVE_HOOK, hook_fn);
212 "To_active hook register failed");
224 EM_ESCOPE_HOOKS_UNREGISTER_TO_ACTIVE,
225 "EM IDLE callback hooks disabled");
227 hook_fn.to_active = func;
228 stat = hook_unregister(TO_ACTIVE_HOOK, hook_fn);
230 "To_active hook unregister failed");
242 EM_ESCOPE_HOOKS_REGISTER_WHILE_IDLE,
243 "EM IDLE callback hooks disabled");
245 hook_fn.while_idle = func;
246 stat = hook_register(WHILE_IDLE_HOOK, hook_fn);
248 "While_idle hook register failed");
260 EM_ESCOPE_HOOKS_UNREGISTER_WHILE_IDLE,
261 "EM IDLE callback hooks disabled");
263 hook_fn.while_idle = func;
264 stat = hook_unregister(WHILE_IDLE_HOOK, hook_fn);
266 "While_idle hook unregister failed");
#define RETURN_ERROR_IF(cond, error, escope, fmt,...)
#define EM_IDLE_HOOKS_ENABLE
#define EM_API_HOOKS_ENABLE
void(* em_idle_hook_while_idle_t)(void)
em_status_t em_hooks_register_to_active(em_idle_hook_to_active_t func)
em_status_t em_hooks_unregister_alloc(em_api_hook_alloc_t func)
void(* em_idle_hook_to_active_t)(void)
em_status_t em_hooks_unregister_to_active(em_idle_hook_to_active_t func)
em_status_t em_hooks_register_alloc(em_api_hook_alloc_t func)
void(* em_api_hook_send_t)(const em_event_t events[], int num, em_queue_t queue, em_event_group_t event_group)
em_status_t em_hooks_register_free(em_api_hook_free_t func)
void(* em_idle_hook_to_idle_t)(uint64_t to_idle_delay_ns)
void(* em_api_hook_alloc_t)(const em_event_t events[], int num_act, int num_req, uint32_t size, em_event_type_t type, em_pool_t pool)
em_status_t em_hooks_unregister_to_idle(em_idle_hook_to_idle_t func)
void(* em_api_hook_free_t)(const em_event_t events[], int num)
em_status_t em_hooks_register_to_idle(em_idle_hook_to_idle_t func)
em_status_t em_hooks_register_while_idle(em_idle_hook_while_idle_t func)
em_status_t em_hooks_unregister_free(em_api_hook_free_t func)
em_status_t em_hooks_unregister_send(em_api_hook_send_t func)
em_status_t em_hooks_register_send(em_api_hook_send_t func)
em_status_t em_hooks_unregister_while_idle(em_idle_hook_while_idle_t func)