Function report |
Source Code:kernel\trace\trace.c |
Create Date:2022-07-28 11:58:33 |
| Last Modify:2020-03-12 14:18:49 | Copyright©Brick |
| home page | Tree |
| Annotation kernel can get tool activity | Download SCCT | Chinese |
Name:allocate_cmdlines_buffer
Proto:static int allocate_cmdlines_buffer(unsigned int val, struct saved_cmdlines_buffer *s)
Type:int
Parameter:
| Type | Parameter | Name |
|---|---|---|
| unsigned int | val | |
| struct saved_cmdlines_buffer * | s |
| 2050 | map_cmdline_to_pid = kmalloc_array - allocate memory for an array.*@n: number of elements.*@size: element size.*@flags: the type of memory to allocate (see kmalloc). |
| 2053 | If Not map_cmdline_to_pid Then Return -ENOMEM |
| 2056 | saved_cmdlines = kmalloc_array - allocate memory for an array.*@n: number of elements.*@size: element size.*@flags: the type of memory to allocate (see kmalloc). |
| 2057 | If Not saved_cmdlines Then |
| 2058 | kfree(map_cmdline_to_pid) |
| 2059 | Return -ENOMEM |
| 2062 | cmdline_idx = 0 |
| 2063 | cmdline_num = val |
| 2064 | memset( & map_pid_to_cmdline, NO_CMDLINE_MAP, size of map_pid_to_cmdline ) |
| 2066 | memset(map_cmdline_to_pid, NO_CMDLINE_MAP, val * size of map_cmdline_to_pid ) |
| 2069 | Return 0 |
| Name | Describe |
|---|---|
| trace_create_savedcmd | |
| tracing_resize_saved_cmdlines |
| 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 |