From 7035c50aa03b0b748dccbbc784660fe81251bcb1 Mon Sep 17 00:00:00 2001 From: Theo de Raadt Date: Tue, 11 Aug 2009 10:48:40 +0000 Subject: Must move the splx() lower in m_clget() so that it protects atomic access to the per-ipf mbuf cluster reference counters ok dlg claudio --- sys/kern/uipc_mbuf.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'sys/kern') diff --git a/sys/kern/uipc_mbuf.c b/sys/kern/uipc_mbuf.c index 6fe7e1ab646..7636f9ad2d7 100644 --- a/sys/kern/uipc_mbuf.c +++ b/sys/kern/uipc_mbuf.c @@ -1,4 +1,4 @@ -/* $OpenBSD: uipc_mbuf.c,v 1.128 2009/08/09 21:08:30 deraadt Exp $ */ +/* $OpenBSD: uipc_mbuf.c,v 1.129 2009/08/11 10:48:39 deraadt Exp $ */ /* $NetBSD: uipc_mbuf.c,v 1.15.4.1 1996/06/13 17:11:44 cgd Exp $ */ /* @@ -421,7 +421,6 @@ m_clget(struct mbuf *m, int how, struct ifnet *ifp, u_int pktlen) splx(s); return (NULL); } - splx(s); if (m->m_ext.ext_buf != NULL) { m->m_data = m->m_ext.ext_buf; m->m_flags |= M_EXT|M_CLUSTER; @@ -436,6 +435,7 @@ m_clget(struct mbuf *m, int how, struct ifnet *ifp, u_int pktlen) MCLINITREFERENCE(m); } + splx(s); return (m); } -- cgit v1.2.3