Function report |
Source Code:kernel\events\core.c |
Create Date:2022-07-28 13:31:56 |
| Last Modify:2022-05-20 07:50:19 | Copyright©Brick |
| home page | Tree |
| Annotation kernel can get tool activity | Download SCCT | Chinese |
Name:Get the perf_event_context for a task and lock it.* This has to cope with with the fact that until it is locked,* the context could get moved to another task.
Proto:static struct perf_event_context *perf_lock_task_context(struct task_struct *task, int ctxn, unsigned long *flags)
Type:struct perf_event_context
Parameter:
| Type | Parameter | Name |
|---|---|---|
| struct task_struct * | task | |
| int | ctxn | |
| unsigned long * | flags |
| 1373 | retry : |
| 1383 | local_irq_save( * flags) |
| 1386 | If ctx Then |
| 1398 | If ctx != fetch RCU-protected pointer for dereferencing(perf_event_ctxp[ctxn]) Then |
| 1401 | local_irq_restore( * flags) |
| 1402 | Go to retry |
| 1408 | ctx = NULL |
| 1409 | Else |
| 1410 | WARN_ON_ONCE(task != task) |
| 1414 | If Not ctx Then local_irq_restore( * flags) |
| 1416 | Return ctx |
| Name | Describe |
|---|---|
| perf_pin_task_context | Get the context for a task and increment its pin_count so it* can't get swapped to another task. This also increments its* reference count so that the context can't get freed. |
| find_get_context | Returns a matching context with refcount and pincount. |
| 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 |