aboutsummaryrefslogtreecommitdiff
path: root/src/debugcon.zig
diff options
context:
space:
mode:
authorMarin Ivanov <[email protected]>2024-05-02 01:07:26 +0300
committerMarin Ivanov <[email protected]>2024-05-02 01:07:26 +0300
commit476d95c3d01d085013d2986997d0232c3a97d27b (patch)
tree29dff4a771f1f95ae96f98684871f35442e237a7 /src/debugcon.zig
parentb443cf5d72a3b5b11331475a29772eca63479377 (diff)
write in console and debugcon
Diffstat (limited to 'src/debugcon.zig')
-rw-r--r--src/debugcon.zig7
1 files changed, 2 insertions, 5 deletions
diff --git a/src/debugcon.zig b/src/debugcon.zig
index 6014637..e721a4d 100644
--- a/src/debugcon.zig
+++ b/src/debugcon.zig
@@ -14,10 +14,7 @@ pub fn outb(port: u16, data: u8) void {
}
pub fn write(data: []const u8) void {
- const len: u8 = @intCast(data.len & 0xFF);
- outb(0xe9, 0x30 + len);
- for (0..len) |i| {
- outb(0xe9, 0x30);
- outb(0xe9, data[i]);
+ for (data) |x| {
+ outb(0xe9, x);
}
}