Function report |
Source Code:kernel\power\energy_model.c |
Create Date:2022-07-28 10:04:47 |
| Last Modify:2020-03-12 14:18:49 | Copyright©Brick |
| home page | Tree |
| Annotation kernel can get tool activity | Download SCCT | Chinese |
Name:m_register_perf_domain() - Register the Energy Model of a performance domain*@span : Mask of CPUs in the performance domain*@nr_states : Number of capacity states to register*@cb : Callback functions providing the data of the Energy Model* Create Energy
Proto:int em_register_perf_domain(cpumask_t *span, unsigned int nr_states, struct em_data_callback *cb)
Type:int
Parameter:
| Type | Parameter | Name |
|---|---|---|
| cpumask_t * | span | |
| unsigned int | nr_states | |
| struct em_data_callback * | cb |
| 202 | prev_cap = 0 |
| 204 | ret = 0 |
| 213 | mutex_lock( & Mutex serializing the registrations of performance domains and letting* callbacks defined by drivers sleep.) |
| 226 | cap = arch_scale_cpu_capacity(cpu) |
| 228 | pr_err("CPUs of %*pbl must have the same capacity\n", cpumask_pr_args - printf args to output a cpumask*@maskp: cpumask to be printed* Can be used to provide arguments for '%*pb[l]' when printing a cpumask.(span)) |
| 231 | Go to unlock |
| 237 | pd = em_create_pd(span, nr_states, cb) |
| 238 | If Not pd Then |
| 240 | Go to unlock |
| 253 | unlock : |
| 256 | Return ret |
| 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 |