diff options
| author | Felix Morgner <felix.morgner@ost.ch> | 2026-03-21 09:06:05 +0100 |
|---|---|---|
| committer | Felix Morgner <felix.morgner@ost.ch> | 2026-03-21 09:06:05 +0100 |
| commit | cceaf717405059e8b02132d7c33f9fe3b2645b56 (patch) | |
| tree | 134b41bf36ea6b207ebccf6b6924f50c6405dda9 /arch/x86_64/src | |
| parent | 6a392e8e40f163470d7fb12e0846f2ec7bdee61a (diff) | |
| download | teachos-cceaf717405059e8b02132d7c33f9fe3b2645b56.tar.xz teachos-cceaf717405059e8b02132d7c33f9fe3b2645b56.zip | |
x86_64/cpu: log interrupt data in hex
Diffstat (limited to 'arch/x86_64/src')
| -rw-r--r-- | arch/x86_64/src/cpu/interrupts.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/arch/x86_64/src/cpu/interrupts.cpp b/arch/x86_64/src/cpu/interrupts.cpp index 2eec026..466389d 100644 --- a/arch/x86_64/src/cpu/interrupts.cpp +++ b/arch/x86_64/src/cpu/interrupts.cpp @@ -29,7 +29,7 @@ namespace arch::cpu auto const user = (frame->interrupt.error_code & 0x4) != 0; kstd::println(kstd::print_sink::stderr, "[x86_64:MMU] PAGE FAULT!"); - kstd::println(kstd::print_sink::stderr, "\tFault address: 0x{:x}", fault_address); + kstd::println(kstd::print_sink::stderr, "\tFault address: {:#018x}", fault_address); kstd::println(kstd::print_sink::stderr, "\tPresent: {}", present); kstd::println(kstd::print_sink::stderr, "\tWrite: {}", write); kstd::println(kstd::print_sink::stderr, "\tUser: {}", user); @@ -41,7 +41,7 @@ namespace arch::cpu auto handle_legacy_interrupt(interrupt_frame * frame) -> void { - kstd::println("[x86_64:SYS] Ignoring 8259 legacy interrupt {}", frame->interrupt.number); + kstd::println("[x86_64:SYS] Ignoring 8259 legacy interrupt {:#04x}", frame->interrupt.number); } } // namespace @@ -64,7 +64,7 @@ namespace arch::cpu handle_page_fault(frame); break; default: - kstd::println(kstd::print_sink::stderr, "[x86_64:SYS] Unhandled interrupt {} received with code {}", + kstd::println(kstd::print_sink::stderr, "[x86_64:SYS] Unhandled interrupt {:#04x} received with code {:#04x}", frame->interrupt.number, frame->interrupt.error_code); kapi::cpu::halt(); } |
