diff options
author | Alex Auvolat <alex@adnab.me> | 2015-03-09 22:06:59 +0100 |
---|---|---|
committer | Alex Auvolat <alex@adnab.me> | 2015-03-09 22:06:59 +0100 |
commit | e499d74b6f0b57f9a11486c346dbc335e4f8433d (patch) | |
tree | 91c35db2d0edc5147f874f5f36c51eca8dd7cdb3 /src/kernel/dev | |
parent | 380fd19521dd5205ef3da5248899244b5b29dc27 (diff) | |
download | kogata-e499d74b6f0b57f9a11486c346dbc335e4f8433d.tar.gz kogata-e499d74b6f0b57f9a11486c346dbc335e4f8433d.zip |
Update README
Diffstat (limited to 'src/kernel/dev')
-rw-r--r-- | src/kernel/dev/v86.c | 15 |
1 files changed, 5 insertions, 10 deletions
diff --git a/src/kernel/dev/v86.c b/src/kernel/dev/v86.c index 68bc375..183b791 100644 --- a/src/kernel/dev/v86.c +++ b/src/kernel/dev/v86.c @@ -207,17 +207,12 @@ void v86_ex_handler(registers_t *regs) { } void v86_pf_handler(void* zero, registers_t *regs, void* addr) { - if (addr < (void*)V86_STACK_TOP) { - pd_map_page(addr, (uint32_t)addr / PAGE_SIZE, true); - } else { - dbg_printf("Unexpected V86 PF at 0x%p\n", addr); + dbg_printf("Unexpected V86 PF at 0x%p\n", addr); - if (current_thread->user_ex_handler == v86_ex_handler) { - // we are in V86 thread - v86_exit_thread(false); - } else { - PANIC("V86 memory access exception."); - } + if (current_thread == v86_thread) { + v86_exit_thread(false); + } else { + PANIC("V86 memory access exception."); } } |