diff options
author | Christian Cunningham <cc@localhost> | 2022-02-01 18:25:51 -0700 |
---|---|---|
committer | Christian Cunningham <cc@localhost> | 2022-02-01 18:25:51 -0700 |
commit | e71ca9d94c38d61096e587e1fa17a8b79cd89397 (patch) | |
tree | 866edbd5b74a2b02f6c8c599ce0175a81c4f2ecf /include | |
parent | 36f2d87ee57e841be5fe60f6430bdd167f9f03af (diff) |
Started syscalling
Diffstat (limited to 'include')
-rw-r--r-- | include/cpu.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/include/cpu.h b/include/cpu.h index 68638a5..52d016b 100644 --- a/include/cpu.h +++ b/include/cpu.h @@ -76,4 +76,11 @@ static inline void* getirqstack(void) return sp; } +#define syscall_h_quote(text) #text +#define syscall_h_expand_and_quote(text) syscall_h_quote(text) + +#define sys0(sys_n) asm volatile("svc #" syscall_h_expand_and_quote(sys_n) ::: "r0", "r1", "r2", "r3", "lr"); + +#define SYS_SCHED 2 + #endif |