函数逻辑报告 |
Source Code:kernel\irq\affinity.c |
Create Date:2022-07-27 11:16:16 |
Last Modify:2020-03-12 14:18:49 | Copyright©Brick |
首页 | 函数Tree |
注解内核,赢得工具 | 下载SCCT | English |
函数名称:__irq_build_affinity_masks
函数原型:static int __irq_build_affinity_masks(unsigned int startvec, unsigned int numvecs, unsigned int firstvec, cpumask_var_t *node_to_cpumask, const struct cpumask *cpu_mask, struct cpumask *nmsk, struct irq_affinity_desc *masks)
返回类型:int
参数:
类型 | 参数 | 名称 |
---|---|---|
unsigned int | startvec | |
unsigned int | numvecs | |
unsigned int | firstvec | |
cpumask_var_t * | node_to_cpumask | |
const struct cpumask * | cpu_mask | |
struct cpumask * | nmsk | |
struct irq_affinity_desc * | masks |
255 | done等于0 |
258 | nodemsk等于NODE_MASK_NONE |
261 | 如果非pumask_weight - Count of bits in *srcp*@srcp: the cpumask to count bits (< nr_cpu_ids) in.则返回:0 |
264 | nodes等于get_nodes_in_cpumask(node_to_cpumask, cpu_mask, & nodemsk) |
277 | 返回:numvecs |
280 | node_vectors等于分配数组内存并置零 |
283 | 如果非node_vectors则返回:负ENOMEM |
290 | 以i小于nr_node_ids循环 |
292 | nv等于node_vectors[i] |
299 | ncpus等于pumask_weight - Count of bits in *srcp*@srcp: the cpumask to count bits (< nr_cpu_ids) in. |
300 | 如果非ncpus则继续下一循环 |
303 | WARN_ON_ONCE(nvectors > ncpus) |
306 | extra_vecs等于ncpus减nvectors乘ncpus除nvectors |
310 | cpus_per_vec等于ncpus除nvectors |
313 | 如果extra_vecs则 |
314 | cpus_per_vec自加 |
315 | extra_vecs先自减 |
324 | irq_spread_init_one( & mask, nmsk, cpus_per_vec) |
329 | 释放内存 |
330 | 返回:done |
名称 | 描述 |
---|---|
irq_build_affinity_masks | ld affinity in two stages:* 1) spread present CPU on these vectors* 2) spread other possible CPUs on these vectors |
源代码转换工具 开放的插件接口 | X |
---|---|
支持:c/c++/esqlc/java Oracle/Informix/Mysql 插件可实现:逻辑报告 代码生成和批量转换代码 |