CoolPotOS/apps/include/syscall.h

22 lines
428 B
C
Raw Normal View History

2024-08-30 16:12:44 +08:00
#ifndef CRASHPOWEROS_SYSCALL_H
#define CRASHPOWEROS_SYSCALL_H
2024-08-31 12:36:49 +08:00
#define SYSCALL_PUTC 1
2024-08-30 16:12:44 +08:00
#define SYSCALL_PRINT 2
2024-08-31 01:23:06 +08:00
#define SYSCALL_GETC 3
2024-08-31 12:36:49 +08:00
#define SYSCALL_MALLOC 4
#define SYSCALL_FREE 5
#define SYSCALL_EXIT 6
2024-08-30 16:12:44 +08:00
#include <stdint.h>
2024-08-31 12:36:49 +08:00
#include <stddef.h>
2024-08-30 16:12:44 +08:00
2024-08-31 12:36:49 +08:00
void syscall_print(char* c);
void syscall_putchar(char c);
char syscall_getc();
void* syscall_malloc(size_t size);
void syscall_free(void *ptr);
void syscall_exit(int code);
2024-08-31 01:23:06 +08:00
2024-08-30 16:12:44 +08:00
#endif