diff options
author | Valentin Schneider | 2020-08-17 12:29:55 +0100 |
---|---|---|
committer | Ingo Molnar | 2020-08-19 10:49:48 +0200 |
commit | ab65afb094c7b2e954e8d56ffbc7df843211c2c8 (patch) | |
tree | 65eacab77cc6814334f595ab9e9fce3e0ee19e26 /kernel/sched/topology.c | |
parent | 6f349818621dff364fc000909135d0065e9756c9 (diff) |
sched/topology: Remove SD_SERIALIZE degeneration special case
If there is only a single NUMA node in the system, the only NUMA topology
level that will be generated will be NODE (identity distance), which
doesn't have SD_SERIALIZE.
This means we don't need this special case in sd_parent_degenerate(), as
having the NODE level "naturally" covers it. Thus, remove it.
Suggested-by: Peter Zijlstra <peterz@infradead.org>
Signed-off-by: Valentin Schneider <valentin.schneider@arm.com>
Signed-off-by: Ingo Molnar <mingo@kernel.org>
Reviewed-by: Dietmar Eggemann <dietmar.eggemann@arm.com>
Acked-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Link: https://lore.kernel.org/r/20200817113003.20802-10-valentin.schneider@arm.com
Diffstat (limited to 'kernel/sched/topology.c')
-rw-r--r-- | kernel/sched/topology.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/kernel/sched/topology.c b/kernel/sched/topology.c index 38e6671c3bd7..c662c53736e2 100644 --- a/kernel/sched/topology.c +++ b/kernel/sched/topology.c @@ -183,11 +183,9 @@ sd_parent_degenerate(struct sched_domain *sd, struct sched_domain *parent) return 0; /* Flags needing groups don't count if only 1 group in parent */ - if (parent->groups == parent->groups->next) { + if (parent->groups == parent->groups->next) pflags &= ~(SD_DEGENERATE_GROUPS_MASK | SD_PREFER_SIBLING); - if (nr_node_ids == 1) - pflags &= ~SD_SERIALIZE; - } + if (~cflags & pflags) return 0; |