aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBen Hutchings <ben@decadent.org.uk>2021-12-27 19:48:29 +0100
committerBen Hutchings <ben@decadent.org.uk>2021-12-27 19:48:29 +0100
commitdf622860136f95868a36eae578482dc7b9687f50 (patch)
treecb75ceb06573dac5f733aabdadc870ee38d935ff
parent9129392a31774e6b63ab7231f1802a094e7eb90b (diff)
downloadklibc-df622860136f95868a36eae578482dc7b9687f50.tar.gz
[klibc] s390: mmap: Change inline assembly to work with Clang
Clang rejects the operand "%b1" to svc: usr/klibc/arch/s390/mmap.c:61:3: error: invalid operand in inline asm: ' svc ${1:b}' Since svc always takes an immediate operand, the "b" modifier is not needed. After deleting it, both Clang and gcc generate the correct instruction "svc 90". Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
-rw-r--r--usr/klibc/arch/s390/mmap.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/usr/klibc/arch/s390/mmap.c b/usr/klibc/arch/s390/mmap.c
index 33312397b56fb2..dfc5a8459cd482 100644
--- a/usr/klibc/arch/s390/mmap.c
+++ b/usr/klibc/arch/s390/mmap.c
@@ -58,7 +58,7 @@ void *mmap(void *addr, size_t len, int prot, int flags, int fd, off_t offset)
unsigned long __res;
__asm__ __volatile__ (
- " svc %b1\n"
+ " svc %1\n"
: "=d" (__svcres)
: "i" (__NR_mmap),
"0" (__arg1)