An x86_64 UEFI operating system.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

14 lines
385 B

use x86_64::structures::idt::{InterruptDescriptorTable, InterruptStackFrame};
static mut IDT: InterruptDescriptorTable = InterruptDescriptorTable::new();
pub fn load() {
unsafe {
IDT.breakpoint.set_handler_fn(breakpoint_handler);
IDT.load();
}
}
extern "x86-interrupt" fn breakpoint_handler(_: InterruptStackFrame) {
log::info!("Breakpoint reached!");
}