From 74881ac649742ea5b1b34c78ee365440e04ef046 Mon Sep 17 00:00:00 2001 From: Nick Johnson Date: Wed, 3 Mar 2021 04:04:51 -0600 Subject: [PATCH] Kernel: Make InstructionFetch PageFault flags match up (#5608) Previously, the instruction fetch flag of the page fault handler did not have the currect binary representation, and would always return false. This aligns these flags. --- Kernel/Arch/i386/CPU.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Kernel/Arch/i386/CPU.h b/Kernel/Arch/i386/CPU.h index ac0b4eb731..e343369a29 100644 --- a/Kernel/Arch/i386/CPU.h +++ b/Kernel/Arch/i386/CPU.h @@ -433,7 +433,7 @@ public: bool is_write() const { return (m_code & 2) == PageFaultFlags::Write; } bool is_user() const { return (m_code & 4) == PageFaultFlags::UserMode; } bool is_supervisor() const { return (m_code & 4) == PageFaultFlags::SupervisorMode; } - bool is_instruction_fetch() const { return (m_code & 8) == PageFaultFlags::InstructionFetch; } + bool is_instruction_fetch() const { return (m_code & 16) == PageFaultFlags::InstructionFetch; } private: u16 m_code;