summaryrefslogtreecommitdiff
path: root/include/linux/sched.h
diff options
context:
space:
mode:
authorPeter Zijlstra <a.p.zijlstra@chello.nl>2011-04-07 14:10:04 +0200
committerIngo Molnar <mingo@elte.hu>2011-04-11 14:09:32 +0200
commit60495e7760d8ee364695006af37309b0755e0e17 (patch)
tree1c842c0797a6a6b0066b18f296661fcf77cd0d0a /include/linux/sched.h
parent54ab4ff4316eb329d2c1acc110fbc623d2966931 (diff)
sched: Dynamic sched_domain::level
Remove the SD_LV_ enum and use dynamic level assignments. Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl> Cc: Mike Galbraith <efault@gmx.de> Cc: Nick Piggin <npiggin@kernel.dk> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Andrew Morton <akpm@linux-foundation.org> Link: http://lkml.kernel.org/r/20110407122942.969433965@chello.nl Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'include/linux/sched.h')
-rw-r--r--include/linux/sched.h23
1 files changed, 3 insertions, 20 deletions
diff --git a/include/linux/sched.h b/include/linux/sched.h
index 09d9e02f2b61..e43e5b0ab0b5 100644
--- a/include/linux/sched.h
+++ b/include/linux/sched.h
@@ -892,25 +892,6 @@ static inline struct cpumask *sched_group_cpus(struct sched_group *sg)
return to_cpumask(sg->cpumask);
}
-enum sched_domain_level {
- SD_LV_NONE = 0,
-#ifdef CONFIG_SCHED_SMT
- SD_LV_SIBLING,
-#endif
-#ifdef CONFIG_SCHED_MC
- SD_LV_MC,
-#endif
-#ifdef CONFIG_SCHED_BOOK
- SD_LV_BOOK,
-#endif
- SD_LV_CPU,
-#ifdef CONFIG_NUMA
- SD_LV_NODE,
- SD_LV_ALLNODES,
-#endif
- SD_LV_MAX
-};
-
struct sched_domain_attr {
int relax_domain_level;
};
@@ -919,6 +900,8 @@ struct sched_domain_attr {
.relax_domain_level = -1, \
}
+extern int sched_domain_level_max;
+
struct sched_domain {
/* These fields must be setup */
struct sched_domain *parent; /* top domain must be null terminated */
@@ -936,7 +919,7 @@ struct sched_domain {
unsigned int forkexec_idx;
unsigned int smt_gain;
int flags; /* See SD_* */
- enum sched_domain_level level;
+ int level;
/* Runtime fields. */
unsigned long last_balance; /* init to jiffies. units in jiffies */