Don't pass l (== curlwp) into the system call trace code.
Delete inclusion of opt_syscall_debug.h into systm.h, every kernel object file doesn't need to depend on opt_syscall_debug.h!
This commit is contained in:
parent
ba7a604397
commit
c9848793d9
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: kern_subr.c,v 1.170 2007/12/31 15:32:11 ad Exp $ */
|
||||
/* $NetBSD: kern_subr.c,v 1.171 2008/01/05 12:30:47 dsl Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 1997, 1998, 1999, 2002, 2007, 2006 The NetBSD Foundation, Inc.
|
||||
@ -86,7 +86,7 @@
|
||||
*/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: kern_subr.c,v 1.170 2007/12/31 15:32:11 ad Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: kern_subr.c,v 1.171 2008/01/05 12:30:47 dsl Exp $");
|
||||
|
||||
#include "opt_ddb.h"
|
||||
#include "opt_md.h"
|
||||
@ -1366,7 +1366,7 @@ trace_enter(struct lwp *l, register_t code, register_t realcode,
|
||||
struct proc *p = l->l_proc;
|
||||
|
||||
#ifdef SYSCALL_DEBUG
|
||||
scdebug_call(l, code, args);
|
||||
scdebug_call(code, args);
|
||||
#endif /* SYSCALL_DEBUG */
|
||||
|
||||
ktrsyscall(code, realcode, callp, args);
|
||||
@ -1396,7 +1396,7 @@ trace_exit(struct lwp *l, register_t code, const register_t *args,
|
||||
struct proc *p = l->l_proc;
|
||||
|
||||
#ifdef SYSCALL_DEBUG
|
||||
scdebug_ret(l, code, error, rval);
|
||||
scdebug_ret(code, error, rval);
|
||||
#endif /* SYSCALL_DEBUG */
|
||||
|
||||
ktrsysret(code, error, rval);
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: kern_xxx.c,v 1.67 2007/12/20 23:03:10 dsl Exp $ */
|
||||
/* $NetBSD: kern_xxx.c,v 1.68 2008/01/05 12:30:47 dsl Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 1982, 1986, 1989, 1993
|
||||
@ -32,7 +32,7 @@
|
||||
*/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: kern_xxx.c,v 1.67 2007/12/20 23:03:10 dsl Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: kern_xxx.c,v 1.68 2008/01/05 12:30:47 dsl Exp $");
|
||||
|
||||
#include "opt_syscall_debug.h"
|
||||
|
||||
@ -108,8 +108,9 @@ int scdebug = SCDEBUG_CALLS|SCDEBUG_RETURNS|SCDEBUG_SHOWARGS|SCDEBUG_ALL;
|
||||
#endif
|
||||
|
||||
void
|
||||
scdebug_call(struct lwp *l, register_t code, register_t args[])
|
||||
scdebug_call(register_t code, const register_t args[])
|
||||
{
|
||||
struct lwp *l = curlwp;
|
||||
struct proc *p = l->l_proc;
|
||||
const struct sysent *sy;
|
||||
const struct emul *em;
|
||||
@ -150,8 +151,9 @@ scdebug_call(struct lwp *l, register_t code, register_t args[])
|
||||
}
|
||||
|
||||
void
|
||||
scdebug_ret(struct lwp *l, register_t code, int error, register_t retval[])
|
||||
scdebug_ret(register_t code, int error, const register_t retval[])
|
||||
{
|
||||
struct lwp *l = curlwp;
|
||||
struct proc *p = l->l_proc;
|
||||
const struct sysent *sy;
|
||||
const struct emul *em;
|
||||
|
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: systm.h,v 1.207 2007/12/25 18:33:49 perry Exp $ */
|
||||
/* $NetBSD: systm.h,v 1.208 2008/01/05 12:30:47 dsl Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 1982, 1988, 1991, 1993
|
||||
@ -42,7 +42,6 @@
|
||||
#if defined(_KERNEL_OPT)
|
||||
#include "opt_ddb.h"
|
||||
#include "opt_multiprocessor.h"
|
||||
#include "opt_syscall_debug.h"
|
||||
#endif
|
||||
|
||||
#include <machine/endian.h>
|
||||
@ -466,10 +465,9 @@ extern int db_fromconsole; /* XXX ddb/ddbvar.h */
|
||||
#endif
|
||||
#endif /* _KERNEL */
|
||||
|
||||
#ifdef SYSCALL_DEBUG
|
||||
void scdebug_call(struct lwp *, register_t, register_t[]);
|
||||
void scdebug_ret(struct lwp *, register_t, int, register_t[]);
|
||||
#endif /* SYSCALL_DEBUG */
|
||||
/* For SYSCALL_DEBUG */
|
||||
void scdebug_call(register_t, const register_t[]);
|
||||
void scdebug_ret(register_t, int, const register_t[]);
|
||||
|
||||
void kernel_lock_init(void);
|
||||
void _kernel_lock(int, struct lwp *);
|
||||
|
Loading…
Reference in New Issue
Block a user