소스 검색

sched: use group_first_cpu() instead of cpumask_first(sched_group_cpus())

Impact: cleanup

This patch changes cpumask_first(sched_group_cpus()) to group_first_cpu()
for maintainability.

Signed-off-by: Miao Xie <miaox@cn.fujitsu.com>
Acked-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Miao Xie 16 년 전
부모
커밋
13318a7186
1개의 변경된 파일2개의 추가작업 그리고 2개의 파일을 삭제
  1. 2 2
      kernel/sched.c

+ 2 - 2
kernel/sched.c

@@ -7995,7 +7995,7 @@ static void init_numa_sched_groups_power(struct sched_group *group_head)
 			struct sched_domain *sd;
 			struct sched_domain *sd;
 
 
 			sd = &per_cpu(phys_domains, j).sd;
 			sd = &per_cpu(phys_domains, j).sd;
-			if (j != cpumask_first(sched_group_cpus(sd->groups))) {
+			if (j != group_first_cpu(sd->groups)) {
 				/*
 				/*
 				 * Only add "power" once for each
 				 * Only add "power" once for each
 				 * physical package.
 				 * physical package.
@@ -8073,7 +8073,7 @@ static void init_sched_groups_power(int cpu, struct sched_domain *sd)
 
 
 	WARN_ON(!sd || !sd->groups);
 	WARN_ON(!sd || !sd->groups);
 
 
-	if (cpu != cpumask_first(sched_group_cpus(sd->groups)))
+	if (cpu != group_first_cpu(sd->groups))
 		return;
 		return;
 
 
 	child = sd->child;
 	child = sd->child;