aboutsummaryrefslogtreecommitdiff
path: root/system
diff options
context:
space:
mode:
authorBobby <[email protected]>2025-12-30 14:41:21 +0530
committerBobby <[email protected]>2025-12-30 14:41:21 +0530
commitdc9c5dcf04c7a5dab571a2fb1b3e79f7196a8c97 (patch)
treede99f14ce6b3e5656d85a3e8e16a5235bca90fea /system
parent5de74fe69126c5c28142b19770438f6a2ebf4f1e (diff)
downloadakiba-dc9c5dcf04c7a5dab571a2fb1b3e79f7196a8c97.tar.xz
akiba-dc9c5dcf04c7a5dab571a2fb1b3e79f7196a8c97.zip
feat: refactor Pulse init system to improve loading sequence and remove debug code
Diffstat (limited to 'system')
-rw-r--r--system/pulse/pulse.zig43
1 files changed, 4 insertions, 39 deletions
diff --git a/system/pulse/pulse.zig b/system/pulse/pulse.zig
index f1464a7..c558eb3 100644
--- a/system/pulse/pulse.zig
+++ b/system/pulse/pulse.zig
@@ -4,44 +4,9 @@
const akiba = @import("akiba");
export fn _start() noreturn {
- // IMMEDIATE DEBUG - write directly to port to bypass everything
- asm volatile (
- \\mov $0x3F8, %dx
- \\mov $'P', %al
- \\out %al, %dx
- \\mov $'U', %al
- \\out %al, %dx
- \\mov $'L', %al
- \\out %al, %dx
- \\mov $'S', %al
- \\out %al, %dx
- \\mov $'E', %al
- \\out %al, %dx
- \\mov $'!', %al
- \\out %al, %dx
- \\mov $'\n', %al
- \\out %al, %dx
- );
+ akiba.io.println("Pulse: System ready!") catch {};
- akiba.io.println("Pulse: Init system starting...") catch {};
-
- // Spawn echo as a test
- const child_pid = akiba.kata.spawn("/binaries/echo.akiba") catch {
- akiba.io.println("Pulse: Failed to spawn child") catch {};
- akiba.kata.exit(1);
- };
-
- akiba.io.println("Pulse: Spawned child process") catch {};
-
- // Wait for child to exit
- const exit_code = akiba.kata.wait(child_pid) catch {
- akiba.io.println("Pulse: Wait failed") catch {};
- akiba.kata.exit(1);
- };
-
- akiba.io.println("Pulse: Child process exited") catch {};
-
- // For now, just exit. Later: respawn shell or shutdown
- akiba.io.println("Pulse: Shutting down") catch {};
- akiba.kata.exit(exit_code);
+ while (true) {
+ akiba.kata.yield();
+ }
}