From 48fc6c37a0b86e8c6eb274d14b42b8feb7d1f8bd Mon Sep 17 00:00:00 2001 From: gwr Date: Tue, 26 Sep 1995 03:53:46 +0000 Subject: [PATCH] Correct child_return() so child is charged for its cpu time. --- sys/arch/sun3/sun3/trap.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/sys/arch/sun3/sun3/trap.c b/sys/arch/sun3/sun3/trap.c index 1c606caf879c..e811437502f4 100644 --- a/sys/arch/sun3/sun3/trap.c +++ b/sys/arch/sun3/sun3/trap.c @@ -1,4 +1,4 @@ -/* $NetBSD: trap.c,v 1.53 1995/08/08 21:11:47 gwr Exp $ */ +/* $NetBSD: trap.c,v 1.54 1995/09/26 03:53:46 gwr Exp $ */ /* * Copyright (c) 1994 Gordon W. Ross @@ -706,7 +706,11 @@ child_return(p) f->f_sr &= ~PSL_C; f->f_format = FMT0; - userret(p, f, p->p_sticks, (u_int)0, 0); + /* + * Old ticks (3rd arg) is zero so we will charge the child + * for any clock ticks that might happen before this point. + */ + userret(p, f, 0, (u_int)0, 0); #ifdef KTRACE if (KTRPOINT(p, KTR_SYSRET)) ktrsysret(p->p_tracep, SYS_fork, 0, 0);