ppc: Various minor compile fixes
[sfrench/cifs-2.6.git] / arch / ppc / kernel / traps.c
index 26606aa33de6e292a0689e19ab0c8694ede75c8c..3145e9773db99a01b1f10af6cd6e92e4830af501 100644 (file)
 #include <asm/perfmon.h>
 
 #ifdef CONFIG_XMON
+extern int xmon_bpt(struct pt_regs *regs);
+extern int xmon_sstep(struct pt_regs *regs);
+extern int xmon_iabr_match(struct pt_regs *regs);
+extern int xmon_dabr_match(struct pt_regs *regs);
+
 void (*debugger)(struct pt_regs *regs) = xmon;
 int (*debugger_bpt)(struct pt_regs *regs) = xmon_bpt;
 int (*debugger_sstep)(struct pt_regs *regs) = xmon_sstep;
@@ -814,6 +819,17 @@ void TAUException(struct pt_regs *regs)
 }
 #endif /* CONFIG_INT_TAU */
 
+/*
+ * FP unavailable trap from kernel - print a message, but let
+ * the task use FP in the kernel until it returns to user mode.
+ */
+void kernel_fp_unavailable_exception(struct pt_regs *regs)
+{
+       regs->msr |= MSR_FP;
+       printk(KERN_ERR "floating point used in kernel (task=%p, pc=%lx)\n",
+              current, regs->nip);
+}
+
 void altivec_unavailable_exception(struct pt_regs *regs)
 {
        static int kernel_altivec_count;