Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 638a7174 authored by Darrick J. Wong's avatar Darrick J. Wong
Browse files

xfs: don't iunlock unlocked inodes



Don't iunlock an unlocked inode, which can happen if the parent pointer
scrubber bails out with sc->ip unlocked while trying to grab the parent
directory inode.

Signed-off-by: default avatarDarrick J. Wong <darrick.wong@oracle.com>
Reviewed-by: default avatarBrian Foster <bfoster@redhat.com>
parent cf1b0b8b
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -159,6 +159,7 @@ xfs_scrub_teardown(
		sc->tp = NULL;
	}
	if (sc->ip) {
		if (sc->ilock_flags)
			xfs_iunlock(sc->ip, sc->ilock_flags);
		if (sc->ip != ip_in &&
		    !xfs_internal_inum(sc->mp, sc->ip->i_ino))