1
0
mirror of https://gitlab.os-k.eu/os-k-team/os-k.git synced 2023-08-25 14:03:10 +02:00

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

View File

@ -38,6 +38,11 @@
// //
#define interrupt(n) asm volatile ("int %0" : : "N" (n) : "cc", "memory") #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 // Returns whether IRQs are enabled
// //