| Function report | 
| Source Code: kernel\trace\trace_events_trigger.c | Create Date:2022-07-28 12:26:16 | 
| Last Modify:2020-03-12 14:18:49 | Copyright©Brick | 
| home page | Tree | 
| Annotation kernel can get tool activity | Download SCCT | Chinese | 
Name:vent_trigger_callback - Generic event_command @func implementation*@cmd_ops: The command ops, used for trigger registration*@file: The trace_event_file associated with the event*@glob: The raw string used to register the trigger*@cmd: The cmd portion of
Proto:static int event_trigger_callback(struct event_command *cmd_ops, struct trace_event_file *file, char *glob, char *cmd, char *param)
Type:int
Parameter:
| Type | Parameter | Name | 
|---|---|---|
| struct event_command * | cmd_ops | |
| struct trace_event_file * | file | |
| char * | glob | |
| char * | cmd | |
| char * | param | 
| 628 | char * trigger = NULL | 
| 636 | trigger_ops = get_trigger_ops(cmd, trigger) | 
| 639 | trigger_data = kzalloc - allocate memory. The memory is set to zero.*@size: how many bytes of memory are required.*@flags: the type of memory to allocate (see kmalloc). | 
| 640 | If Not trigger_data Then Go to out | 
| 643 | count = -1 | 
| 644 | ops = trigger_ops | 
| 646 | private_data = file | 
| 650 | If glob[0] == '!' Then | 
| 651 | unreg(glob + 1, trigger_ops, trigger_data, file) | 
| 652 | kfree(trigger_data) | 
| 653 | ret = 0 | 
| 654 | Go to out | 
| 657 | If trigger Then | 
| 661 | If Not strlen - Find the length of a string*@s: The string to be sized Then Go to out_free | 
| 676 | If Not set_filter Then Go to out_reg | 
| 679 | ret = set_filter(param, trigger_data, file) | 
| 683 | out_reg : | 
| 686 | ret = reg(glob, trigger_ops, trigger_data, file) | 
| 692 | If Not ret Then | 
| 693 | unreg(glob, trigger_ops, trigger_data, file) | 
| 700 | out : | 
| 701 | Return ret | 
| 703 | out_free : | 
| 704 | If set_filter Then set_filter(NULL, trigger_data, NULL) | 
| 706 | kfree(trigger_data) | 
| 707 | Go to out | 
| Source code conversion tool public plug-in interface | X | 
|---|---|
| Support c/c++/esqlc/java Oracle/Informix/Mysql Plug-in can realize: logical Report Code generation and batch code conversion |