diff options
author | Andreas Herrmann <andreas.herrmann3@amd.com> | 2009-08-18 06:59:28 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2009-08-18 12:35:43 -0400 |
commit | 86548096f252bfe2065f1ea2d301e7319a16375d (patch) | |
tree | ace19d728270cba803bf5d5704d59af6fa4627bd /kernel/sched.c | |
parent | a2af04cdbb748158043e31799b28c48272081600 (diff) |
sched: Separate out build of CPU sched groups from __build_sched_domains
... to further strip down __build_sched_domains().
Signed-off-by: Andreas Herrmann <andreas.herrmann3@amd.com>
Cc: Peter Zijlstra <peterz@infradead.org>
LKML-Reference: <20090818105928.GJ29515@alberich.amd.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'kernel/sched.c')
-rw-r--r-- | kernel/sched.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/kernel/sched.c b/kernel/sched.c index f2c202f66297..b09a41c93ae1 100644 --- a/kernel/sched.c +++ b/kernel/sched.c | |||
@@ -8586,6 +8586,13 @@ static void build_sched_groups(struct s_data *d, enum sched_domain_level l, | |||
8586 | d->send_covered, d->tmpmask); | 8586 | d->send_covered, d->tmpmask); |
8587 | break; | 8587 | break; |
8588 | #endif | 8588 | #endif |
8589 | case SD_LV_CPU: /* set up physical groups */ | ||
8590 | cpumask_and(d->nodemask, cpumask_of_node(cpu), cpu_map); | ||
8591 | if (!cpumask_empty(d->nodemask)) | ||
8592 | init_sched_build_groups(d->nodemask, cpu_map, | ||
8593 | &cpu_to_phys_group, | ||
8594 | d->send_covered, d->tmpmask); | ||
8595 | break; | ||
8589 | default: | 8596 | default: |
8590 | break; | 8597 | break; |
8591 | } | 8598 | } |
@@ -8631,15 +8638,8 @@ static int __build_sched_domains(const struct cpumask *cpu_map, | |||
8631 | } | 8638 | } |
8632 | 8639 | ||
8633 | /* Set up physical groups */ | 8640 | /* Set up physical groups */ |
8634 | for (i = 0; i < nr_node_ids; i++) { | 8641 | for (i = 0; i < nr_node_ids; i++) |
8635 | cpumask_and(d.nodemask, cpumask_of_node(i), cpu_map); | 8642 | build_sched_groups(&d, SD_LV_CPU, cpu_map, i); |
8636 | if (cpumask_empty(d.nodemask)) | ||
8637 | continue; | ||
8638 | |||
8639 | init_sched_build_groups(d.nodemask, cpu_map, | ||
8640 | &cpu_to_phys_group, | ||
8641 | d.send_covered, d.tmpmask); | ||
8642 | } | ||
8643 | 8643 | ||
8644 | #ifdef CONFIG_NUMA | 8644 | #ifdef CONFIG_NUMA |
8645 | /* Set up node groups */ | 8645 | /* Set up node groups */ |