Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/kern assertion



details:   https://anonhg.NetBSD.org/src/rev/7aa5a811cce4
branches:  trunk
changeset: 771745:7aa5a811cce4
user:      yamt <yamt%NetBSD.org@localhost>
date:      Fri Dec 02 12:33:12 2011 +0000

description:
assertion

diffstat:

 sys/kern/kern_resource.c |  6 ++++--
 1 files changed, 4 insertions(+), 2 deletions(-)

diffs (27 lines):

diff -r 571de775af94 -r 7aa5a811cce4 sys/kern/kern_resource.c
--- a/sys/kern/kern_resource.c  Fri Dec 02 12:32:38 2011 +0000
+++ b/sys/kern/kern_resource.c  Fri Dec 02 12:33:12 2011 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: kern_resource.c,v 1.167 2011/06/03 17:58:18 rmind Exp $        */
+/*     $NetBSD: kern_resource.c,v 1.168 2011/12/02 12:33:12 yamt Exp $ */
 
 /*-
  * Copyright (c) 1982, 1986, 1991, 1993
@@ -37,7 +37,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: kern_resource.c,v 1.167 2011/06/03 17:58:18 rmind Exp $");
+__KERNEL_RCSID(0, "$NetBSD: kern_resource.c,v 1.168 2011/12/02 12:33:12 yamt Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -484,6 +484,8 @@
        struct bintime tm;
        struct timeval tv;
 
+       KASSERT(p->p_stat == SDEAD || mutex_owned(p->p_lock));
+
        mutex_spin_enter(&p->p_stmutex);
        st = p->p_sticks;
        ut = p->p_uticks;



Home | Main Index | Thread Index | Old Index