crash_kexec should not be called with console_sem held. Move
the call before bust_spinlocks(0) in oops_end to avoid the
problem.
Signed-off-by: Alexander van Heukelum <heukelum@fastmail.fm>
Acked-by: "Neil Horman" <nhorman@tuxdriver.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
 
 void __kprobes oops_end(unsigned long flags, struct pt_regs *regs, int signr)
 {
+       if (regs && kexec_should_crash(current))
+               crash_kexec(regs);
+
        bust_spinlocks(0);
        die_owner = -1;
        add_taint(TAINT_DIE);
        if (!regs)
                return;
 
-       if (kexec_should_crash(current))
-               crash_kexec(regs);
        if (in_interrupt())
                panic("Fatal exception in interrupt");
        if (panic_on_oops)