Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 30 Jan 2021 08:14:17 GMT
From:      Kirk McKusick <mckusick@FreeBSD.org>
To:        src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org
Subject:   git: 1aa1ede1fd44 - stable/13 - MFC: a63eae6
Message-ID:  <202101300814.10U8EHB6087518@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch stable/13 has been updated by mckusick:

URL: https://cgit.FreeBSD.org/src/commit/?id=1aa1ede1fd447a1807f0cdd9ee7227b5741fecea

commit 1aa1ede1fd447a1807f0cdd9ee7227b5741fecea
Author:     Kirk McKusick <mckusick@FreeBSD.org>
AuthorDate: 2021-01-30 08:03:37 +0000
Commit:     Kirk McKusick <mckusick@FreeBSD.org>
CommitDate: 2021-01-30 08:15:41 +0000

    MFC: a63eae6
    
    Revert 2d4422e7991a, Eliminate lock order reversal in UFS ffs_unmount().
    
    After discussion with Chuck Silvers (chs@) we have decided that
    there is a better way to resolve this lock order reversal which
    will be committed separately.
    
    Sponsored by: Netflix
    
    (cherry picked from commit a63eae65ff8789994c40573a0aa65128022c8bf2)
---
 sys/ufs/ffs/ffs_vfsops.c | 9 +--------
 1 file changed, 1 insertion(+), 8 deletions(-)

diff --git a/sys/ufs/ffs/ffs_vfsops.c b/sys/ufs/ffs/ffs_vfsops.c
index 415bb4614c1a..60d4dad57d03 100644
--- a/sys/ufs/ffs/ffs_vfsops.c
+++ b/sys/ufs/ffs/ffs_vfsops.c
@@ -1547,14 +1547,7 @@ ffs_unmount(mp, mntflags)
 	BO_UNLOCK(&ump->um_odevvp->v_bufobj);
 	atomic_store_rel_ptr((uintptr_t *)&ump->um_dev->si_mountpt, 0);
 	mntfs_freevp(ump->um_devvp);
-	/* Avoid LOR in vrele by passing in locked vnode and using vput */
-	if (vn_lock(ump->um_odevvp, LK_EXCLUSIVE | LK_NOWAIT) == 0) {
-		vput(ump->um_odevvp);
-	} else {
-		/* This should never happen, see commit message for details */
-		printf("ffs_unmount: Unexpected LK_NOWAIT failure\n");
-		vrele(ump->um_odevvp);
-	}
+	vrele(ump->um_odevvp);
 	dev_rel(ump->um_dev);
 	mtx_destroy(UFS_MTX(ump));
 	if (mp->mnt_gjprovider != NULL) {



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202101300814.10U8EHB6087518>