diff options
author | Artur Grabowski <art@cvs.openbsd.org> | 2000-11-10 18:15:50 +0000 |
---|---|---|
committer | Artur Grabowski <art@cvs.openbsd.org> | 2000-11-10 18:15:50 +0000 |
commit | 7c2c0cece14deee41a6cc3def2928808d73881b0 (patch) | |
tree | 871f91c39959ffa32ae5ac773513265eb121d8c9 | |
parent | 38a9424b2fc187e798fe3a91366490408b112921 (diff) |
Change the ktrace interface functions from taking the trace vnode to taking the
traced proc. The vnode is in the proc and all functions need the proc.
30 files changed, 153 insertions, 162 deletions
diff --git a/sys/arch/alpha/alpha/trap.c b/sys/arch/alpha/alpha/trap.c index 157814b717c..25d5cd6870f 100644 --- a/sys/arch/alpha/alpha/trap.c +++ b/sys/arch/alpha/alpha/trap.c @@ -1,4 +1,4 @@ -/* $OpenBSD: trap.c,v 1.21 2000/11/08 19:16:59 ericj Exp $ */ +/* $OpenBSD: trap.c,v 1.22 2000/11/10 18:15:33 art Exp $ */ /* $NetBSD: trap.c,v 1.52 2000/05/24 16:48:33 thorpej Exp $ */ /*- @@ -680,7 +680,7 @@ syscall(code, framep) } #ifdef KTRACE if (KTRPOINT(p, KTR_SYSCALL)) - ktrsyscall(p->p_tracep, code, callp->sy_argsize, args + hidden); + ktrsyscall(p, code, callp->sy_argsize, args + hidden); #endif #ifdef SYSCALL_DEBUG scdebug_call(p, code, args + hidden); @@ -722,7 +722,7 @@ syscall(code, framep) userret(p, framep->tf_regs[FRAME_PC], sticks); #ifdef KTRACE if (KTRPOINT(p, KTR_SYSRET)) - ktrsysret(p->p_tracep, code, error, rval[0]); + ktrsysret(p, code, error, rval[0]); #endif } @@ -742,7 +742,7 @@ child_return(arg) userret(p, p->p_md.md_tf->tf_regs[FRAME_PC], 0); #ifdef KTRACE if (KTRPOINT(p, KTR_SYSRET)) - ktrsysret(p->p_tracep, SYS_fork, 0, 0); + ktrsysret(p, SYS_fork, 0, 0); #endif } diff --git a/sys/arch/amiga/amiga/trap.c b/sys/arch/amiga/amiga/trap.c index 15d76710a46..dad86e56805 100644 --- a/sys/arch/amiga/amiga/trap.c +++ b/sys/arch/amiga/amiga/trap.c @@ -1,4 +1,4 @@ -/* $OpenBSD: trap.c,v 1.18 2000/05/27 21:34:36 art Exp $ */ +/* $OpenBSD: trap.c,v 1.19 2000/11/10 18:15:35 art Exp $ */ /* $NetBSD: trap.c,v 1.56 1997/07/16 00:01:47 is Exp $ */ /* @@ -916,7 +916,7 @@ syscall(code, frame) #endif #ifdef KTRACE if (KTRPOINT(p, KTR_SYSCALL)) - ktrsyscall(p->p_tracep, code, argsize, args); + ktrsyscall(p, code, argsize, args); #endif if (error) goto bad; @@ -965,7 +965,7 @@ syscall(code, frame) userret(p, frame.f_pc, sticks); #ifdef KTRACE if (KTRPOINT(p, KTR_SYSRET)) - ktrsysret(p->p_tracep, code, error, rval[0]); + ktrsysret(p, code, error, rval[0]); #endif } @@ -983,7 +983,7 @@ child_return(p, frame) userret(p, frame.f_pc, p->p_sticks); #ifdef KTRACE if (KTRPOINT(p, KTR_SYSRET)) - ktrsysret(p->p_tracep, SYS_fork, 0, 0); + ktrsysret(p, SYS_fork, 0, 0); #endif } diff --git a/sys/arch/arc/arc/trap.c b/sys/arch/arc/arc/trap.c index 297686ce355..e3373732457 100644 --- a/sys/arch/arc/arc/trap.c +++ b/sys/arch/arc/arc/trap.c @@ -1,4 +1,4 @@ -/* $OpenBSD: trap.c,v 1.24 2000/06/08 10:31:15 art Exp $ */ +/* $OpenBSD: trap.c,v 1.25 2000/11/10 18:15:36 art Exp $ */ /* * Copyright (c) 1988 University of Utah. @@ -520,7 +520,7 @@ trap(statusReg, causeReg, vadr, pc, f) #endif #ifdef KTRACE if (KTRPOINT(p, KTR_SYSCALL)) - ktrsyscall(p->p_tracep, code, + ktrsyscall(p, code, callp->sy_argsize, args.i); #endif @@ -555,7 +555,7 @@ trap(statusReg, causeReg, vadr, pc, f) #endif #ifdef KTRACE if (KTRPOINT(p, KTR_SYSCALL)) - ktrsyscall(p->p_tracep, code, + ktrsyscall(p, code, callp->sy_argsize, args.i); #endif @@ -587,7 +587,7 @@ trap(statusReg, causeReg, vadr, pc, f) #endif #ifdef KTRACE if (KTRPOINT(p, KTR_SYSCALL)) - ktrsyscall(p->p_tracep, code, + ktrsyscall(p, code, callp->sy_argsize, args.i); #endif @@ -600,7 +600,7 @@ trap(statusReg, causeReg, vadr, pc, f) #endif #ifdef KTRACE if (KTRPOINT(p, KTR_SYSCALL)) - ktrsyscall(p->p_tracep, code, callp->sy_argsize, args.i); + ktrsyscall(p, code, callp->sy_argsize, args.i); #endif rval[0] = 0; rval[1] = locr0[V1]; @@ -657,7 +657,7 @@ trap(statusReg, causeReg, vadr, pc, f) #endif #ifdef KTRACE if (KTRPOINT(p, KTR_SYSRET)) - ktrsysret(p->p_tracep, code, i, rval[0]); + ktrsysret(p, code, i, rval[0]); #endif goto out; } diff --git a/sys/arch/arm32/arm32/syscall.c b/sys/arch/arm32/arm32/syscall.c index cef77b05978..335dc62b297 100644 --- a/sys/arch/arm32/arm32/syscall.c +++ b/sys/arch/arm32/arm32/syscall.c @@ -499,7 +499,7 @@ syscall(frame, code) #endif #ifdef KTRACE if (KTRPOINT(p, KTR_SYSCALL)) - ktrsyscall(p->p_tracep, code, argsize, args); + ktrsyscall(p, code, argsize, args); #endif rval[0] = 0; rval[1] = frame->tf_r1; @@ -547,7 +547,7 @@ syscall(frame, code) #ifdef KTRACE if (KTRPOINT(p, KTR_SYSRET)) - ktrsysret(p->p_tracep, code, error, rval[0]); + ktrsysret(p, code, error, rval[0]); #endif validate_trapframe(frame, 4); @@ -566,7 +566,7 @@ child_return(p, frame) #ifdef KTRACE if (KTRPOINT(p, KTR_SYSRET)) - ktrsysret(p->p_tracep, SYS_fork, 0, 0); + ktrsysret(p, SYS_fork, 0, 0); #endif } diff --git a/sys/arch/atari/atari/trap.c b/sys/arch/atari/atari/trap.c index d650a031159..838d47922f9 100644 --- a/sys/arch/atari/atari/trap.c +++ b/sys/arch/atari/atari/trap.c @@ -793,7 +793,7 @@ syscall(code, frame) #endif #ifdef KTRACE if (KTRPOINT(p, KTR_SYSCALL)) - ktrsyscall(p->p_tracep, code, argsize, args); + ktrsyscall(p, code, argsize, args); #endif if (error) goto bad; @@ -839,7 +839,7 @@ syscall(code, frame) userret(p, frame.f_pc, sticks); #ifdef KTRACE if (KTRPOINT(p, KTR_SYSRET)) - ktrsysret(p->p_tracep, code, error, rval[0]); + ktrsysret(p, code, error, rval[0]); #endif } /* @@ -856,7 +856,7 @@ child_return(p, frame) userret(p, frame.f_pc, 0); #ifdef KTRACE if (KTRPOINT(p, KTR_SYSRET)) - ktrsysret(p->p_tracep, SYS_fork, 0, 0); + ktrsysret(p, SYS_fork, 0, 0); #endif } diff --git a/sys/arch/hp300/hp300/trap.c b/sys/arch/hp300/hp300/trap.c index 98c42ec5532..7cd925eddab 100644 --- a/sys/arch/hp300/hp300/trap.c +++ b/sys/arch/hp300/hp300/trap.c @@ -1,4 +1,4 @@ -/* $OpenBSD: trap.c,v 1.16 1999/09/18 21:41:41 downsj Exp $ */ +/* $OpenBSD: trap.c,v 1.17 2000/11/10 18:15:38 art Exp $ */ /* $NetBSD: trap.c,v 1.55 1997/07/08 16:56:36 kleink Exp $ */ /* @@ -1129,7 +1129,7 @@ syscall(code, frame) #endif #ifdef KTRACE if (KTRPOINT(p, KTR_SYSCALL)) - ktrsyscall(p->p_tracep, code, argsize, args); + ktrsyscall(p, code, argsize, args); #endif if (error) goto bad; @@ -1172,7 +1172,7 @@ syscall(code, frame) userret(p, &frame, sticks, (u_int)0, 0); #ifdef KTRACE if (KTRPOINT(p, KTR_SYSRET)) - ktrsysret(p->p_tracep, code, error, rval[0]); + ktrsysret(p, code, error, rval[0]); #endif } @@ -1189,6 +1189,6 @@ child_return(p, frame) userret(p, &frame, 0, (u_int)0, 0); #ifdef KTRACE if (KTRPOINT(p, KTR_SYSRET)) - ktrsysret(p->p_tracep, SYS_fork, 0, 0); + ktrsysret(p, SYS_fork, 0, 0); #endif } diff --git a/sys/arch/hppa/hppa/trap.c b/sys/arch/hppa/hppa/trap.c index 5ee10ff5c0a..e9918c356ae 100644 --- a/sys/arch/hppa/hppa/trap.c +++ b/sys/arch/hppa/hppa/trap.c @@ -1,4 +1,4 @@ -/* $OpenBSD: trap.c,v 1.22 2000/11/08 16:22:36 mickey Exp $ */ +/* $OpenBSD: trap.c,v 1.23 2000/11/10 18:15:38 art Exp $ */ /* * Copyright (c) 1998-2000 Michael Shalayeff @@ -454,7 +454,7 @@ child_return(p) userret(p, p->p_md.md_regs->tf_iioq_head, 0); #ifdef KTRACE if (KTRPOINT(p, KTR_SYSRET)) - ktrsysret(p->p_tracep, SYS_fork, 0, 0); + ktrsysret(p, SYS_fork, 0, 0); #endif } @@ -508,7 +508,7 @@ syscall(frame, args) #endif #ifdef KTRACE if (KTRPOINT(p, KTR_SYSCALL)) - ktrsyscall(p->p_tracep, code, argsize, args); + ktrsyscall(p, code, argsize, args); #endif rval[0] = 0; @@ -540,7 +540,7 @@ syscall(frame, args) userret(p, frame->tf_iioq_head, 0); #ifdef KTRACE if (KTRPOINT(p, KTR_SYSRET)) - ktrsysret(p->p_tracep, code, error, rval[0]); + ktrsysret(p, code, error, rval[0]); #endif } diff --git a/sys/arch/i386/i386/trap.c b/sys/arch/i386/i386/trap.c index 9609bef275f..df749a07675 100644 --- a/sys/arch/i386/i386/trap.c +++ b/sys/arch/i386/i386/trap.c @@ -1,4 +1,4 @@ -/* $OpenBSD: trap.c,v 1.33 2000/06/26 22:45:53 art Exp $ */ +/* $OpenBSD: trap.c,v 1.34 2000/11/10 18:15:38 art Exp $ */ /* $NetBSD: trap.c,v 1.95 1996/05/05 06:50:02 mycroft Exp $ */ #undef DEBUG @@ -721,7 +721,7 @@ syscall(frame) #endif #ifdef KTRACE if (KTRPOINT(p, KTR_SYSCALL)) - ktrsyscall(p->p_tracep, code, argsize, args); + ktrsyscall(p, code, argsize, args); #endif if (error) goto bad; @@ -765,7 +765,7 @@ syscall(frame) userret(p, frame.tf_eip, sticks); #ifdef KTRACE if (KTRPOINT(p, KTR_SYSRET)) - ktrsysret(p->p_tracep, code, error, rval[0]); + ktrsysret(p, code, error, rval[0]); #endif } @@ -781,6 +781,6 @@ child_return(p, frame) userret(p, frame.tf_eip, 0); #ifdef KTRACE if (KTRPOINT(p, KTR_SYSRET)) - ktrsysret(p->p_tracep, SYS_fork, 0, 0); + ktrsysret(p, SYS_fork, 0, 0); #endif } diff --git a/sys/arch/kbus/kbus/trap.c b/sys/arch/kbus/kbus/trap.c index fbd8414e6a3..d61227108e1 100644 --- a/sys/arch/kbus/kbus/trap.c +++ b/sys/arch/kbus/kbus/trap.c @@ -930,7 +930,7 @@ syscall(code, tf, pc) if (error) { #ifdef KTRACE if (KTRPOINT(p, KTR_SYSCALL)) - ktrsyscall(p->p_tracep, code, + ktrsyscall(p, code, callp->sy_argsize, args.i); #endif goto bad; @@ -941,7 +941,7 @@ syscall(code, tf, pc) } #ifdef KTRACE if (KTRPOINT(p, KTR_SYSCALL)) - ktrsyscall(p->p_tracep, code, callp->sy_argsize, args.i); + ktrsyscall(p, code, callp->sy_argsize, args.i); #endif rval[0] = 0; rval[1] = tf->tf_out[1]; @@ -980,7 +980,7 @@ bad: userret(p, pc, sticks); #ifdef KTRACE if (KTRPOINT(p, KTR_SYSRET)) - ktrsysret(p->p_tracep, code, error, rval[0]); + ktrsysret(p, code, error, rval[0]); #endif share_fpu(p, tf); } @@ -999,7 +999,7 @@ child_return(p) userret(p, p->p_md.md_tf->tf_pc, 0); #ifdef KTRACE if (KTRPOINT(p, KTR_SYSRET)) - ktrsysret(p->p_tracep, + ktrsysret(p, (p->p_flag & P_PPWAIT) ? SYS_vfork : SYS_fork, 0, 0); #endif } diff --git a/sys/arch/mac68k/mac68k/trap.c b/sys/arch/mac68k/mac68k/trap.c index 42dcafbb8b7..6ce1934a8df 100644 --- a/sys/arch/mac68k/mac68k/trap.c +++ b/sys/arch/mac68k/mac68k/trap.c @@ -1,4 +1,4 @@ -/* $OpenBSD: trap.c,v 1.17 2000/06/08 10:23:49 art Exp $ */ +/* $OpenBSD: trap.c,v 1.18 2000/11/10 18:15:39 art Exp $ */ /* $NetBSD: trap.c,v 1.46 1997/04/07 22:54:44 scottr Exp $ */ /* @@ -1051,7 +1051,7 @@ syscall(code, frame) #endif #ifdef KTRACE if (KTRPOINT(p, KTR_SYSCALL)) - ktrsyscall(p->p_tracep, code, argsize, args); + ktrsyscall(p, code, argsize, args); #endif if (error) goto bad; @@ -1094,7 +1094,7 @@ syscall(code, frame) userret(p, &frame, sticks, (u_int)0, 0); #ifdef KTRACE if (KTRPOINT(p, KTR_SYSRET)) - ktrsysret(p->p_tracep, code, error, rval[0]); + ktrsysret(p, code, error, rval[0]); #endif } @@ -1116,6 +1116,6 @@ child_return(p, frame) userret(p, &frame, 0, (u_int)0, 0); #ifdef KTRACE if (KTRPOINT(p, KTR_SYSRET)) - ktrsysret(p->p_tracep, SYS_fork, 0, 0); + ktrsysret(p, SYS_fork, 0, 0); #endif } diff --git a/sys/arch/mvme68k/mvme68k/trap.c b/sys/arch/mvme68k/mvme68k/trap.c index 6e1dab5ab11..fb33ef7c7a6 100644 --- a/sys/arch/mvme68k/mvme68k/trap.c +++ b/sys/arch/mvme68k/mvme68k/trap.c @@ -1,4 +1,4 @@ -/* $OpenBSD: trap.c,v 1.24 2000/06/07 15:49:40 art Exp $ */ +/* $OpenBSD: trap.c,v 1.25 2000/11/10 18:15:39 art Exp $ */ /* * Copyright (c) 1995 Theo de Raadt @@ -1063,7 +1063,7 @@ struct frame frame; #endif #ifdef KTRACE if (KTRPOINT(p, KTR_SYSCALL)) - ktrsyscall(p->p_tracep, code, argsize, args); + ktrsyscall(p, code, argsize, args); #endif if (error) goto bad; @@ -1106,7 +1106,7 @@ struct frame frame; userret(p, &frame, sticks, (u_int)0, 0); #ifdef KTRACE if (KTRPOINT(p, KTR_SYSRET)) - ktrsysret(p->p_tracep, code, error, rval[0]); + ktrsysret(p, code, error, rval[0]); #endif } @@ -1123,7 +1123,7 @@ struct frame frame; userret(p, &frame, 0, (u_int)0, 0); #ifdef KTRACE if (KTRPOINT(p, KTR_SYSRET)) - ktrsysret(p->p_tracep, SYS_fork, 0, 0); + ktrsysret(p, SYS_fork, 0, 0); #endif } diff --git a/sys/arch/mvme88k/mvme88k/trap.c b/sys/arch/mvme88k/mvme88k/trap.c index 8787dbe4efe..439e67200e0 100644 --- a/sys/arch/mvme88k/mvme88k/trap.c +++ b/sys/arch/mvme88k/mvme88k/trap.c @@ -1,4 +1,4 @@ -/* $OpenBSD: trap.c,v 1.9 2000/06/08 22:25:21 niklas Exp $ */ +/* $OpenBSD: trap.c,v 1.10 2000/11/10 18:15:40 art Exp $ */ /* * Copyright (c) 1998 Steve Murphree, Jr. * Copyright (c) 1996 Nivas Madhur @@ -1302,7 +1302,7 @@ syscall(register_t code, struct m88100_saved_state *tf) #endif #ifdef KTRACE if (KTRPOINT(p, KTR_SYSCALL)) - ktrsyscall(p->p_tracep, code, callp->sy_argsize, args.i); + ktrsyscall(p, code, callp->sy_argsize, args.i); #endif rval[0] = 0; rval[1] = 0; @@ -1378,7 +1378,7 @@ syscall(register_t code, struct m88100_saved_state *tf) userret(p, tf, sticks); #ifdef KTRACE if (KTRPOINT(p, KTR_SYSRET)) - ktrsysret(p->p_tracep, code, error, rval[0]); + ktrsysret(p, code, error, rval[0]); #endif } @@ -1458,7 +1458,7 @@ m197_syscall(register_t code, struct m88100_saved_state *tf) #endif #ifdef KTRACE if (KTRPOINT(p, KTR_SYSCALL)) - ktrsyscall(p->p_tracep, code, callp->sy_argsize, args.i); + ktrsyscall(p, code, callp->sy_argsize, args.i); #endif rval[0] = 0; rval[1] = 0; @@ -1530,7 +1530,7 @@ m197_syscall(register_t code, struct m88100_saved_state *tf) userret(p, tf, sticks); #ifdef KTRACE if (KTRPOINT(p, KTR_SYSRET)) - ktrsysret(p->p_tracep, code, error, rval[0]); + ktrsysret(p, code, error, rval[0]); #endif } @@ -1558,7 +1558,7 @@ child_return(struct proc *p) userret(p, tf, p->p_sticks); #ifdef KTRACE if (KTRPOINT(p, KTR_SYSRET)) - ktrsysret(p->p_tracep, SYS_fork, 0, 0); + ktrsysret(p, SYS_fork, 0, 0); #endif } diff --git a/sys/arch/pc532/pc532/trap.c b/sys/arch/pc532/pc532/trap.c index 161e43aa95a..88273d20b43 100644 --- a/sys/arch/pc532/pc532/trap.c +++ b/sys/arch/pc532/pc532/trap.c @@ -429,7 +429,7 @@ syscall(frame) #endif #ifdef KTRACE if (KTRPOINT(p, KTR_SYSCALL)) - ktrsyscall(p->p_tracep, code, i, &args); + ktrsyscall(p, code, i, &args); #endif goto done; } @@ -438,7 +438,7 @@ syscall(frame) #endif #ifdef KTRACE if (KTRPOINT(p, KTR_SYSCALL)) - ktrsyscall(p->p_tracep, code, i, &args); + ktrsyscall(p, code, i, &args); #endif rval[0] = 0; rval[1] = 0; @@ -507,7 +507,7 @@ done: #endif #ifdef KTRACE if (KTRPOINT(p, KTR_SYSRET)) - ktrsysret(p->p_tracep, code, error, rval[0]); + ktrsysret(p, code, error, rval[0]); #endif } diff --git a/sys/arch/pmax/pmax/trap.c b/sys/arch/pmax/pmax/trap.c index e9512bb6293..f28c2f16ec2 100644 --- a/sys/arch/pmax/pmax/trap.c +++ b/sys/arch/pmax/pmax/trap.c @@ -1,4 +1,4 @@ -/* $OpenBSD: trap.c,v 1.21 2000/06/08 09:46:27 art Exp $ */ +/* $OpenBSD: trap.c,v 1.22 2000/11/10 18:15:41 art Exp $ */ /* $NetBSD: trap.c,v 1.50 1996/10/13 21:37:49 jonathan Exp $ */ /* @@ -658,7 +658,7 @@ trap(statusReg, causeReg, vadr, pc, args) #endif #ifdef KTRACE if (KTRPOINT(p, KTR_SYSCALL)) - ktrsyscall(p->p_tracep, code, + ktrsyscall(p, code, callp->sy_argsize, args.i); #endif @@ -693,7 +693,7 @@ trap(statusReg, causeReg, vadr, pc, args) #endif #ifdef KTRACE if (KTRPOINT(p, KTR_SYSCALL)) - ktrsyscall(p->p_tracep, code, + ktrsyscall(p, code, callp->sy_argsize, args.i); #endif @@ -725,7 +725,7 @@ trap(statusReg, causeReg, vadr, pc, args) #endif #ifdef KTRACE if (KTRPOINT(p, KTR_SYSCALL)) - ktrsyscall(p->p_tracep, code, + ktrsyscall(p, code, callp->sy_argsize, args.i); #endif @@ -738,7 +738,7 @@ trap(statusReg, causeReg, vadr, pc, args) #endif #ifdef KTRACE if (KTRPOINT(p, KTR_SYSCALL)) - ktrsyscall(p->p_tracep, code, callp->sy_argsize, args.i); + ktrsyscall(p, code, callp->sy_argsize, args.i); #endif rval[0] = 0; rval[1] = locr0[V1]; @@ -801,7 +801,7 @@ trap(statusReg, causeReg, vadr, pc, args) #endif #ifdef KTRACE if (KTRPOINT(p, KTR_SYSRET)) - ktrsysret(p->p_tracep, code, i, rval[0]); /*XXX*/ + ktrsysret(p, code, i, rval[0]); /*XXX*/ #endif goto out; } diff --git a/sys/arch/powerpc/powerpc/trap.c b/sys/arch/powerpc/powerpc/trap.c index 998ecd50c1c..94530e7b397 100644 --- a/sys/arch/powerpc/powerpc/trap.c +++ b/sys/arch/powerpc/powerpc/trap.c @@ -1,4 +1,4 @@ -/* $OpenBSD: trap.c,v 1.20 2000/09/06 22:48:13 rahnds Exp $ */ +/* $OpenBSD: trap.c,v 1.21 2000/11/10 18:15:42 art Exp $ */ /* $NetBSD: trap.c,v 1.3 1996/10/13 03:31:37 christos Exp $ */ /* @@ -271,7 +271,7 @@ printf("isi iar %x\n", frame->srr0); #ifdef KTRACE /* Can't get all the arguments! */ if (KTRPOINT(p, KTR_SYSCALL)) - ktrsyscall(p->p_tracep, code, + ktrsyscall(p, code, argsize, args); #endif goto syscall_bad; @@ -280,7 +280,7 @@ printf("isi iar %x\n", frame->srr0); } #ifdef KTRACE if (KTRPOINT(p, KTR_SYSCALL)) - ktrsyscall(p->p_tracep, code, argsize, params); + ktrsyscall(p, code, argsize, params); #endif rval[0] = 0; rval[1] = frame->fixreg[FIRSTARG + 1]; @@ -320,7 +320,7 @@ syscall_bad: #endif #ifdef KTRACE if (KTRPOINT(p, KTR_SYSRET)) - ktrsysret(p->p_tracep, code, error, rval[0]); + ktrsysret(p, code, error, rval[0]); #endif } break; @@ -484,7 +484,7 @@ child_return(p) tf->srr1 &= ~PSL_FP; /* Disable FPU, as we can't be fpuproc */ #ifdef KTRACE if (KTRPOINT(p, KTR_SYSRET)) - ktrsysret(p->p_tracep, SYS_fork, 0, 0); + ktrsysret(p, SYS_fork, 0, 0); #endif /* Profiling? XXX */ curpriority = p->p_priority; diff --git a/sys/arch/sparc/sparc/trap.c b/sys/arch/sparc/sparc/trap.c index f9105049e4c..c1ed8e3dff0 100644 --- a/sys/arch/sparc/sparc/trap.c +++ b/sys/arch/sparc/sparc/trap.c @@ -1,4 +1,4 @@ -/* $OpenBSD: trap.c,v 1.25 2000/07/04 10:52:28 art Exp $ */ +/* $OpenBSD: trap.c,v 1.26 2000/11/10 18:15:42 art Exp $ */ /* $NetBSD: trap.c,v 1.58 1997/09/12 08:55:01 pk Exp $ */ /* @@ -1130,7 +1130,7 @@ syscall(code, tf, pc) if (error) { #ifdef KTRACE if (KTRPOINT(p, KTR_SYSCALL)) - ktrsyscall(p->p_tracep, code, + ktrsyscall(p, code, callp->sy_argsize, args.i); #endif goto bad; @@ -1141,7 +1141,7 @@ syscall(code, tf, pc) } #ifdef KTRACE if (KTRPOINT(p, KTR_SYSCALL)) - ktrsyscall(p->p_tracep, code, callp->sy_argsize, args.i); + ktrsyscall(p, code, callp->sy_argsize, args.i); #endif rval[0] = 0; rval[1] = tf->tf_out[1]; @@ -1188,7 +1188,7 @@ syscall(code, tf, pc) userret(p, pc, sticks); #ifdef KTRACE if (KTRPOINT(p, KTR_SYSRET)) - ktrsysret(p->p_tracep, code, error, rval[0]); + ktrsysret(p, code, error, rval[0]); #endif share_fpu(p, tf); } @@ -1207,7 +1207,7 @@ child_return(p) userret(p, p->p_md.md_tf->tf_pc, 0); #ifdef KTRACE if (KTRPOINT(p, KTR_SYSRET)) - ktrsysret(p->p_tracep, + ktrsysret(p, (p->p_flag & P_PPWAIT) ? SYS_vfork : SYS_fork, 0, 0); #endif } diff --git a/sys/arch/sun3/sun3/trap.c b/sys/arch/sun3/sun3/trap.c index e9f127df00b..27aec29f066 100644 --- a/sys/arch/sun3/sun3/trap.c +++ b/sys/arch/sun3/sun3/trap.c @@ -1,4 +1,4 @@ -/* $OpenBSD: trap.c,v 1.21 2000/06/08 09:40:03 art Exp $ */ +/* $OpenBSD: trap.c,v 1.22 2000/11/10 18:15:43 art Exp $ */ /* $NetBSD: trap.c,v 1.63-1.65ish 1997/01/16 15:41:40 gwr Exp $ */ /* @@ -706,7 +706,7 @@ syscall(code, frame) #endif #ifdef KTRACE if (KTRPOINT(p, KTR_SYSCALL)) - ktrsyscall(p->p_tracep, code, argsize, args); + ktrsyscall(p, code, argsize, args); #endif if (error) goto bad; @@ -752,7 +752,7 @@ syscall(code, frame) userret(p, &frame, sticks); #ifdef KTRACE if (KTRPOINT(p, KTR_SYSRET)) - ktrsysret(p->p_tracep, code, error, rval[0]); + ktrsysret(p, code, error, rval[0]); #endif } @@ -778,7 +778,7 @@ child_return(p) userret((struct proc *)p, f, 0); #ifdef KTRACE if (KTRPOINT((struct proc *)p, KTR_SYSRET)) - ktrsysret(((struct proc *)p)->p_tracep, SYS_fork, 0, 0); + ktrsysret(((struct proc *)p), SYS_fork, 0, 0); #endif } diff --git a/sys/arch/vax/vax/trap.c b/sys/arch/vax/vax/trap.c index 22e0648a8e6..db589030997 100644 --- a/sys/arch/vax/vax/trap.c +++ b/sys/arch/vax/vax/trap.c @@ -1,4 +1,4 @@ -/* $OpenBSD: trap.c,v 1.12 2000/04/27 01:10:14 bjc Exp $ */ +/* $OpenBSD: trap.c,v 1.13 2000/11/10 18:15:43 art Exp $ */ /* $NetBSD: trap.c,v 1.47 1999/08/21 19:26:20 matt Exp $ */ /* * Copyright (c) 1994 Ludd, University of Lule}, Sweden. @@ -369,7 +369,7 @@ if(startsysc)printf("trap syscall %s pc %lx, psl %lx, sp %lx, pid %d, frame %p\n if (err) { #ifdef KTRACE if (KTRPOINT(p, KTR_SYSCALL)) - ktrsyscall(p->p_tracep, frame->code, + ktrsyscall(p, frame->code, callp->sy_argsize, args); #endif goto bad; @@ -399,7 +399,7 @@ if(startsysc)printf("trap syscall %s pc %lx, psl %lx, sp %lx, pid %d, frame %p\n #ifdef KTRACE if (KTRPOINT(p, KTR_SYSCALL)) - ktrsyscall(p->p_tracep, frame->code, callp->sy_argsize, args); + ktrsyscall(p, frame->code, callp->sy_argsize, args); #endif err = (*callp->sy_call)(curproc, args, rval); exptr = curproc->p_addr->u_pcb.framep; @@ -456,6 +456,6 @@ bad: } #ifdef KTRACE if (KTRPOINT(p, KTR_SYSRET)) - ktrsysret(p->p_tracep, frame->code, err, rval[0]); + ktrsysret(p, frame->code, err, rval[0]); #endif } diff --git a/sys/arch/wgrisc/wgrisc/trap.c b/sys/arch/wgrisc/wgrisc/trap.c index 7b04ac9aa3f..c227c68e641 100644 --- a/sys/arch/wgrisc/wgrisc/trap.c +++ b/sys/arch/wgrisc/wgrisc/trap.c @@ -1,4 +1,4 @@ -/* $OpenBSD: trap.c,v 1.4 1999/05/24 23:09:10 jason Exp $ */ +/* $OpenBSD: trap.c,v 1.5 2000/11/10 18:15:44 art Exp $ */ /* * Copyright (c) 1988 University of Utah. * Copyright (c) 1992, 1993 @@ -39,7 +39,7 @@ * from: Utah Hdr: trap.c 1.32 91/04/06 * * from: @(#)trap.c 8.5 (Berkeley) 1/11/94 - * $Id: trap.c,v 1.4 1999/05/24 23:09:10 jason Exp $ + * $Id: trap.c,v 1.5 2000/11/10 18:15:44 art Exp $ */ #include <sys/param.h> @@ -594,7 +594,7 @@ trap(statusReg, causeReg, vadr, pc, args) #endif #ifdef KTRACE if (KTRPOINT(p, KTR_SYSCALL)) - ktrsyscall(p->p_tracep, code, + ktrsyscall(p, code, callp->sy_argsize, args.i); #endif @@ -629,7 +629,7 @@ trap(statusReg, causeReg, vadr, pc, args) #endif #ifdef KTRACE if (KTRPOINT(p, KTR_SYSCALL)) - ktrsyscall(p->p_tracep, code, + ktrsyscall(p, code, callp->sy_argsize, args.i); #endif @@ -661,7 +661,7 @@ trap(statusReg, causeReg, vadr, pc, args) #endif #ifdef KTRACE if (KTRPOINT(p, KTR_SYSCALL)) - ktrsyscall(p->p_tracep, code, + ktrsyscall(p, code, callp->sy_argsize, args.i); #endif @@ -674,7 +674,7 @@ trap(statusReg, causeReg, vadr, pc, args) #endif #ifdef KTRACE if (KTRPOINT(p, KTR_SYSCALL)) - ktrsyscall(p->p_tracep, code, callp->sy_argsize, args.i); + ktrsyscall(p, code, callp->sy_argsize, args.i); #endif rval[0] = 0; rval[1] = locr0[V1]; @@ -735,7 +735,7 @@ trap(statusReg, causeReg, vadr, pc, args) #endif #ifdef KTRACE if (KTRPOINT(p, KTR_SYSRET)) - ktrsysret(p->p_tracep, code, i, rval[0]); + ktrsysret(p, code, i, rval[0]); #endif goto out; } diff --git a/sys/compat/hpux/hpux_net.c b/sys/compat/hpux/hpux_net.c index 574f459fec3..6703a495ac6 100644 --- a/sys/compat/hpux/hpux_net.c +++ b/sys/compat/hpux/hpux_net.c @@ -1,4 +1,4 @@ -/* $OpenBSD: hpux_net.c,v 1.3 1997/04/16 09:18:07 downsj Exp $ */ +/* $OpenBSD: hpux_net.c,v 1.4 2000/11/10 18:15:44 art Exp $ */ /* $NetBSD: hpux_net.c,v 1.14 1997/04/01 19:59:02 scottr Exp $ */ /* @@ -161,7 +161,7 @@ hpux_sys_netioctl(p, v, retval) (error = copyin((caddr_t)args, (caddr_t)uap, (u_int)i))) { #ifdef KTRACE if (KTRPOINT(p, KTR_SYSCALL)) - ktrsyscall(p->p_tracep, code + MINBSDIPCCODE, + ktrsyscall(p, code + MINBSDIPCCODE, hpuxtobsdipc[code].nargs, (register_t *)uap); #endif @@ -169,7 +169,7 @@ hpux_sys_netioctl(p, v, retval) } #ifdef KTRACE if (KTRPOINT(p, KTR_SYSCALL)) - ktrsyscall(p->p_tracep, code + MINBSDIPCCODE, + ktrsyscall(p, code + MINBSDIPCCODE, hpuxtobsdipc[code].nargs, (register_t *)uap); #endif diff --git a/sys/compat/netbsd/netbsd_pos_io.c b/sys/compat/netbsd/netbsd_pos_io.c index 55bea8188ff..28ed9a38814 100644 --- a/sys/compat/netbsd/netbsd_pos_io.c +++ b/sys/compat/netbsd/netbsd_pos_io.c @@ -1,4 +1,4 @@ -/* $OpenBSD: netbsd_pos_io.c,v 1.5 2000/04/19 08:34:57 csapuntz Exp $ */ +/* $OpenBSD: netbsd_pos_io.c,v 1.6 2000/11/10 18:15:45 art Exp $ */ /* $NetBSD: vfs_syscalls.c,v 1.71 1996/04/23 10:29:02 mycroft Exp $ */ @@ -151,7 +151,7 @@ netbsd_sys_pread(p, v, retval) cnt -= auio.uio_resid; #ifdef KTRACE if (KTRPOINT(p, KTR_GENIO) && error == 0) - ktrgenio(p->p_tracep, SCARG(uap, fd), UIO_READ, &ktriov, + ktrgenio(p, SCARG(uap, fd), UIO_READ, &ktriov, cnt, error); #endif *retval = cnt; @@ -243,7 +243,7 @@ netbsd_sys_preadv(p, v, retval) #ifdef KTRACE if (ktriov != NULL) { if (error == 0) - ktrgenio(p->p_tracep, SCARG(uap, fd), UIO_READ, ktriov, + ktrgenio(p, SCARG(uap, fd), UIO_READ, ktriov, cnt, error); FREE(ktriov, M_TEMP); } @@ -320,7 +320,7 @@ netbsd_sys_pwrite(p, v, retval) cnt -= auio.uio_resid; #ifdef KTRACE if (KTRPOINT(p, KTR_GENIO) && error == 0) - ktrgenio(p->p_tracep, SCARG(uap, fd), UIO_WRITE, + ktrgenio(p, SCARG(uap, fd), UIO_WRITE, &ktriov, cnt, error); #endif *retval = cnt; @@ -420,7 +420,7 @@ netbsd_sys_pwritev(p, v, retval) #ifdef KTRACE if (ktriov != NULL) { if (error == 0) - ktrgenio(p->p_tracep, SCARG(uap, fd), UIO_WRITE, + ktrgenio(p, SCARG(uap, fd), UIO_WRITE, ktriov, cnt, error); FREE(ktriov, M_TEMP); } diff --git a/sys/compat/svr4/svr4_misc.c b/sys/compat/svr4/svr4_misc.c index b4ecc81c64f..d10fa9219ae 100644 --- a/sys/compat/svr4/svr4_misc.c +++ b/sys/compat/svr4/svr4_misc.c @@ -1,4 +1,4 @@ -/* $OpenBSD: svr4_misc.c,v 1.27 2000/06/28 23:48:15 fgsch Exp $ */ +/* $OpenBSD: svr4_misc.c,v 1.28 2000/11/10 18:15:46 art Exp $ */ /* $NetBSD: svr4_misc.c,v 1.42 1996/12/06 03:22:34 christos Exp $ */ /* @@ -1611,7 +1611,7 @@ svr4_sys_setegid(p, v, retval) p->p_os = OOS_LINUX; #ifdef KTRACE if (KTRPOINT(p, KTR_EMUL)) - ktremul(p->p_tracep, p->p_emul->e_name); + ktremul(p, p->p_emul->e_name); #endif return (0); } diff --git a/sys/kern/kern_exec.c b/sys/kern/kern_exec.c index 47d7e22691e..162313d55e4 100644 --- a/sys/kern/kern_exec.c +++ b/sys/kern/kern_exec.c @@ -1,4 +1,4 @@ -/* $OpenBSD: kern_exec.c,v 1.44 2000/09/28 13:41:39 art Exp $ */ +/* $OpenBSD: kern_exec.c,v 1.45 2000/11/10 18:15:46 art Exp $ */ /* $NetBSD: kern_exec.c,v 1.75 1996/02/09 18:59:28 christos Exp $ */ /*- @@ -618,7 +618,7 @@ sys_execve(p, v, retval) #ifdef KTRACE if (KTRPOINT(p, KTR_EMUL)) - ktremul(p->p_tracep, p->p_emul->e_name); + ktremul(p, p->p_emul->e_name); #endif return (0); diff --git a/sys/kern/kern_ktrace.c b/sys/kern/kern_ktrace.c index 1226550a488..85becf736ac 100644 --- a/sys/kern/kern_ktrace.c +++ b/sys/kern/kern_ktrace.c @@ -1,4 +1,4 @@ -/* $OpenBSD: kern_ktrace.c,v 1.21 2000/09/27 16:13:46 mickey Exp $ */ +/* $OpenBSD: kern_ktrace.c,v 1.22 2000/11/10 18:15:46 art Exp $ */ /* $NetBSD: kern_ktrace.c,v 1.23 1996/02/09 18:59:36 christos Exp $ */ /* @@ -57,7 +57,7 @@ void ktrinitheader __P((struct ktr_header *, struct proc *, int)); int ktrops __P((struct proc *, struct proc *, int, int, struct vnode *)); int ktrsetchildren __P((struct proc *, struct proc *, int, int, struct vnode *)); -int ktrwrite __P((struct vnode *, struct ktr_header *)); +int ktrwrite __P((struct proc *, struct ktr_header *)); int ktrcanset __P((struct proc *, struct proc *)); /* @@ -97,8 +97,8 @@ ktrinitheader(kth, p, type) } void -ktrsyscall(vp, code, argsize, args) - struct vnode *vp; +ktrsyscall(p, code, argsize, args) + struct proc *p; register_t code; size_t argsize; register_t args[]; @@ -106,7 +106,6 @@ ktrsyscall(vp, code, argsize, args) struct ktr_header kth; struct ktr_syscall *ktp; unsigned int len = sizeof(struct ktr_syscall) + argsize; - struct proc *p = curproc; /* XXX */ register_t *argp; int i; @@ -120,21 +119,20 @@ ktrsyscall(vp, code, argsize, args) *argp++ = args[i]; kth.ktr_buf = (caddr_t)ktp; kth.ktr_len = len; - ktrwrite(vp, &kth); + ktrwrite(p, &kth); free(ktp, M_TEMP); p->p_traceflag &= ~KTRFAC_ACTIVE; } void -ktrsysret(vp, code, error, retval) - struct vnode *vp; +ktrsysret(p, code, error, retval) + struct proc *p; register_t code; int error; register_t retval; { struct ktr_header kth; struct ktr_sysret ktp; - struct proc *p = curproc; /* XXX */ p->p_traceflag |= KTRFAC_ACTIVE; ktrinitheader(&kth, p, KTR_SYSRET); @@ -145,47 +143,45 @@ ktrsysret(vp, code, error, retval) kth.ktr_buf = (caddr_t)&ktp; kth.ktr_len = sizeof(struct ktr_sysret); - ktrwrite(vp, &kth); + ktrwrite(p, &kth); p->p_traceflag &= ~KTRFAC_ACTIVE; } void -ktrnamei(vp, path) - struct vnode *vp; +ktrnamei(p, path) + struct proc *p; char *path; { struct ktr_header kth; - struct proc *p = curproc; /* XXX */ p->p_traceflag |= KTRFAC_ACTIVE; ktrinitheader(&kth, p, KTR_NAMEI); kth.ktr_len = strlen(path); kth.ktr_buf = path; - ktrwrite(vp, &kth); + ktrwrite(p, &kth); p->p_traceflag &= ~KTRFAC_ACTIVE; } void -ktremul(vp, emul) - struct vnode *vp; +ktremul(p, emul) + struct proc *p; char *emul; { struct ktr_header kth; - struct proc *p = curproc; /* XXX */ p->p_traceflag |= KTRFAC_ACTIVE; ktrinitheader(&kth, p, KTR_EMUL); kth.ktr_len = strlen(emul); kth.ktr_buf = emul; - ktrwrite(vp, &kth); + ktrwrite(p, &kth); p->p_traceflag &= ~KTRFAC_ACTIVE; } void -ktrgenio(vp, fd, rw, iov, len, error) - struct vnode *vp; +ktrgenio(p, fd, rw, iov, len, error) + struct proc *p; int fd; enum uio_rw rw; struct iovec *iov; @@ -195,7 +191,6 @@ ktrgenio(vp, fd, rw, iov, len, error) struct ktr_genio *ktp; caddr_t cp; int resid = len, count; - struct proc *p = curproc; /* XXX */ int buflen; if (error) @@ -231,7 +226,7 @@ ktrgenio(vp, fd, rw, iov, len, error) kth.ktr_len = count + sizeof(struct ktr_genio); - if (ktrwrite(vp, &kth) != 0) + if (ktrwrite(p, &kth) != 0) break; iov->iov_len -= count; @@ -249,15 +244,14 @@ ktrgenio(vp, fd, rw, iov, len, error) } void -ktrpsig(vp, sig, action, mask, code) - struct vnode *vp; +ktrpsig(p, sig, action, mask, code) + struct proc *p; int sig; sig_t action; int mask, code; { struct ktr_header kth; struct ktr_psig kp; - struct proc *p = curproc; /* XXX */ p->p_traceflag |= KTRFAC_ACTIVE; ktrinitheader(&kth, p, KTR_PSIG); @@ -268,18 +262,17 @@ ktrpsig(vp, sig, action, mask, code) kth.ktr_buf = (caddr_t)&kp; kth.ktr_len = sizeof (struct ktr_psig); - ktrwrite(vp, &kth); + ktrwrite(p, &kth); p->p_traceflag &= ~KTRFAC_ACTIVE; } void -ktrcsw(vp, out, user) - struct vnode *vp; +ktrcsw(p, out, user) + struct proc *p; int out, user; { struct ktr_header kth; struct ktr_csw kc; - struct proc *p = curproc; /* XXX */ p->p_traceflag |= KTRFAC_ACTIVE; ktrinitheader(&kth, p, KTR_CSW); @@ -288,7 +281,7 @@ ktrcsw(vp, out, user) kth.ktr_buf = (caddr_t)&kc; kth.ktr_len = sizeof (struct ktr_csw); - ktrwrite(vp, &kth); + ktrwrite(p, &kth); p->p_traceflag &= ~KTRFAC_ACTIVE; } @@ -431,7 +424,7 @@ ktrops(curp, p, ops, facs, vp) * change/attach request. */ if (KTRPOINT(p, KTR_EMUL)) - ktremul(p->p_tracep, p->p_emul->e_name); + ktremul(p, p->p_emul->e_name); return (1); } @@ -469,14 +462,14 @@ ktrsetchildren(curp, top, ops, facs, vp) } int -ktrwrite(vp, kth) - struct vnode *vp; +ktrwrite(p, kth) + struct proc *p; struct ktr_header *kth; { struct uio auio; struct iovec aiov[2]; - struct proc *p = curproc; /* XXX */ int error; + struct vnode *vp = p->p_tracep; if (vp == NULL) return 0; @@ -542,4 +535,4 @@ ktrcanset(callp, targetp) return (0); } -#endif +#endif
\ No newline at end of file diff --git a/sys/kern/kern_sig.c b/sys/kern/kern_sig.c index caadb6620fa..bb5c923f364 100644 --- a/sys/kern/kern_sig.c +++ b/sys/kern/kern_sig.c @@ -1,4 +1,4 @@ -/* $OpenBSD: kern_sig.c,v 1.38 2000/06/05 11:02:50 art Exp $ */ +/* $OpenBSD: kern_sig.c,v 1.39 2000/11/10 18:15:47 art Exp $ */ /* $NetBSD: kern_sig.c,v 1.54 1996/04/22 01:38:32 christos Exp $ */ /* @@ -641,7 +641,7 @@ trapsignal(p, signum, code, type, sigval) p->p_stats->p_ru.ru_nsignals++; #ifdef KTRACE if (KTRPOINT(p, KTR_PSIG)) - ktrpsig(p->p_tracep, signum, ps->ps_sigact[signum], + ktrpsig(p, signum, ps->ps_sigact[signum], p->p_sigmask, code); #endif (*p->p_emul->e_sendsig)(ps->ps_sigact[signum], signum, @@ -1062,8 +1062,7 @@ postsig(signum) action = ps->ps_sigact[signum]; #ifdef KTRACE if (KTRPOINT(p, KTR_PSIG)) - ktrpsig(p->p_tracep, - signum, action, ps->ps_flags & SAS_OLDMASK ? + ktrpsig(p, signum, action, ps->ps_flags & SAS_OLDMASK ? ps->ps_oldmask : p->p_sigmask, 0); #endif if (action == SIG_DFL) { diff --git a/sys/kern/kern_synch.c b/sys/kern/kern_synch.c index 8e9570618fc..b04530fefd3 100644 --- a/sys/kern/kern_synch.c +++ b/sys/kern/kern_synch.c @@ -1,4 +1,4 @@ -/* $OpenBSD: kern_synch.c,v 1.28 2000/08/03 14:36:36 mickey Exp $ */ +/* $OpenBSD: kern_synch.c,v 1.29 2000/11/10 18:15:47 art Exp $ */ /* $NetBSD: kern_synch.c,v 1.37 1996/04/22 01:38:37 christos Exp $ */ /*- @@ -357,7 +357,7 @@ tsleep(ident, priority, wmesg, timo) #ifdef KTRACE if (KTRPOINT(p, KTR_CSW)) - ktrcsw(p->p_tracep, 1, 0); + ktrcsw(p, 1, 0); #endif s = splhigh(); if (cold || panicstr) { @@ -426,7 +426,7 @@ resume: if (sig == 0) { #ifdef KTRACE if (KTRPOINT(p, KTR_CSW)) - ktrcsw(p->p_tracep, 0, 0); + ktrcsw(p, 0, 0); #endif return (EWOULDBLOCK); } @@ -435,7 +435,7 @@ resume: if (catch && (sig != 0 || (sig = CURSIG(p)) != 0)) { #ifdef KTRACE if (KTRPOINT(p, KTR_CSW)) - ktrcsw(p->p_tracep, 0, 0); + ktrcsw(p, 0, 0); #endif if (p->p_sigacts->ps_sigintr & sigmask(sig)) return (EINTR); @@ -443,7 +443,7 @@ resume: } #ifdef KTRACE if (KTRPOINT(p, KTR_CSW)) - ktrcsw(p->p_tracep, 0, 0); + ktrcsw(p, 0, 0); #endif return (0); } @@ -523,7 +523,7 @@ sleep(ident, priority) p->p_stats->p_ru.ru_nvcsw++; #ifdef KTRACE if (KTRPOINT(p, KTR_CSW)) - ktrcsw(p->p_tracep, 1, 0); + ktrcsw(p, 1, 0); #endif mi_switch(); #ifdef DDB @@ -532,7 +532,7 @@ sleep(ident, priority) #endif #ifdef KTRACE if (KTRPOINT(p, KTR_CSW)) - ktrcsw(p->p_tracep, 0, 0); + ktrcsw(p, 0, 0); #endif curpriority = p->p_usrpri; splx(s); diff --git a/sys/kern/sys_generic.c b/sys/kern/sys_generic.c index 593bd2e42b4..595071f1258 100644 --- a/sys/kern/sys_generic.c +++ b/sys/kern/sys_generic.c @@ -1,4 +1,4 @@ -/* $OpenBSD: sys_generic.c,v 1.27 2000/09/27 16:13:46 mickey Exp $ */ +/* $OpenBSD: sys_generic.c,v 1.28 2000/11/10 18:15:47 art Exp $ */ /* $NetBSD: sys_generic.c,v 1.24 1996/03/29 00:25:32 cgd Exp $ */ /* @@ -154,7 +154,7 @@ dofileread(p, fd, fp, buf, nbyte, offset, retval) cnt -= auio.uio_resid; #ifdef KTRACE if (KTRPOINT(p, KTR_GENIO) && error == 0) - ktrgenio(p->p_tracep, fd, UIO_READ, &ktriov, cnt, error); + ktrgenio(p, fd, UIO_READ, &ktriov, cnt, error); #endif *retval = cnt; out: @@ -275,7 +275,7 @@ dofilereadv(p, fd, fp, iovp, iovcnt, offset, retval) #ifdef KTRACE if (ktriov != NULL) { if (error == 0) - ktrgenio(p->p_tracep, fd, UIO_READ, ktriov, cnt, + ktrgenio(p, fd, UIO_READ, ktriov, cnt, error); free(ktriov, M_TEMP); } @@ -380,7 +380,7 @@ dofilewrite(p, fd, fp, buf, nbyte, offset, retval) cnt -= auio.uio_resid; #ifdef KTRACE if (KTRPOINT(p, KTR_GENIO) && error == 0) - ktrgenio(p->p_tracep, fd, UIO_WRITE, &ktriov, cnt, error); + ktrgenio(p, fd, UIO_WRITE, &ktriov, cnt, error); #endif *retval = cnt; out: @@ -502,7 +502,7 @@ dofilewritev(p, fd, fp, iovp, iovcnt, offset, retval) #ifdef KTRACE if (ktriov != NULL) { if (error == 0) - ktrgenio(p->p_tracep, fd, UIO_WRITE, ktriov, cnt, + ktrgenio(p, fd, UIO_WRITE, ktriov, cnt, error); free(ktriov, M_TEMP); } diff --git a/sys/kern/uipc_syscalls.c b/sys/kern/uipc_syscalls.c index 613f1e969d0..786b1ed0bb5 100644 --- a/sys/kern/uipc_syscalls.c +++ b/sys/kern/uipc_syscalls.c @@ -1,4 +1,4 @@ -/* $OpenBSD: uipc_syscalls.c,v 1.32 2000/10/12 09:58:05 itojun Exp $ */ +/* $OpenBSD: uipc_syscalls.c,v 1.33 2000/11/10 18:15:48 art Exp $ */ /* $NetBSD: uipc_syscalls.c,v 1.19 1996/02/09 19:00:48 christos Exp $ */ /* @@ -504,8 +504,7 @@ sendit(p, s, mp, flags, retsize) #ifdef KTRACE if (ktriov != NULL) { if (error == 0) - ktrgenio(p->p_tracep, s, UIO_WRITE, - ktriov, *retsize, error); + ktrgenio(p, s, UIO_WRITE, ktriov, *retsize, error); free(ktriov, M_TEMP); } #endif @@ -655,7 +654,7 @@ recvit(p, s, mp, namelenp, retsize) #ifdef KTRACE if (ktriov != NULL) { if (error == 0) - ktrgenio(p->p_tracep, s, UIO_READ, + ktrgenio(p, s, UIO_READ, ktriov, len - auio.uio_resid, error); free(ktriov, M_TEMP); } diff --git a/sys/kern/vfs_lookup.c b/sys/kern/vfs_lookup.c index 1acc9172103..a26cf001f81 100644 --- a/sys/kern/vfs_lookup.c +++ b/sys/kern/vfs_lookup.c @@ -1,4 +1,4 @@ -/* $OpenBSD: vfs_lookup.c,v 1.17 1999/04/16 14:04:41 deraadt Exp $ */ +/* $OpenBSD: vfs_lookup.c,v 1.18 2000/11/10 18:15:48 art Exp $ */ /* $NetBSD: vfs_lookup.c,v 1.17 1996/02/09 19:00:59 christos Exp $ */ /* @@ -116,7 +116,7 @@ namei(ndp) #ifdef KTRACE if (KTRPOINT(cnp->cn_proc, KTR_NAMEI)) - ktrnamei(cnp->cn_proc->p_tracep, cnp->cn_pnbuf); + ktrnamei(cnp->cn_proc, cnp->cn_pnbuf); #endif /* diff --git a/sys/sys/ktrace.h b/sys/sys/ktrace.h index 2fc4b4b368a..216a76c70c9 100644 --- a/sys/sys/ktrace.h +++ b/sys/sys/ktrace.h @@ -1,4 +1,4 @@ -/* $OpenBSD: ktrace.h,v 1.3 2000/04/20 10:03:41 art Exp $ */ +/* $OpenBSD: ktrace.h,v 1.4 2000/11/10 18:15:49 art Exp $ */ /* $NetBSD: ktrace.h,v 1.12 1996/02/04 02:12:29 christos Exp $ */ /* @@ -165,14 +165,14 @@ __END_DECLS #else -void ktrcsw __P((struct vnode *, int, int)); -void ktremul __P((struct vnode *, char *)); -void ktrgenio __P((struct vnode *, int, enum uio_rw, struct iovec *, int, int)); -void ktrnamei __P((struct vnode *, char *)); -void ktrpsig __P((struct vnode *, int, sig_t, int, int)); -void ktrsyscall __P((struct vnode *, register_t, size_t, register_t [])); -void ktrsysret __P((struct vnode *, register_t, int, register_t)); +void ktrcsw __P((struct proc *, int, int)); +void ktremul __P((struct proc *, char *)); +void ktrgenio __P((struct proc *, int, enum uio_rw, struct iovec *, int, int)); +void ktrnamei __P((struct proc *, char *)); +void ktrpsig __P((struct proc *, int, sig_t, int, int)); +void ktrsyscall __P((struct proc *, register_t, size_t, register_t [])); +void ktrsysret __P((struct proc *, register_t, int, register_t)); void ktrsettracevnode __P((struct proc *, struct vnode *)); -#endif /* !_KERNEL */ +#endif /* !_KERNEL */
\ No newline at end of file |