aboutsummaryrefslogtreecommitdiff
path: root/src/kernel/syscall/actions
diff options
context:
space:
mode:
authorMarvin Borner2019-11-30 21:07:22 +0100
committerMarvin Borner2019-11-30 21:07:22 +0100
commit50f949d994c33ab23d63bdb9e8a438560ab0b4c4 (patch)
tree35089087979bd8cee4693c71264b1c537336e4dd /src/kernel/syscall/actions
parentac947d45c288f62e927895afe7cd6a722ffdd8f8 (diff)
Working userspace!
Diffstat (limited to 'src/kernel/syscall/actions')
-rw-r--r--src/kernel/syscall/actions/sys_write.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/kernel/syscall/actions/sys_write.c b/src/kernel/syscall/actions/sys_write.c
new file mode 100644
index 0000000..c537d12
--- /dev/null
+++ b/src/kernel/syscall/actions/sys_write.c
@@ -0,0 +1,9 @@
+#include <stdint-gcc.h>
+#include <mlibc/stdio.h>
+
+uint32_t sys_write(char *buf, uint32_t count)
+{
+ for (uint32_t i = 0; i < count; i++)
+ writec(*(buf++));
+ return count;
+} \ No newline at end of file