powerpc: Fix emulation of illegal instructions on PowerNV platform
[pandora-kernel.git] / arch / powerpc / kernel / traps.c
index 82dcd4d..9844662 100644 (file)
@@ -1036,6 +1036,16 @@ void __kprobes program_check_exception(struct pt_regs *regs)
                _exception(SIGILL, regs, ILL_ILLOPC, regs->nip);
 }
 
+/*
+ * This occurs when running in hypervisor mode on POWER6 or later
+ * and an illegal instruction is encountered.
+ */
+void __kprobes emulation_assist_interrupt(struct pt_regs *regs)
+{
+       regs->msr |= REASON_ILLEGAL;
+       program_check_exception(regs);
+}
+
 void alignment_exception(struct pt_regs *regs)
 {
        int sig, code, fixed = 0;