Lines Matching refs:hndl

60 tnfctl_register_funcs(tnfctl_handle_t *hndl,  in tnfctl_register_funcs()  argument
66 if (hndl->destroy_func) { in tnfctl_register_funcs()
72 prexstat = _tnfctl_probes_traverse(hndl, in tnfctl_register_funcs()
79 hndl->create_func = create_func; in tnfctl_register_funcs()
80 hndl->destroy_func = destroy_func; in tnfctl_register_funcs()
84 prexstat = _tnfctl_probes_traverse(hndl, in tnfctl_register_funcs()
94 _tnfctl_destructor_wrapper(tnfctl_handle_t *hndl, prbctlref_t *probe, void *cd) in _tnfctl_destructor_wrapper() argument
96 assert(hndl->destroy_func); in _tnfctl_destructor_wrapper()
97 hndl->destroy_func(probe->probe_handle->client_registered_data); in _tnfctl_destructor_wrapper()
103 _tnfctl_creator_wrapper(tnfctl_handle_t *hndl, prbctlref_t *probe, void *cd) in _tnfctl_creator_wrapper() argument
107 assert(hndl->create_func); in _tnfctl_creator_wrapper()
109 p_handle->client_registered_data = hndl->create_func(hndl, p_handle); in _tnfctl_creator_wrapper()
115 tnfctl_probe_apply(tnfctl_handle_t *hndl, tnfctl_probe_op_t func_p, in tnfctl_probe_apply() argument
123 prexstat = _tnfctl_probes_traverse(hndl, apply_func, &pr_args); in tnfctl_probe_apply()
128 tnfctl_probe_apply_ids(tnfctl_handle_t *hndl, ulong_t probe_count, in tnfctl_probe_apply_ids() argument
140 LOCK_SYNC(hndl, prexstat, release_lock); in tnfctl_probe_apply_ids()
145 obj_p = hndl->objlist; in tnfctl_probe_apply_ids()
160 prexstat = func_p(hndl, probe->probe_handle, calldata); in tnfctl_probe_apply_ids()
167 UNLOCK(hndl, release_lock); in tnfctl_probe_apply_ids()
172 tnfctl_probe_state_get(tnfctl_handle_t *hndl, tnfctl_probe_t *probe_hndl, in tnfctl_probe_state_get() argument
181 if (hndl->mode == KERNEL_MODE) { in tnfctl_probe_state_get()
182 prexstat = _tnfctl_refresh_kernel(hndl); in tnfctl_probe_state_get()
188 LOCK_SYNC(hndl, prexstat, release_lock); in tnfctl_probe_state_get()
201 (tnf_probe_func_t) hndl->commitfunc) ? B_TRUE : B_FALSE; in tnfctl_probe_state_get()
206 if (hndl->mode == KERNEL_MODE) { in tnfctl_probe_state_get()
214 prexstat = _tnfctl_comb_decode(hndl, (uintptr_t) prbctl_p->probe_func, in tnfctl_probe_state_get()
230 UNLOCK(hndl, release_lock); in tnfctl_probe_state_get()
235 check_operation(tnfctl_handle_t *hndl, tnfctl_probe_t *probe_hndl) in check_operation() argument
239 if (hndl->mode == KERNEL_MODE) { in check_operation()
240 prexstat = _tnfctl_refresh_kernel(hndl); in check_operation()
243 } else if (hndl->trace_buf_state == TNFCTL_BUF_NONE) { in check_operation()
248 if (hndl->trace_buf_state == TNFCTL_BUF_BROKEN) in check_operation()
259 tnfctl_probe_enable(tnfctl_handle_t *hndl, tnfctl_probe_t *probe_hndl, void *cd) in tnfctl_probe_enable() argument
266 LOCK_SYNC(hndl, prexstat, release_lock); in tnfctl_probe_enable()
268 prexstat = check_operation(hndl, probe_hndl); in tnfctl_probe_enable()
273 prbctl_p->test_func = (tnf_probe_test_func_t) hndl->testfunc; in tnfctl_probe_enable()
274 prexstat = _tnfctl_flush_a_probe(hndl, probe_hndl->probe_p, in tnfctl_probe_enable()
279 UNLOCK(hndl, release_lock); in tnfctl_probe_enable()
284 tnfctl_probe_disable(tnfctl_handle_t *hndl, tnfctl_probe_t *probe_hndl, in tnfctl_probe_disable() argument
292 LOCK_SYNC(hndl, prexstat, release_lock); in tnfctl_probe_disable()
294 prexstat = check_operation(hndl, probe_hndl); in tnfctl_probe_disable()
300 prexstat = _tnfctl_flush_a_probe(hndl, probe_hndl->probe_p, in tnfctl_probe_disable()
305 UNLOCK(hndl, release_lock); in tnfctl_probe_disable()
310 tnfctl_probe_trace(tnfctl_handle_t *hndl, tnfctl_probe_t *probe_hndl, void *cd) in tnfctl_probe_trace() argument
317 LOCK_SYNC(hndl, prexstat, release_lock); in tnfctl_probe_trace()
319 prexstat = check_operation(hndl, probe_hndl); in tnfctl_probe_trace()
324 prbctl_p->commit_func = (tnf_probe_func_t) hndl->commitfunc; in tnfctl_probe_trace()
325 prexstat = _tnfctl_flush_a_probe(hndl, probe_hndl->probe_p, in tnfctl_probe_trace()
331 UNLOCK(hndl, release_lock); in tnfctl_probe_trace()
336 tnfctl_probe_untrace(tnfctl_handle_t *hndl, tnfctl_probe_t *probe_hndl, in tnfctl_probe_untrace() argument
344 LOCK_SYNC(hndl, prexstat, release_lock); in tnfctl_probe_untrace()
346 prexstat = check_operation(hndl, probe_hndl); in tnfctl_probe_untrace()
351 prbctl_p->commit_func = (tnf_probe_func_t) hndl->rollbackfunc; in tnfctl_probe_untrace()
352 prexstat = _tnfctl_flush_a_probe(hndl, probe_hndl->probe_p, in tnfctl_probe_untrace()
358 UNLOCK(hndl, release_lock); in tnfctl_probe_untrace()
363 tnfctl_probe_connect(tnfctl_handle_t *hndl, tnfctl_probe_t *probe_hndl, in tnfctl_probe_connect() argument
372 if (hndl->mode == KERNEL_MODE) in tnfctl_probe_connect()
376 LOCK_SYNC(hndl, prexstat, release_lock); in tnfctl_probe_connect()
378 prexstat = check_operation(hndl, probe_hndl); in tnfctl_probe_connect()
388 prexstat = _tnfctl_sym_obj_find(hndl, lib_base_name, func, in tnfctl_probe_connect()
391 prexstat = _tnfctl_sym_find(hndl, func, &func_addr); in tnfctl_probe_connect()
398 prexstat = _tnfctl_comb_build(hndl, PRB_COMB_CHAIN, in tnfctl_probe_connect()
404 prexstat = _tnfctl_flush_a_probe(hndl, probe_hndl->probe_p, in tnfctl_probe_connect()
410 UNLOCK(hndl, release_lock); in tnfctl_probe_connect()
415 tnfctl_probe_disconnect_all(tnfctl_handle_t *hndl, tnfctl_probe_t *probe_hndl, in tnfctl_probe_disconnect_all() argument
422 if (hndl->mode == KERNEL_MODE) in tnfctl_probe_disconnect_all()
426 LOCK_SYNC(hndl, prexstat, release_lock); in tnfctl_probe_disconnect_all()
428 prexstat = check_operation(hndl, probe_hndl); in tnfctl_probe_disconnect_all()
433 prbctl_p->probe_func = (tnf_probe_func_t) hndl->endfunc; in tnfctl_probe_disconnect_all()
434 prexstat = _tnfctl_flush_a_probe(hndl, probe_hndl->probe_p, in tnfctl_probe_disconnect_all()
440 UNLOCK(hndl, release_lock); in tnfctl_probe_disconnect_all()
449 apply_func(tnfctl_handle_t *hndl, prbctlref_t *probe, void *cd) in apply_func() argument
455 prexstat = (*(args->func_p))(hndl, probe->probe_handle, args->calldata); in apply_func()