X-Git-Url: http://pileus.org/git/?a=blobdiff_plain;f=arch%2Falpha%2Fkernel%2Ftraps.c;fp=arch%2Falpha%2Fkernel%2Ftraps.c;h=9c4c189eb22f5a9db2d2ae678756a5241b3e1ee5;hb=d5bdaf4f68f0590fc481bca54bcaffeb27b75fca;hp=bd0665cdc840d3e9a79b752ec3a88279ede69344;hpb=dc6ec87d4c77029457a79fd6fa9b6f8304dc8348;p=~andy%2Flinux diff --git a/arch/alpha/kernel/traps.c b/arch/alpha/kernel/traps.c index bd0665cdc84..9c4c189eb22 100644 --- a/arch/alpha/kernel/traps.c +++ b/arch/alpha/kernel/traps.c @@ -241,6 +241,21 @@ do_entIF(unsigned long type, struct pt_regs *regs) (const char *)(data[1] | (long)data[2] << 32), data[0]); } +#ifdef CONFIG_ALPHA_WTINT + if (type == 4) { + /* If CALL_PAL WTINT is totally unsupported by the + PALcode, e.g. MILO, "emulate" it by overwriting + the insn. */ + unsigned int *pinsn + = (unsigned int *) regs->pc - 1; + if (*pinsn == PAL_wtint) { + *pinsn = 0x47e01400; /* mov 0,$0 */ + imb(); + regs->r0 = 0; + return; + } + } +#endif /* ALPHA_WTINT */ die_if_kernel((type == 1 ? "Kernel Bug" : "Instruction fault"), regs, type, NULL); }