X-Git-Url: https://scm.lunaixsky.com/lunaix-os.git/blobdiff_plain/28c176b668c841a3b7fb093faccf0efa39257603..bffa3430fbbaaad29bec0b5bee9c1f0bfc7fd068:/lunaix-os/arch/x86/syscall64.S diff --git a/lunaix-os/arch/x86/syscall64.S b/lunaix-os/arch/x86/syscall64.S index f4ea8bd..624002f 100644 --- a/lunaix-os/arch/x86/syscall64.S +++ b/lunaix-os/arch/x86/syscall64.S @@ -106,14 +106,14 @@ ret 1: - - movq irbx(%rbx), %rdi /* rbx -> rdi #1 arg */ - movq ircx(%rbx), %rsi /* rcx -> rsi #2 arg */ - movq irdx(%rbx), %rdx /* rdx -> rdx #3 arg */ - movq irdi(%rbx), %rcx /* rdi -> rcx #4 arg */ - movq irsi(%rbx), %r8 /* rsi -> r8 #5 arg */ + movq (%rax), %rdi + movq irbx(%rbx), %rsi /* rbx -> rsi #1 arg */ + movq ircx(%rbx), %rdx /* rcx -> rdx #2 arg */ + movq irdx(%rbx), %rcx /* rdx -> rcx #3 arg */ + movq irdi(%rbx), %r8 /* rdi -> r8 #4 arg */ + movq irsi(%rbx), %r9 /* rsi -> r9 #5 arg */ - call *(%rax) + call dispatch_syscall movq %rax, irax(%rbx) /* save the return value */