summaryrefslogtreecommitdiffhomepage
path: root/arch/nt32
diff options
context:
space:
mode:
authormidipix <writeonce@midipix.org>2016-06-21 15:55:17 -0400
committermidipix <writeonce@midipix.org>2016-06-21 15:55:17 -0400
commit4df0787e8987ab789e70a57ce7e480dffec14b80 (patch)
treeb664054495179b6eed5592dee922b00564436493 /arch/nt32
parent2d8d618a3998933912e5dba9a1f814fc646ca30c (diff)
downloadmmglue-4df0787e8987ab789e70a57ce7e480dffec14b80.tar.bz2
mmglue-4df0787e8987ab789e70a57ce7e480dffec14b80.tar.xz
__syscall_alert(): initial implementation and integration.
Diffstat (limited to 'arch/nt32')
-rw-r--r--arch/nt32/syscall_arch.h15
1 files changed, 8 insertions, 7 deletions
diff --git a/arch/nt32/syscall_arch.h b/arch/nt32/syscall_arch.h
index fb3cc46..9a5d4af 100644
--- a/arch/nt32/syscall_arch.h
+++ b/arch/nt32/syscall_arch.h
@@ -1,4 +1,5 @@
extern unsigned long ** __syscall_vtbl;
+extern long __syscall_alert(long);
typedef long __syscall0_fn(void);
typedef long __syscall1_fn(long a1);
@@ -14,43 +15,43 @@ typedef long __syscall6_fn(long a1, long a2, long a3, long a4, long a5, long a6)
static __inline long __syscall0(long n)
{
sysfn_from_fn(__syscall0_fn);
- return sysfn();
+ return sysfn ? sysfn() : __syscall_alert(n);
}
static __inline long __syscall1(long n, long a1)
{
sysfn_from_fn(__syscall1_fn);
- return sysfn(a1);
+ return sysfn ? sysfn(a1) : __syscall_alert(n);
}
static __inline long __syscall2(long n, long a1, long a2)
{
sysfn_from_fn(__syscall2_fn);
- return sysfn(a1, a2);
+ return sysfn ? sysfn(a1, a2) : __syscall_alert(n);
}
static __inline long __syscall3(long n, long a1, long a2, long a3)
{
sysfn_from_fn(__syscall3_fn);
- return sysfn(a1, a2, a3);
+ return sysfn ? sysfn(a1, a2, a3) : __syscall_alert(n);
}
static __inline long __syscall4(long n, long a1, long a2, long a3, long a4)
{
sysfn_from_fn(__syscall4_fn);
- return sysfn(a1, a2, a3, a4);
+ return sysfn ? sysfn(a1, a2, a3, a4) : __syscall_alert(n);
}
static __inline long __syscall5(long n, long a1, long a2, long a3, long a4, long a5)
{
sysfn_from_fn(__syscall5_fn);
- return sysfn(a1, a2, a3, a4, a5);
+ return sysfn ? sysfn(a1, a2, a3, a4, a5) : __syscall_alert(n);
}
static __inline long __syscall6(long n, long a1, long a2, long a3, long a4, long a5, long a6)
{
sysfn_from_fn(__syscall6_fn);
- return sysfn(a1, a2, a3, a4, a5, a6);
+ return sysfn ? sysfn(a1, a2, a3, a4, a5, a6) : __syscall_alert(n);
}