Date: Tue, 19 Aug 2014 17:04:18 +0000 (UTC) From: Alexander Motin <mav@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r270176 - head/sys/cam/ctl Message-ID: <201408191704.s7JH4I3c045203@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: mav Date: Tue Aug 19 17:04:18 2014 New Revision: 270176 URL: http://svnweb.freebsd.org/changeset/base/270176 Log: Fix lock recursion on LUN shutdown, introduced on r269497. MFC after: 3 days Modified: head/sys/cam/ctl/ctl_tpc.c Modified: head/sys/cam/ctl/ctl_tpc.c ============================================================================== --- head/sys/cam/ctl/ctl_tpc.c Tue Aug 19 15:51:43 2014 (r270175) +++ head/sys/cam/ctl/ctl_tpc.c Tue Aug 19 17:04:18 2014 (r270176) @@ -228,7 +228,7 @@ ctl_tpc_lun_shutdown(struct ctl_lun *lun } /* Free ROD tokens for this LUN. */ - mtx_lock(&control_softc->ctl_lock); + mtx_assert(&control_softc->ctl_lock, MA_OWNED); TAILQ_FOREACH_SAFE(token, &control_softc->tpc_tokens, links, ttoken) { if (token->lun != lun->lun || token->active) continue; @@ -236,7 +236,6 @@ ctl_tpc_lun_shutdown(struct ctl_lun *lun free(token->params, M_CTL); free(token, M_CTL); } - mtx_unlock(&control_softc->ctl_lock); } int
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201408191704.s7JH4I3c045203>