Function report |
Source Code:kernel\padata.c |
Create Date:2022-07-28 13:47:18 |
| Last Modify:2020-03-12 14:18:49 | Copyright©Brick |
| home page | Tree |
| Annotation kernel can get tool activity | Download SCCT | Chinese |
Name:padata_do_parallel - padata parallelization function*@ps: padatashell*@padata: object to be parallelized*@cb_cpu: pointer to the CPU that the serialization callback function should* run on. If it's not in the serial cpumask of @pinst* (i
Proto:int padata_do_parallel(struct padata_shell *ps, struct padata_priv *padata, int *cb_cpu)
Type:int
Parameter:
| Type | Parameter | Name |
|---|---|---|
| struct padata_shell * | ps | |
| struct padata_priv * | padata | |
| int * | cb_cpu |
| 116 | If Not (flags & PADATA_INIT) || flags & PADATA_INVALID Then Go to out |
| 120 | If Not pumask_weight - Count of bits in *srcp*@srcp: the cpumask to count bits (< nr_cpu_ids) in. Then Go to out |
| 124 | cpu_index = cb_cpu % pumask_weight - Count of bits in *srcp*@srcp: the cpumask to count bits (< nr_cpu_ids) in. |
| 134 | If flags & PADATA_RESET Then Go to out |
| 137 | If atomic_read( & refcnt) >= MAX_OBJ_NUM Then Go to out |
| 140 | err = 0 |
| 141 | atomic_inc( & refcnt) |
| 145 | seq_nr = atomic_inc_return( & seq_nr) |
| 146 | target_cpu = padata_cpu_hash(pd, seq_nr) |
| 147 | cpu = target_cpu |
| 148 | queue = per_cpu_ptr(pqueue, target_cpu) |
| 152 | spin_unlock( & lock) |
| 156 | out : |
| 159 | Return err |
| 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 |