Syscall first parameter

This commit is contained in:
Adrien Bourmault 2021-02-26 18:10:25 +01:00
parent bc3e8323bd
commit aa0207cf67
Signed by: neox
GPG Key ID: 6EB408FE0ACEC664
1 changed files with 5 additions and 0 deletions

View File

@ -38,6 +38,11 @@
//
#define interrupt(n) asm volatile ("int %0" : : "N" (n) : "cc", "memory")
//
// Trigger a system call
//
#define syscall(n) asm volatile ("movq %0, %rdi\nint $0x80" : : "N" (n) : "cc", "memory")
//
// Returns whether IRQs are enabled
//