Module Name:    src
Committed By:   maxv
Date:           Thu Aug 11 14:58:29 UTC 2016

Modified Files:
        src/sys/arch/amd64/amd64: trap.c
        src/sys/arch/i386/i386: trap.c

Log Message:
Reduce the diff, and typo.


To generate a diff of this commit:
cvs rdiff -u -r1.83 -r1.84 src/sys/arch/amd64/amd64/trap.c
cvs rdiff -u -r1.276 -r1.277 src/sys/arch/i386/i386/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.83 src/sys/arch/amd64/amd64/trap.c:1.84
--- src/sys/arch/amd64/amd64/trap.c:1.83	Sun Dec 13 15:53:05 2015
+++ src/sys/arch/amd64/amd64/trap.c	Thu Aug 11 14:58:29 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: trap.c,v 1.83 2015/12/13 15:53:05 maxv Exp $	*/
+/*	$NetBSD: trap.c,v 1.84 2016/08/11 14:58:29 maxv 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.83 2015/12/13 15:53:05 maxv Exp $");
+__KERNEL_RCSID(0, "$NetBSD: trap.c,v 1.84 2016/08/11 14:58:29 maxv Exp $");
 
 #include "opt_ddb.h"
 #include "opt_kgdb.h"
@@ -374,7 +374,7 @@ kernelfault:
 		case 0x848e:	/* mov 0xa8(%rsp),%es (8e 84 24 a8 00 00 00) */
 		case 0x9c8e:	/* mov 0xb0(%rsp),%ds (8e 9c 24 b0 00 00 00) */
 			/*
-			 * We faulted loading one if the user segment registers.
+			 * We faulted loading one of the user segment registers.
 			 * The stack frame containing the user registers is
 			 * still valid and pointed to by tf_rsp.
 			 * Maybe we should check the iretq follows.

Index: src/sys/arch/i386/i386/trap.c
diff -u src/sys/arch/i386/i386/trap.c:1.276 src/sys/arch/i386/i386/trap.c:1.277
--- src/sys/arch/i386/i386/trap.c:1.276	Wed Dec 16 18:54:03 2015
+++ src/sys/arch/i386/i386/trap.c	Thu Aug 11 14:58:29 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: trap.c,v 1.276 2015/12/16 18:54:03 maxv Exp $	*/
+/*	$NetBSD: trap.c,v 1.277 2016/08/11 14:58:29 maxv Exp $	*/
 
 /*-
  * Copyright (c) 1998, 2000, 2005, 2006, 2007, 2008 The NetBSD Foundation, Inc.
@@ -68,7 +68,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: trap.c,v 1.276 2015/12/16 18:54:03 maxv Exp $");
+__KERNEL_RCSID(0, "$NetBSD: trap.c,v 1.277 2016/08/11 14:58:29 maxv Exp $");
 
 #include "opt_ddb.h"
 #include "opt_kgdb.h"
@@ -116,7 +116,7 @@ __KERNEL_RCSID(0, "$NetBSD: trap.c,v 1.2
 #include <sys/dtrace_bsd.h>
 
 /*
- * This is a hook which is initialised by the dtrace module
+ * This is a hook which is initialized by the dtrace module
  * to handle traps which might occur during DTrace probe
  * execution.
  */
@@ -291,8 +291,7 @@ trap(struct trapframe *frame)
 		trap_print(frame, l);
 	}
 #endif
-	if (type != T_NMI &&
-	    !KERNELMODE(frame->tf_cs, frame->tf_eflags)) {
+	if (type != T_NMI && !KERNELMODE(frame->tf_cs, frame->tf_eflags)) {
 		type |= T_USER;
 		l->l_md.md_regs = frame;
 		pcb->pcb_cr2 = 0;
@@ -322,9 +321,6 @@ trap(struct trapframe *frame)
 
 	switch (type) {
 
-	case T_ASTFLT:
-		/*FALLTHROUGH*/
-
 	default:
 	we_re_toast:
 		if (type == T_TRCTRAP)
@@ -409,7 +405,7 @@ kernelfault:
 				goto we_re_toast;
 			}
 			/*
-			 * We faulted loading one if the user segment registers.
+			 * We faulted loading one of the user segment registers.
 			 * The stack frame containing the user registers is
 			 * still valid and is just below the %eip:%cs:%fl of
 			 * the kernel fault frame.

Reply via email to