diff options
author | peter <peter@FreeBSD.org> | 2000-08-25 22:28:08 +0000 |
---|---|---|
committer | peter <peter@FreeBSD.org> | 2000-08-25 22:28:08 +0000 |
commit | 84c0ff464eab1e6a55fde75c0b55fbe2e0dcc2a2 (patch) | |
tree | 7b57c50915c336c3205318b83bcadce5bee4ebcc /sys | |
parent | d9362d87174823461005a87a1f42268e10efa9d5 (diff) | |
download | FreeBSD-src-84c0ff464eab1e6a55fde75c0b55fbe2e0dcc2a2.zip FreeBSD-src-84c0ff464eab1e6a55fde75c0b55fbe2e0dcc2a2.tar.gz |
m_mballoc_wait() had a spl/tsleep race. mbufs can be freed in interrupt
context, which can cause a wakeup.. which can race with this.
Diffstat (limited to 'sys')
-rw-r--r-- | sys/kern/uipc_mbuf.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/sys/kern/uipc_mbuf.c b/sys/kern/uipc_mbuf.c index ee0b58c..2db80b2 100644 --- a/sys/kern/uipc_mbuf.c +++ b/sys/kern/uipc_mbuf.c @@ -249,9 +249,11 @@ m_mballoc_wait(int caller, int type) struct mbuf *p; int s; + s = splimp(); m_mballoc_wid++; if ((tsleep(&m_mballoc_wid, PVM, "mballc", mbuf_wait)) == EWOULDBLOCK) m_mballoc_wid--; + splx(s); /* * Now that we (think) that we've got something, we will redo an |