Usermode/ld-acess - Fix x86_64 not saving RBP on no-arg syscalls
[tpg/acess2.git] / Usermode / Libraries / ld-acess.so_src / arch / x86_64.asm.h
index 9c52098..b80e092 100644 (file)
@@ -2,8 +2,6 @@
 ; AcssMicro - System Calls
 ; ========================
 
-%include "../../../Kernel/include/syscalls.inc.asm"
-
 [bits 64]
 
 [section .text]
@@ -58,9 +56,11 @@ _errno:      dw      0       ; Placed in .text, to allow use of relative addressing
 [global %1:func]
 %1:
        push rbx
+       push rbp
        mov eax, %2
        SYSCALL_OP
        mov [DWORD rel _errno], ebx
+       pop rbp
        pop rbx
        ret
 %endmacro

UCC git Repository :: git.ucc.asn.au