Test initialisation of MUIA_List_AdjustWidth and MUIA_List_AdjustHeight, and
[AROS.git] / arch / all-linux / hidd / pcilinux / syscall.h
blobb2d1b34075748ae85065f2c094df9929ed9b0827
1 /*
2 * This driver uses direct hardware access, so it runs only on x86 machines.
3 * Additionally it uses iopl syscall which is available only on Linux.
5 * Since this driver is so machine-specific, we use direct syscalls and inline them
6 * here. If this driver is ever made portable and machine-independent, this will need to
7 * be replaced with libc functions called via hostlib.resource (on some UNIXes, for
8 * example on Darwin, syscalls are private API and no binary compatibility is
9 * guaranteed accross OS versions).
12 static inline int syscall1(IPTR num, IPTR arg1)
14 int ret;
16 asm volatile(
17 "int $0x80"
18 :"=a"(ret)
19 :"a"(num), "b"(arg1)
21 return ret;
24 static inline int syscall2(IPTR num, IPTR arg1, IPTR arg2)
26 int ret;
28 asm volatile(
29 "int $0x80"
30 :"=a"(ret)
31 :"a"(num), "b"(arg1), "c"(arg2)
33 return ret;