函数逻辑报告

Linux Kernel

v5.5.9

Brick Technologies Co., Ltd

Source Code:kernel\tracepoint.c Create Date:2022-07-27 12:55:26
Last Modify:2020-03-12 14:18:49 Copyright©Brick
首页 函数Tree
注解内核,赢得工具下载SCCTEnglish

函数名称:Add the probe function to a tracepoint.

函数原型:static int tracepoint_add_func(struct tracepoint *tp, struct tracepoint_func *func, int prio)

返回类型:int

参数:

类型参数名称
struct tracepoint *tp
struct tracepoint_func *func
intprio
233  如果regfunc且非static_key_enabled( & key)则
234  ret等于regfunc()
235  如果ret小于0则返回:ret
239  tp_funcs等于cu_dereference_protected() - fetch RCU pointer when updates prevented*@p: The pointer to read, prior to dereferencing*@c: The conditions under which the dereference will take place* Return the value of the specified RCU-protected pointer, but omit(funcs, lockdep_is_held( & racepoints_mutex protects the builtin and module tracepoints.* tracepoints_mutex nests inside tracepoint_module_list_mutex.))
241  old等于func_add( & tp_funcs, func, prio)
242  如果是错误
243  WARN_ON_ONCE(错误 != - ENOMEM)
244  返回:错误
253  cu_assign_pointer() - assign to RCU-protected pointer*@p: pointer to assign to*@v: value to assign (publish)* Assigns the specified value to the specified RCU-protected* pointer, ensuring that any concurrent RCU readers will see* any prior initialization(funcs, tp_funcs)
254  如果非static_key_enabled( & key)则static_key_slow_inc( & key)
256  release_probes(old)
257  返回:0
调用者
名称描述
tracepoint_probe_register_prioracepoint_probe_register_prio - Connect a probe to a tracepoint with priority*@tp: tracepoint*@probe: probe handler*@data: tracepoint data*@prio: priority of this function over other registered functions* Returns 0 if ok, error value on error