summaryrefslogtreecommitdiff
path: root/lib/armflush.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/armflush.c')
-rw-r--r--lib/armflush.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/lib/armflush.c b/lib/armflush.c
index eae3260..13955e1 100644
--- a/lib/armflush.c
+++ b/lib/armflush.c
@@ -7,12 +7,12 @@
#ifdef __TINYC__
/* syscall wrapper */
-unsigned syscall(unsigned syscall_nr, ...);
+unsigned _tccsyscall(unsigned syscall_nr, ...);
/* arm-tcc supports only fake asm currently */
__asm__(
- ".global syscall\n"
- "syscall:\n"
+ ".global _tccsyscall\n"
+ "_tccsyscall:\n"
".int 0xe92d4080\n" // push {r7, lr}
".int 0xe1a07000\n" // mov r7, r0
".int 0xe1a00001\n" // mov r0, r1
@@ -31,6 +31,8 @@ __asm__(
#define __ARM_NR_BASE (__NR_SYSCALL_BASE+0x0f0000)
#define __ARM_NR_cacheflush (__ARM_NR_BASE+2)
+#define syscall _tccsyscall
+
#else
#define _GNU_SOURCE