Update of /cvsroot/linux-vax/kernel-2.5/arch/vax/kernel
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv17291/kernel
Modified Files:
syscall.c
Log Message:
- Add config options to switch off abortion of syscalls with wrong
number of arguments and the matching warning for it.
- Update ka4x_defconfig.
- This is only in place to help Kaj-Michael with TA-Linux. It'll go
away after his getty is fixed (which I think causes the error messages
he gets out of his system...).
Index: syscall.c
===================================================================
RCS file: /cvsroot/linux-vax/kernel-2.5/arch/vax/kernel/syscall.c,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -d -r1.10 -r1.11
--- syscall.c 12 Jun 2004 22:52:53 -0000 1.10
+++ syscall.c 16 Aug 2004 11:22:38 -0000 1.11
@@ -21,15 +21,12 @@
#include <asm/ptrace.h>
#include <asm/unistd.h>
#include <asm/ipc.h>
+#include <asm/thread_info.h>
#include "interrupt.h" /* Local, private definitions */
-/* This is the handler for the CHMK (change mode to kernel) trap.
- Later we'll probably re-write this in asm. */
extern unsigned long *sys_call_table[__NR_last_syscall + 1];
-extern unsigned long first_syscall;
-extern unsigned long last_syscall;
static int syscall_num_args[__NR_last_syscall + 1] = {
[0] = -1, /* setup */
@@ -320,15 +317,19 @@
nr_args = *user_ap;
}
+#ifdef DEBUG_VAX_CHECK_CHMx_ARGS
/*
* Check number of syscall arguments
*/
if (unlikely (syscall_num_args[sc_number] != nr_args)) {
printk (KERN_DEBUG "Stack mismatch (should=%d, caller=%d) on syscall %d\n",
syscall_num_args[sc_number], nr_args, sc_number);
+#ifdef DEBUG_VAX_CHECK_CHMx_ARGS_ABORT
regs->r0 = -EFAULT;
return;
+#endif /* DEBUG_VAX_CHECK_CHMx_ARGS_ABORT */
}
+#endif /* DEBUG_VAX_CHECK_CHMx_ARGS */
/*
* We pass all the user-supplied args plus the pointer to the
|