Add and use hlt_loop function

This commit is contained in:
Philipp Oppermann
2019-01-25 14:16:29 +01:00
parent 599a643d97
commit c2e4e8c96f
3 changed files with 10 additions and 4 deletions

View File

@@ -12,3 +12,9 @@ pub unsafe fn exit_qemu() {
let mut port = Port::<u32>::new(0xf4);
port.write(0);
}
pub fn hlt_loop() -> ! {
loop {
x86_64::instructions::hlt();
}
}