21 #error syscall-stubs.h requires SERVICE to be defined 24 #error syscall-stubs.h requires SERVICE_ERROR to be defined 27 #error syscall-stubs.h requires SERVICE_INIT to be defined 30 static long syscall0(
long function)
32 long num = ((SERVICE & 0xFFFF) << 16) | (
function & 0xFFFF);
35 asm volatile(
"mov r0, %1; \ 39 :
"=r"(ret),
"=r"(SERVICE_ERROR)
44 static long syscall1(
long function,
long p1)
46 long num = ((SERVICE & 0xFFFF) << 16) | (
function & 0xFFFF);
49 asm volatile(
"mov r0, %1; \ 54 :
"=r"(ret),
"=r"(SERVICE_ERROR)
59 static long syscall2(
long function,
long p1,
long p2)
61 long num = ((SERVICE & 0xFFFF) << 16) | (
function & 0xFFFF);
64 asm volatile(
"mov r0, %1; \ 70 :
"=r"(ret),
"=r"(SERVICE_ERROR)
71 :
"r"(num),
"r"(p1),
"r"(p2));
75 static long syscall3(
long function,
long p1,
long p2,
long p3)
77 long num = ((SERVICE & 0xFFFF) << 16) | (
function & 0xFFFF);
80 asm volatile(
"mov r0, %1; \ 87 :
"=r"(ret),
"=r"(SERVICE_ERROR)
88 :
"r"(num),
"r"(p1),
"r"(p2),
"r"(p3));
94 static long syscall4(
long function,
long p1,
long p2,
long p3,
long p4)
96 long num = ((SERVICE & 0xFFFF) << 16) | (
function & 0xFFFF);
112 static long syscall5(
long function,
long p1,
long p2,
long p3,
long p4,
long p5)
114 long num = ((SERVICE & 0xFFFF) << 16) | (
function & 0xFFFF);