Change VERIFY to ASSERT in mutex_destroy()

There have been multiple reports of 'zdb' tripping the VERIFY in
mutex_destroy() because pthread_mutex_destroy() returns EBUSY.

Exactly how this can happen still needs to be explained, but this
doesn't strictly need to be fatal for non-debug builds.  Therefore,
this patch converts the VERIFY to an ASSERT until the root cause
is determined and resolved.

Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
Issue #2027
This commit is contained in:
Brian Behlendorf 2014-10-30 11:11:00 -07:00
parent 5f15fa2216
commit 340dfbe193

View File

@ -289,7 +289,7 @@ mutex_destroy(kmutex_t *mp)
{ {
ASSERT3U(mp->m_magic, ==, MTX_MAGIC); ASSERT3U(mp->m_magic, ==, MTX_MAGIC);
ASSERT3P(mp->m_owner, ==, MTX_INIT); ASSERT3P(mp->m_owner, ==, MTX_INIT);
VERIFY3S(pthread_mutex_destroy(&(mp)->m_lock), ==, 0); ASSERT0(pthread_mutex_destroy(&(mp)->m_lock));
mp->m_owner = MTX_DEST; mp->m_owner = MTX_DEST;
mp->m_magic = 0; mp->m_magic = 0;
} }