x86: add debug of invalid per_cpu map accesses

dont crash survivable situations.

Signed-off-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
This commit is contained in:
Ingo Molnar 2008-01-30 13:33:23 +01:00
Родитель c49a4955ea
Коммит 5f5cd8fd60
1 изменённых файлов: 5 добавлений и 4 удалений

Просмотреть файл

@ -70,7 +70,8 @@ static inline int cpu_to_node(int cpu)
if (x86_cpu_to_node_map_early_ptr) {
printk("KERN_NOTICE cpu_to_node(%d): usage too early!\n",
(int)cpu);
BUG();
dump_stack();
return ((int *)x86_cpu_to_node_map_early_ptr)[cpu];
}
#endif
if (per_cpu_offset(cpu))