diff --git a/init/main.c b/init/main.c index 2b1cdaab45e654bd1dd9c7d772c48e226e6ec20d..bc27d72bbb198fe8ea00dab91502711be811d3e8 100644 --- a/init/main.c +++ b/init/main.c @@ -538,6 +538,11 @@ asmlinkage void __init start_kernel(void) parse_args("Booting kernel", command_line, __start___param, __stop___param - __start___param, &unknown_bootoption); + if (!irqs_disabled()) { + printk(KERN_WARNING "start_kernel(): bug: interrupts were " + "enabled *very* early, fixing it\n"); + local_irq_disable(); + } sort_main_extable(); trap_init(); rcu_init();