make GPE on CPL0 cause panic

This commit is contained in:
NAKAMURA Gou
2015-03-03 17:30:34 +09:00
parent 063fa963c3
commit 8db54c2637

View File

@ -615,6 +615,9 @@ void gpe_handler(struct x86_user_context *regs)
kprintf("General protection fault (err: %lx, %lx:%lx)\n",
regs->gpr.error, regs->gpr.cs, regs->gpr.rip);
arch_show_interrupt_context(regs);
if ((regs->gpr.cs & 3) == 0) {
panic("gpe_handler");
}
set_signal(SIGSEGV, regs, NULL);
check_signal(0, regs);
check_need_resched();