Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/kern Don't check pserialize_not_in_read_section after panic
details: https://anonhg.NetBSD.org/src/rev/266506f1a416
branches: trunk
changeset: 450533:266506f1a416
user: ozaki-r <ozaki-r%NetBSD.org@localhost>
date: Wed Apr 17 02:29:43 2019 +0000
description:
Don't check pserialize_not_in_read_section after panic
It can cause a false positive assertion failure.
diffstat:
sys/kern/kern_mutex.c | 6 +++---
sys/kern/kern_rwlock.c | 6 +++---
2 files changed, 6 insertions(+), 6 deletions(-)
diffs (58 lines):
diff -r 42b598d46398 -r 266506f1a416 sys/kern/kern_mutex.c
--- a/sys/kern/kern_mutex.c Tue Apr 16 23:14:34 2019 +0000
+++ b/sys/kern/kern_mutex.c Wed Apr 17 02:29:43 2019 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: kern_mutex.c,v 1.76 2019/03/10 12:49:48 skrll Exp $ */
+/* $NetBSD: kern_mutex.c,v 1.77 2019/04/17 02:29:43 ozaki-r Exp $ */
/*-
* Copyright (c) 2002, 2006, 2007, 2008 The NetBSD Foundation, Inc.
@@ -40,7 +40,7 @@
#define __MUTEX_PRIVATE
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: kern_mutex.c,v 1.76 2019/03/10 12:49:48 skrll Exp $");
+__KERNEL_RCSID(0, "$NetBSD: kern_mutex.c,v 1.77 2019/04/17 02:29:43 ozaki-r Exp $");
#include <sys/param.h>
#include <sys/atomic.h>
@@ -524,9 +524,9 @@
MUTEX_ASSERT(mtx, curthread != 0);
MUTEX_ASSERT(mtx, !cpu_intr_p());
MUTEX_WANTLOCK(mtx);
- KDASSERT(pserialize_not_in_read_section());
if (panicstr == NULL) {
+ KDASSERT(pserialize_not_in_read_section());
LOCKDEBUG_BARRIER(&kernel_lock, 1);
}
diff -r 42b598d46398 -r 266506f1a416 sys/kern/kern_rwlock.c
--- a/sys/kern/kern_rwlock.c Tue Apr 16 23:14:34 2019 +0000
+++ b/sys/kern/kern_rwlock.c Wed Apr 17 02:29:43 2019 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: kern_rwlock.c,v 1.52 2018/08/31 01:23:57 ozaki-r Exp $ */
+/* $NetBSD: kern_rwlock.c,v 1.53 2019/04/17 02:29:43 ozaki-r Exp $ */
/*-
* Copyright (c) 2002, 2006, 2007, 2008, 2009 The NetBSD Foundation, Inc.
@@ -38,7 +38,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: kern_rwlock.c,v 1.52 2018/08/31 01:23:57 ozaki-r Exp $");
+__KERNEL_RCSID(0, "$NetBSD: kern_rwlock.c,v 1.53 2019/04/17 02:29:43 ozaki-r Exp $");
#define __RWLOCK_PRIVATE
@@ -290,9 +290,9 @@
RW_ASSERT(rw, !cpu_intr_p());
RW_ASSERT(rw, curthread != 0);
RW_WANTLOCK(rw, op);
- KDASSERT(pserialize_not_in_read_section());
if (panicstr == NULL) {
+ KDASSERT(pserialize_not_in_read_section());
LOCKDEBUG_BARRIER(&kernel_lock, 1);
}
Home |
Main Index |
Thread Index |
Old Index