From 405b5b1018397bff48e32c75e10a6b3b58bb6a20 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Matteo=20Gm=C3=BCr?= Date: Fri, 21 Feb 2025 14:13:39 +0000 Subject: Update factory method code --- arch/x86_64/src/memory/cpu/control_register.cpp | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) (limited to 'arch/x86_64/src/memory/cpu') diff --git a/arch/x86_64/src/memory/cpu/control_register.cpp b/arch/x86_64/src/memory/cpu/control_register.cpp index 298874f..7ee88b5 100644 --- a/arch/x86_64/src/memory/cpu/control_register.cpp +++ b/arch/x86_64/src/memory/cpu/control_register.cpp @@ -1,6 +1,6 @@ #include "arch/memory/cpu/control_register.hpp" -#include "arch/exception_handling/assert.hpp" +#include "arch/exception_handling/panic.hpp" #include @@ -24,8 +24,7 @@ namespace teachos::arch::memory::cpu asm volatile("mov %%cr4, %[output]" : [output] "=r"(current_value)); break; default: - exception_handling::assert(false, - "[Control Register] Attempted to read non-existent or reserved control register"); + exception_handling::panic("[Control Register] Attempted to read non-existent or reserved control register"); break; } return current_value; @@ -60,8 +59,7 @@ namespace teachos::arch::memory::cpu : "memory"); break; default: - exception_handling::assert(false, - "[Control Register] Attempted to write non-existent or reserved control register"); + exception_handling::panic("[Control Register] Attempted to write non-existent or reserved control register"); break; } } -- cgit v1.2.3