summaryrefslogtreecommitdiffstats
path: root/arch/um/include
diff options
context:
space:
mode:
authorAl Viro <viro@ftp.linux.org.uk>2007-05-15 20:36:00 +0100
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-05-15 18:56:37 -0700
commitecec5ba681a0bf1165899f8b1889f06fcd8e901a (patch)
treebacc286b05900e6a3f8dfc96386efc5dc85d660d /arch/um/include
parent327b9eebbf2b7ce632e93a9c1386d944af0dadf4 (diff)
downloadop-kernel-dev-ecec5ba681a0bf1165899f8b1889f06fcd8e901a.zip
op-kernel-dev-ecec5ba681a0bf1165899f8b1889f06fcd8e901a.tar.gz
fix uml-x86_64
__NR_syscall_max is done in x86_64 asm-offsets; do an equivalent in uml kern_constants.h Signed-off-by: Al Viro <viro@zeniv.linux.org.uk> Acked-by: Jeff Dike <jdike@addtoit.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'arch/um/include')
-rw-r--r--arch/um/include/sysdep-x86_64/kernel-offsets.h9
-rw-r--r--arch/um/include/sysdep-x86_64/syscalls.h3
2 files changed, 11 insertions, 1 deletions
diff --git a/arch/um/include/sysdep-x86_64/kernel-offsets.h b/arch/um/include/sysdep-x86_64/kernel-offsets.h
index a307237..c978b58 100644
--- a/arch/um/include/sysdep-x86_64/kernel-offsets.h
+++ b/arch/um/include/sysdep-x86_64/kernel-offsets.h
@@ -17,7 +17,16 @@
#define OFFSET(sym, str, mem) \
DEFINE(sym, offsetof(struct str, mem));
+#define __NO_STUBS 1
+#undef __SYSCALL
+#undef _ASM_X86_64_UNISTD_H_
+#define __SYSCALL(nr, sym) [nr] = 1,
+static char syscalls[] = {
+#include <asm/arch/unistd.h>
+};
+
void foo(void)
{
#include <common-offsets.h>
+DEFINE(UM_NR_syscall_max, sizeof(syscalls) - 1);
}
diff --git a/arch/um/include/sysdep-x86_64/syscalls.h b/arch/um/include/sysdep-x86_64/syscalls.h
index 5e86aa0..cf72256 100644
--- a/arch/um/include/sysdep-x86_64/syscalls.h
+++ b/arch/um/include/sysdep-x86_64/syscalls.h
@@ -9,6 +9,7 @@
#include <linux/msg.h>
#include <linux/shm.h>
+#include <kern_constants.h>
typedef long syscall_handler_t(void);
@@ -29,6 +30,6 @@ extern long old_mmap(unsigned long addr, unsigned long len,
extern syscall_handler_t sys_modify_ldt;
extern syscall_handler_t sys_arch_prctl;
-#define NR_syscalls (__NR_syscall_max + 1)
+#define NR_syscalls (UM_NR_syscall_max + 1)
#endif
OpenPOWER on IntegriCloud