aboutsummaryrefslogtreecommitdiffstats
path: root/halt-rs/src
diff options
context:
space:
mode:
Diffstat (limited to 'halt-rs/src')
-rw-r--r--halt-rs/src/lib.rs13
1 files changed, 13 insertions, 0 deletions
diff --git a/halt-rs/src/lib.rs b/halt-rs/src/lib.rs
new file mode 100644
index 0000000..4ee0bdd
--- /dev/null
+++ b/halt-rs/src/lib.rs
@@ -0,0 +1,13 @@
+#![no_std]
+
+use libpintos::exit;
+
+#[panic_handler]
+fn panic(_info: &core::panic::PanicInfo) -> ! {
+ loop {}
+}
+
+#[no_mangle]
+pub unsafe extern "C" fn entry() {
+ exit(0x42);
+}