Date: Fri, 5 Aug 2011 07:30:18 GMT From: Gleb Kurtsou <gleb.kurtsou@gmail.com> To: freebsd-fs@FreeBSD.org Subject: Re: kern/159418: [tmpfs] [panic] tmpfs kernel panic: recursing on non recursive lockmgr tmpfs Message-ID: <201108050730.p757UHus069017@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
The following reply was made to PR kern/159418; it has been noted by GNATS.
From: Gleb Kurtsou <gleb.kurtsou@gmail.com>
To: bug-followup@FreeBSD.org, gpr@mail.ru
Cc:
Subject: Re: kern/159418: [tmpfs] [panic] tmpfs kernel panic: recursing on
non recursive lockmgr tmpfs
Date: Fri, 5 Aug 2011 09:55:50 +0300
--UlVJffcvxoiEqYs2
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
Could you test the patch attached.
Thanks,
Gleb.
--UlVJffcvxoiEqYs2
Content-Type: text/plain; charset=utf-8
Content-Disposition: attachment; filename="tmpfs-rename_lock.patch.txt"
--- a/sys/fs/tmpfs/tmpfs_vnops.c
+++ b/sys/fs/tmpfs/tmpfs_vnops.c
@@ -968,7 +968,7 @@ tmpfs_rename(struct vop_rename_args *v)
/* If we need to move the directory between entries, lock the
* source so that we can safely operate on it. */
- if (tdvp != fdvp) {
+ if (fdvp != tdvp && fdvp != tvp) {
error = vn_lock(fdvp, LK_EXCLUSIVE | LK_RETRY);
if (error != 0)
goto out;
@@ -1145,7 +1145,7 @@ tmpfs_rename(struct vop_rename_args *v)
error = 0;
out_locked:
- if (fdnode != tdnode)
+ if (fdvp != tdvp && fdvp != tvp)
VOP_UNLOCK(fdvp, 0);
out:
--UlVJffcvxoiEqYs2--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201108050730.p757UHus069017>
