os/syscall.c

26 lines
382 B
C
Raw Normal View History

2024-05-21 18:41:16 +03:00
#include <stdint.h>
#include "interrupts.h"
#include "syscall.h"
#include "tty.h"
void test_syscall()
{
terminal_printc("Test syscall called\n");
}
void syscall_handler(Stack *registers)
{
int sys_index = registers->eax;
if (sys_index != 0)
{
return;
}
test_syscall();
}
void syscall_init(void)
{
isr_install_handler(128, syscall_handler);
}