(exit_code: QemuExitCode)
| 105 | } |
| 106 | |
| 107 | pub fn exit_qemu(exit_code: QemuExitCode) { |
| 108 | use x86_64::instructions::port::Port; |
| 109 | |
| 110 | unsafe { |
| 111 | let mut port = Port::new(0xf4); |
| 112 | port.write(exit_code as u32); |
| 113 | } |
| 114 | } |
| 115 | |
| 116 | // Allocator error handler |
| 117 | #[alloc_error_handler] |