--- zzzz-none-000/linux-4.4.271/arch/mips/include/asm/fpu_emulator.h 2021-06-03 06:22:09.000000000 +0000 +++ dakota-7530ac-750/linux-4.4.271/arch/mips/include/asm/fpu_emulator.h 2023-01-11 09:25:41.000000000 +0000 @@ -30,6 +30,7 @@ #include #include +#ifdef CONFIG_MIPS_FPU_EMULATOR #ifdef CONFIG_DEBUG_FS struct mips_fpu_emulator_stats { @@ -66,6 +67,21 @@ extern int fpu_emulator_cop1Handler(struct pt_regs *xcp, struct mips_fpu_struct *ctx, int has_fpu, void *__user *fault_addr); +#else /* no CONFIG_MIPS_FPU_EMULATOR */ +static inline int do_dsemulret(struct pt_regs *xcp) +{ + return 0; /* 0 means error, should never get here anyway */ +} + +static inline int fpu_emulator_cop1Handler(struct pt_regs *xcp, + struct mips_fpu_struct *ctx, int has_fpu, + void *__user *fault_addr) +{ + *fault_addr = NULL; + return SIGILL; /* we don't speak MIPS FPU */ +} +#endif /* CONFIG_MIPS_FPU_EMULATOR */ + void force_fcr31_sig(unsigned long fcr31, void __user *fault_addr, struct task_struct *tsk); int process_fpemu_return(int sig, void __user *fault_addr,