|
| 1 | +diff --git linux_syscall_support.h linux_syscall_support.h |
| 2 | +index 99a4b44..00b3a5c 100644 |
| 3 | +--- linux_syscall_support.h |
| 4 | ++++ linux_syscall_support.h |
| 5 | +@@ -3940,16 +3940,16 @@ struct kernel_statx { |
| 6 | + * So, we just have to redefine all of the _syscallX() macros. |
| 7 | + */ |
| 8 | + #undef LSS_REG |
| 9 | +- #define LSS_REG(ar,a) register int64_t __r##ar __asm__("a"#ar) = (int64_t)a |
| 10 | ++ #define LSS_REG(ar,a) register int64_t __r##ar __asm__("$a"#ar) = (int64_t)a |
| 11 | + /* syscall is like subroutine calls, all caller-saved registers may be |
| 12 | + * clobbered, we should add them to the |Clobbers| list. |
| 13 | + * a0 is not included because it's in the output list. |
| 14 | + */ |
| 15 | +- #define LSS_SYSCALL_CLOBBERS "t0", "t1", "t2", "t3", "t4", "t5", "t6", \ |
| 16 | +- "t7", "t8", "memory" |
| 17 | ++ #define LSS_SYSCALL_CLOBBERS "$t0", "$t1", "$t2", "$t3", "$t4", "$t5", "$t6", \ |
| 18 | ++ "$t7", "$t8", "memory" |
| 19 | + #undef LSS_BODY |
| 20 | + #define LSS_BODY(type,name,args...) \ |
| 21 | +- register int64_t __res_a0 __asm__("a0"); \ |
| 22 | ++ register int64_t __res_a0 __asm__("$a0"); \ |
| 23 | + int64_t __res; \ |
| 24 | + __asm__ __volatile__ ("li.d $a7, %1\n" \ |
| 25 | + "syscall 0x0\n" \ |
| 26 | +@@ -4013,12 +4013,12 @@ struct kernel_statx { |
| 27 | + void *newtls, int *child_tidptr) { |
| 28 | + int64_t __res; |
| 29 | + { |
| 30 | +- register int64_t __res_a0 __asm__("a0"); |
| 31 | +- register uint64_t __flags __asm__("a0") = flags; |
| 32 | +- register void *__stack __asm__("a1") = child_stack; |
| 33 | +- register void *__ptid __asm__("a2") = parent_tidptr; |
| 34 | +- register void *__tls __asm__("a3") = newtls; |
| 35 | +- register int *__ctid __asm__("a4") = child_tidptr; |
| 36 | ++ register int64_t __res_a0 __asm__("$a0"); |
| 37 | ++ register uint64_t __flags __asm__("$a0") = flags; |
| 38 | ++ register void *__stack __asm__("$a1") = child_stack; |
| 39 | ++ register void *__ptid __asm__("$a2") = parent_tidptr; |
| 40 | ++ register void *__tls __asm__("$a3") = newtls; |
| 41 | ++ register int *__ctid __asm__("$a4") = child_tidptr; |
| 42 | + __asm__ __volatile__(/* Push "arg" and "fn" onto the stack that will be |
| 43 | + * used by the child. |
| 44 | + */ |
0 commit comments