Wed Mar 12 18:59:07 2014 UTC ()
Mark a variable diagnostic-only, from John D. Baker.


(martin)
diff -r1.271 -r1.272 src/sys/arch/i386/i386/trap.c

cvs diff -r1.271 -r1.272 src/sys/arch/i386/i386/trap.c (expand / switch to unified diff)

--- src/sys/arch/i386/i386/trap.c 2014/02/12 23:24:09 1.271
+++ src/sys/arch/i386/i386/trap.c 2014/03/12 18:59:07 1.272
@@ -1,14 +1,14 @@ @@ -1,14 +1,14 @@
1/* $NetBSD: trap.c,v 1.271 2014/02/12 23:24:09 dsl Exp $ */ 1/* $NetBSD: trap.c,v 1.272 2014/03/12 18:59:07 martin Exp $ */
2 2
3/*- 3/*-
4 * Copyright (c) 1998, 2000, 2005, 2006, 2007, 2008 The NetBSD Foundation, Inc. 4 * Copyright (c) 1998, 2000, 2005, 2006, 2007, 2008 The NetBSD Foundation, Inc.
5 * All rights reserved. 5 * All rights reserved.
6 * 6 *
7 * This code is derived from software contributed to The NetBSD Foundation 7 * This code is derived from software contributed to The NetBSD Foundation
8 * by Charles M. Hannum. 8 * by Charles M. Hannum.
9 * 9 *
10 * Redistribution and use in source and binary forms, with or without 10 * Redistribution and use in source and binary forms, with or without
11 * modification, are permitted provided that the following conditions 11 * modification, are permitted provided that the following conditions
12 * are met: 12 * are met:
13 * 1. Redistributions of source code must retain the above copyright 13 * 1. Redistributions of source code must retain the above copyright
14 * notice, this list of conditions and the following disclaimer. 14 * notice, this list of conditions and the following disclaimer.
@@ -58,27 +58,27 @@ @@ -58,27 +58,27 @@
58 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 58 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
59 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 59 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
60 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 60 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
61 * SUCH DAMAGE. 61 * SUCH DAMAGE.
62 * 62 *
63 * @(#)trap.c 7.4 (Berkeley) 5/13/91 63 * @(#)trap.c 7.4 (Berkeley) 5/13/91
64 */ 64 */
65 65
66/* 66/*
67 * 386 Trap and System call handling 67 * 386 Trap and System call handling
68 */ 68 */
69 69
70#include <sys/cdefs.h> 70#include <sys/cdefs.h>
71__KERNEL_RCSID(0, "$NetBSD: trap.c,v 1.271 2014/02/12 23:24:09 dsl Exp $"); 71__KERNEL_RCSID(0, "$NetBSD: trap.c,v 1.272 2014/03/12 18:59:07 martin Exp $");
72 72
73#include "opt_ddb.h" 73#include "opt_ddb.h"
74#include "opt_kgdb.h" 74#include "opt_kgdb.h"
75#include "opt_lockdebug.h" 75#include "opt_lockdebug.h"
76#include "opt_multiprocessor.h" 76#include "opt_multiprocessor.h"
77#include "opt_vm86.h" 77#include "opt_vm86.h"
78#include "opt_kstack_dr0.h" 78#include "opt_kstack_dr0.h"
79#include "opt_xen.h" 79#include "opt_xen.h"
80#include "opt_dtrace.h" 80#include "opt_dtrace.h"
81 81
82#include <sys/param.h> 82#include <sys/param.h>
83#include <sys/systm.h> 83#include <sys/systm.h>
84#include <sys/proc.h> 84#include <sys/proc.h>
@@ -737,21 +737,21 @@ trapsignal: @@ -737,21 +737,21 @@ trapsignal:
737 ksi.ksi_trap = type & ~T_USER; 737 ksi.ksi_trap = type & ~T_USER;
738 (*p->p_emul->e_trapsignal)(l, &ksi); 738 (*p->p_emul->e_trapsignal)(l, &ksi);
739 userret(l); 739 userret(l);
740} 740}
741 741
742/*  742/*
743 * startlwp: start of a new LWP. 743 * startlwp: start of a new LWP.
744 */ 744 */
745void 745void
746startlwp(void *arg) 746startlwp(void *arg)
747{ 747{
748 ucontext_t *uc = arg; 748 ucontext_t *uc = arg;
749 lwp_t *l = curlwp; 749 lwp_t *l = curlwp;
750 int error; 750 int error __diagused;
751 751
752 error = cpu_setmcontext(l, &uc->uc_mcontext, uc->uc_flags); 752 error = cpu_setmcontext(l, &uc->uc_mcontext, uc->uc_flags);
753 KASSERT(error == 0); 753 KASSERT(error == 0);
754 754
755 kmem_free(uc, sizeof(ucontext_t)); 755 kmem_free(uc, sizeof(ucontext_t));
756 userret(l); 756 userret(l);
757} 757}