summaryrefslogtreecommitdiff
path: root/sys/dev
diff options
context:
space:
mode:
authorstefan <stefan@s00.xyz>2023-04-15 05:02:02 +0000
committerstefan <stefan@s00.xyz>2023-04-15 05:02:02 +0000
commitaf1ce4b2e637ceb418ea72d51c49a3eee276a938 (patch)
tree4d6a33644f8489e4f582f6e320bd6581b94fb642 /sys/dev
parent8cceb31dcaf4641d43f324fa3301b37859ebfade (diff)
downloadsv-af1ce4b2e637ceb418ea72d51c49a3eee276a938.tar.gz
added multiprocessor support
Diffstat (limited to 'sys/dev')
-rw-r--r--sys/dev/sbi.c39
1 files changed, 0 insertions, 39 deletions
diff --git a/sys/dev/sbi.c b/sys/dev/sbi.c
deleted file mode 100644
index 0c9e3f2..0000000
--- a/sys/dev/sbi.c
+++ /dev/null
@@ -1,39 +0,0 @@
-#include <sbi.h>
-
-struct sbiret
-sbi_ecall(int ext, int fid, unsigned long arg0,
- unsigned long arg1, unsigned long arg2,
- unsigned long arg3, unsigned long arg4,
- unsigned long arg5)
-{
- struct sbiret ret;
-
- register unsigned long a0 asm ("a0") = (unsigned long)(arg0);
- register unsigned long a1 asm ("a1") = (unsigned long)(arg1);
- register unsigned long a2 asm ("a2") = (unsigned long)(arg2);
- register unsigned long a3 asm ("a3") = (unsigned long)(arg3);
- register unsigned long a4 asm ("a4") = (unsigned long)(arg4);
- register unsigned long a5 asm ("a5") = (unsigned long)(arg5);
- register unsigned long a6 asm ("a6") = (unsigned long)(fid);
- register unsigned long a7 asm ("a7") = (unsigned long)(ext);
- asm volatile ("ecall"
- : "+r" (a0), "+r" (a1)
- : "r" (a2), "r" (a3), "r" (a4), "r" (a5), "r" (a6), "r" (a7)
- : "memory");
- ret.err = a0;
- ret.val = a1;
-
- return ret;
-}
-
-void
-sbi_console_putchar(int c)
-{
- sbi_ecall(1, 0, c, 0, 0, 0, 0, 0);
-}
-
-void
-sbi_shutdown(void)
-{
- sbi_ecall(8, 0, 0, 0, 0, 0, 0, 0);
-}