Skip to content

Commit

Permalink
Ensure intr/syscall handlers fits in per-process PT
Browse files Browse the repository at this point in the history
  • Loading branch information
djphoenix committed May 26, 2019
1 parent f1444fa commit 6a6e5f7
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/process/process.cpp
Expand Up @@ -277,7 +277,9 @@ void Process::startup() {
handler &= KB4;
sc_wrapper &= KB4;
addPage(handler, reinterpret_cast<void*>(handler), 1);
addPage(handler + 0x1000, reinterpret_cast<void*>(handler + 0x1000), 1);
addPage(sc_wrapper, reinterpret_cast<void*>(sc_wrapper), 1);
addPage(sc_wrapper + 0x1000, reinterpret_cast<void*>(sc_wrapper + 0x1000), 1);
GDT::Entry *gdt_ent = reinterpret_cast<GDT::Entry*>(uintptr_t(gdt.addr) + 8 * 3);
GDT::Entry *gdt_top = reinterpret_cast<GDT::Entry*>(uintptr_t(gdt.addr) + gdt.limit);

Expand Down

0 comments on commit 6a6e5f7

Please sign in to comment.