aboutsummaryrefslogtreecommitdiff
path: root/arch/score/kernel/sys_call_table.c
diff options
context:
space:
mode:
authorArnd Bergmann <arnd@arndb.de>2009-06-19 11:31:54 +0200
committerArnd Bergmann <arnd@arndb.de>2009-06-19 14:10:33 +0200
commitf673c032ed13ed8f3fda5922c2190da2892398bc (patch)
tree8e1145ed21188c77ffdfacba2b22a529c8ddb938 /arch/score/kernel/sys_call_table.c
parent78229db4c4f78f27ecf772fe7489a70530ba9862 (diff)
score: add generic sys_call_table
This adds back a sys_call_table to the score architecture, which got lost in the conversion to the generic unistd.h file. It's rather worrying that the code got submitted without a system call table, which evidently means that it got zero testing. Since the system call table has a different layout from the old one (which was modeled after the mips-o32 one), I also try to fix the entry.S path to use it. In the modified calling conventions, all system call arguments are passed as registers r4 through r9, instead of r4 through r7 plus stack for the fifth and sixth argument. This matches what other architectures to when they normally pass arguments on the stack. Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Diffstat (limited to 'arch/score/kernel/sys_call_table.c')
-rw-r--r--arch/score/kernel/sys_call_table.c12
1 files changed, 12 insertions, 0 deletions
diff --git a/arch/score/kernel/sys_call_table.c b/arch/score/kernel/sys_call_table.c
new file mode 100644
index 00000000000..287369b88c4
--- /dev/null
+++ b/arch/score/kernel/sys_call_table.c
@@ -0,0 +1,12 @@
+#include <linux/syscalls.h>
+#include <linux/signal.h>
+#include <linux/unistd.h>
+
+#include <asm/syscalls.h>
+
+#undef __SYSCALL
+#define __SYSCALL(nr, call) [nr] = (call),
+
+void *sys_call_table[__NR_syscalls] = {
+#include <asm/unistd.h>
+};