函数逻辑报告 |
Source Code:kernel\trace\trace_events_hist.c |
Create Date:2022-07-27 13:43:44 |
Last Modify:2020-03-12 14:18:49 | Copyright©Brick |
首页 | 函数Tree |
注解内核,赢得工具 | 下载SCCT | English |
函数名称:event_hist_trigger_func
函数原型:static int event_hist_trigger_func(struct event_command *cmd_ops, struct trace_event_file *file, char *glob, char *cmd, char *param)
返回类型:int
参数:
类型 | 参数 | 名称 |
---|---|---|
struct event_command * | cmd_ops | |
struct trace_event_file * | file | |
char * | glob | |
char * | cmd | |
char * | param |
6184 | bool remove = false |
6186 | ret等于0 |
6188 | lockdep_assert_held( & event_mutex) |
6191 | hist_err_clear() |
6192 | last_cmd_set(file, param) |
6206 | 循环 |
6207 | p等于strstr - Find the first substring in a %NUL terminated string*@s1: The string to be searched*@s2: The string to search for |
6213 | p自加 |
6214 | 继续下一循环 |
6216 | 如果p大于等于param加strlen - Find the length of a string*@s: The string to be sized减"if"的长度减1减1则返回:负EINVAL |
6219 | p自加 |
6220 | 继续下一循环 |
6222 | 退出 |
6227 | 否则 |
6233 | attrs等于parse_hist_trigger_attrs(tr, trigger) |
6237 | 如果map_bits则hist_trigger_bits等于map_bits |
6240 | hist_data等于create_hist_data(hist_trigger_bits, attrs, file, remove) |
6241 | 如果是错误则 |
6243 | 返回:错误 |
6246 | trigger_ops等于get_trigger_ops(cmd, trigger) |
6248 | trigger_data等于分配内存并置零 |
6249 | 如果非trigger_data则 |
6254 | count等于负1 |
6255 | ops等于trigger_ops |
6258 | 初始化链表头 |
6261 | private_data等于hist_data |
6264 | 如果param且set_filter则 |
6265 | ret等于set_filter(param, trigger_data, file) |
6270 | 如果remove则 |
6271 | 如果非have_hist_trigger_match(trigger_data, file)则转到:out_free |
6274 | 如果hist_trigger_check_refs(trigger_data, file)则 |
6279 | unreg(glob + 1, trigger_ops, trigger_data, file) |
6280 | se_name等于trace_event_name(event_call) |
6281 | se等于find_synth_event(se_name) |
6284 | ret等于0 |
6285 | 转到:out_free |
6288 | ret等于reg(glob, trigger_ops, trigger_data, file) |
6294 | 如果非ret则 |
6301 | 如果get_named_trigger_data(trigger_data)则转到:enable |
6304 | 如果has_hist_vars(hist_data)则save_hist_vars(hist_data) |
6307 | ret等于create_actions(hist_data) |
6314 | enable : |
6315 | ret等于hist_trigger_enable(trigger_data, file) |
6319 | se_name等于trace_event_name(event_call) |
6320 | se等于find_synth_event(se_name) |
6324 | ret等于0 |
6325 | out : |
6326 | 如果ret恒等于0则hist_err_clear() |
6329 | 返回:ret |
6330 | out_unreg : |
6331 | unreg(glob + 1, trigger_ops, trigger_data, file) |
6332 | out_free : |
6333 | 如果set_filter则set_filter(NULL, trigger_data, NULL) |
6336 | remove_hist_vars(hist_data) |
6338 | kfree(trigger_data) |
6340 | destroy_hist_data(hist_data) |
6341 | 转到:out |
名称 | 描述 |
---|---|
create_field_var_hist | reate_field_var_hist - Automatically create a histogram and var for a field*@target_hist_data: The target hist trigger*@subsys_name: Optional subsystem name*@event_name: Optional event name*@field_name: The name of the field (and the resulting variable)* |
unregister_field_var_hists |
源代码转换工具 开放的插件接口 | X |
---|---|
支持:c/c++/esqlc/java Oracle/Informix/Mysql 插件可实现:逻辑报告 代码生成和批量转换代码 |