aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--arch/x86/kernel/setup.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/arch/x86/kernel/setup.c b/arch/x86/kernel/setup.c
index dd12c1c84a8..df49ce87a30 100644
--- a/arch/x86/kernel/setup.c
+++ b/arch/x86/kernel/setup.c
@@ -350,6 +350,7 @@ cpumask_t *_node_to_cpumask_ptr(int node)
dump_stack();
return &cpu_online_map;
}
+ BUG_ON(node >= nr_node_ids);
return &node_to_cpumask_map[node];
}
EXPORT_SYMBOL(_node_to_cpumask_ptr);
@@ -365,6 +366,7 @@ cpumask_t node_to_cpumask(int node)
dump_stack();
return cpu_online_map;
}
+ BUG_ON(node >= nr_node_ids);
return node_to_cpumask_map[node];
}
EXPORT_SYMBOL(node_to_cpumask);