Module Name:    src
Committed By:   snj
Date:           Fri Aug 14 21:25:34 UTC 2009

Modified Files:
        src/sys/arch/amd64/amd64 [netbsd-5]: trap.c

Log Message:
Pull up following revision(s) (requested by rmidn in ticket #897):
        sys/arch/amd64/amd64/trap.c: revision 1.58
T_ASTFLT|T_USER: check for LP_OWEUPC in l_lpflag, not l_flag.  Also, flag
unset was on p->p_flag.  Luckily, it did not corrupt the p_flag, because
we don't have LW_ flag matching LP_OWEUPC.


To generate a diff of this commit:
cvs rdiff -u -r1.52.4.1 -r1.52.4.2 src/sys/arch/amd64/amd64/trap.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/amd64/amd64/trap.c
diff -u src/sys/arch/amd64/amd64/trap.c:1.52.4.1 src/sys/arch/amd64/amd64/trap.c:1.52.4.2
--- src/sys/arch/amd64/amd64/trap.c:1.52.4.1	Tue Jul 21 00:40:13 2009
+++ src/sys/arch/amd64/amd64/trap.c	Fri Aug 14 21:25:34 2009
@@ -1,4 +1,4 @@
-/*	$NetBSD: trap.c,v 1.52.4.1 2009/07/21 00:40:13 snj Exp $	*/
+/*	$NetBSD: trap.c,v 1.52.4.2 2009/08/14 21:25:34 snj Exp $	*/
 
 /*-
  * Copyright (c) 1998, 2000 The NetBSD Foundation, Inc.
@@ -68,7 +68,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: trap.c,v 1.52.4.1 2009/07/21 00:40:13 snj Exp $");
+__KERNEL_RCSID(0, "$NetBSD: trap.c,v 1.52.4.2 2009/08/14 21:25:34 snj Exp $");
 
 #include "opt_ddb.h"
 #include "opt_kgdb.h"
@@ -387,10 +387,11 @@
 	case T_ARITHTRAP|T_USER:
 	case T_XMM|T_USER:
 		/* Already handled by fputrap(), fall through. */
-	case T_ASTFLT|T_USER:		/* Allow process switch */
+	case T_ASTFLT|T_USER:
+		/* Allow process switch. */
 		uvmexp.softs++;
-		if (l->l_flag & LP_OWEUPC) {
-			p->p_flag &= ~LP_OWEUPC;
+		if (l->l_pflag & LP_OWEUPC) {
+			l->l_pflag &= ~LP_OWEUPC;
 			ADDUPROF(l);
 		}
 		/* Allow a forced task switch. */

Reply via email to