projects
/
cascardo
/
linux.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
x86/topology: Handle CPUID bogosity gracefully
[cascardo/linux.git]
/
arch
/
x86
/
kernel
/
smpboot.c
diff --git
a/arch/x86/kernel/smpboot.c
b/arch/x86/kernel/smpboot.c
index
a2065d3
..
0e4329e
100644
(file)
--- a/
arch/x86/kernel/smpboot.c
+++ b/
arch/x86/kernel/smpboot.c
@@
-332,6
+332,11
@@
static void __init smp_init_package_map(void)
* primary cores.
*/
ncpus = boot_cpu_data.x86_max_cores;
+ if (!ncpus) {
+ pr_warn("x86_max_cores == zero !?!?");
+ ncpus = 1;
+ }
+
__max_logical_packages = DIV_ROUND_UP(total_cpus, ncpus);
/*