summaryrefslogtreecommitdiff
path: root/sys/net
diff options
context:
space:
mode:
authorVisa Hankala <visa@cvs.openbsd.org>2018-12-18 13:18:32 +0000
committerVisa Hankala <visa@cvs.openbsd.org>2018-12-18 13:18:32 +0000
commit7a8c12dd787a002a9cd87040fff61bfd72a57366 (patch)
treead4d2e5f47381d2427d2f6b2ab0752568a885841 /sys/net
parent79344561e5e05c850119ae4eee9737dbcf026c63 (diff)
Fix the IPL of pfkeyv2_mtx to prevent a deadlock. The system can use
the mutex with and without the kernel lock. Prompted by WITNESS. OK deraadt@ kettenis@
Diffstat (limited to 'sys/net')
-rw-r--r--sys/net/pfkeyv2.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/net/pfkeyv2.c b/sys/net/pfkeyv2.c
index 31c098f15bf..28da11d46fd 100644
--- a/sys/net/pfkeyv2.c
+++ b/sys/net/pfkeyv2.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pfkeyv2.c,v 1.192 2018/09/12 11:24:38 mpi Exp $ */
+/* $OpenBSD: pfkeyv2.c,v 1.193 2018/12/18 13:18:31 visa Exp $ */
/*
* @(#)COPYRIGHT 1.1 (NRL) 17 January 1995
@@ -169,7 +169,7 @@ struct pkptable {
};
struct pkptable pkptable;
-struct mutex pfkeyv2_mtx = MUTEX_INITIALIZER(IPL_NONE);
+struct mutex pfkeyv2_mtx = MUTEX_INITIALIZER(IPL_MPFLOOR);
static uint32_t pfkeyv2_seq = 1;
static int nregistered = 0;
static int npromisc = 0;