Lines Matching refs:cpu

31 	unsigned int cpu;  in alloc_cpu_rmap()  local
55 for_each_possible_cpu(cpu) { in alloc_cpu_rmap()
56 rmap->near[cpu].index = cpu % size; in alloc_cpu_rmap()
57 rmap->near[cpu].dist = CPU_RMAP_DIST_INF; in alloc_cpu_rmap()
97 static bool cpu_rmap_copy_neigh(struct cpu_rmap *rmap, unsigned int cpu, in cpu_rmap_copy_neigh() argument
103 if (rmap->near[cpu].dist > dist && in cpu_rmap_copy_neigh()
105 rmap->near[cpu].index = rmap->near[neigh].index; in cpu_rmap_copy_neigh()
106 rmap->near[cpu].dist = dist; in cpu_rmap_copy_neigh()
117 unsigned int cpu; in debug_print_rmap() local
121 for_each_possible_cpu(cpu) { in debug_print_rmap()
122 index = rmap->near[cpu].index; in debug_print_rmap()
124 cpu, index, rmap->near[cpu].dist); in debug_print_rmap()
162 unsigned int cpu; in cpu_rmap_update() local
170 for_each_online_cpu(cpu) { in cpu_rmap_update()
171 if (rmap->near[cpu].index == index) { in cpu_rmap_update()
172 rmap->near[cpu].dist = CPU_RMAP_DIST_INF; in cpu_rmap_update()
173 cpumask_set_cpu(cpu, update_mask); in cpu_rmap_update()
182 for_each_cpu(cpu, affinity) { in cpu_rmap_update()
183 rmap->near[cpu].index = index; in cpu_rmap_update()
184 rmap->near[cpu].dist = 0; in cpu_rmap_update()
186 cpumask_of_node(cpu_to_node(cpu))); in cpu_rmap_update()
192 for_each_cpu(cpu, update_mask) { in cpu_rmap_update()
193 if (cpu_rmap_copy_neigh(rmap, cpu, in cpu_rmap_update()
194 topology_sibling_cpumask(cpu), 1)) in cpu_rmap_update()
196 if (cpu_rmap_copy_neigh(rmap, cpu, in cpu_rmap_update()
197 topology_core_cpumask(cpu), 2)) in cpu_rmap_update()
199 if (cpu_rmap_copy_neigh(rmap, cpu, in cpu_rmap_update()
200 cpumask_of_node(cpu_to_node(cpu)), 3)) in cpu_rmap_update()