summaryrefslogtreecommitdiffstats
path: root/arch/x86_64/lib/printf.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/x86_64/lib/printf.c')
-rw-r--r--arch/x86_64/lib/printf.c25
1 files changed, 0 insertions, 25 deletions
diff --git a/arch/x86_64/lib/printf.c b/arch/x86_64/lib/printf.c
deleted file mode 100644
index db47f6b..0000000
--- a/arch/x86_64/lib/printf.c
+++ /dev/null
@@ -1,25 +0,0 @@
-#include "../hal/serial_com.h"
-#include "lib/printf.h"
-#include "lib/virtterm.h"
-#include "proc/init.h"
-#include "sys/objdir.h"
-
-int
-kvprintf(const char *fmt, va_list ap)
-{
- char buffer[256] = { 0 };
- int r = vsnprintf(buffer, 256, fmt, ap);
- int wlen = (r > 256 ? 256 : r);
-
- {
- jove_owned_obj_t *serial_obj = objdir_getlocal(_rootdir_obj, INIT_ROOTDIR_SERIAL_COM_I);
- serial_com_write(serial_obj, buffer, wlen);
- obj_release(serial_obj);
-
- jove_owned_obj_t *vt_obj = objdir_getlocal(_rootdir_obj, INIT_ROOTDIR_VIRTTERM_I);
- vt_write(vt_obj, buffer, wlen);
- obj_release(vt_obj);
- }
-
- return r;
-}