Date: Fri, 20 Sep 2013 15:17:05 +0200 From: Patrick Lamaiziere <patfbsd@davenulle.org> To: freebsd-stable@freebsd.org, Konstantin Belousov <kostikbel@gmail.com> Subject: Re: Possible kqueue related issue on STABLE/RC. Message-ID: <20130920151705.33aae120@mr129166> In-Reply-To: <20130912073643.GM41229@kib.kiev.ua> References: <alpine.BSF.2.00.1309111705460.89324@olgeni.olgeni> <20130911171913.GG41229@kib.kiev.ua> <alpine.BSF.2.00.1309112316160.2547@olgeni.olgeni> <20130912073643.GM41229@kib.kiev.ua>
next in thread | previous in thread | raw e-mail | index | archive | help
Le Thu, 12 Sep 2013 10:36:43 +0300, Konstantin Belousov <kostikbel@gmail.com> a écrit : Hello, > Might be, your issue is that some filesystems do not care about proper > locking mode for the fifos. UFS carefully disables shared locking for > VFIFO, but it seems ZFS is not. I can propose the following band-aid, > which could help you. > > I have no idea is it the same issue as the kqueue panic. > > diff --git a/sys/kern/vfs_vnops.c b/sys/kern/vfs_vnops.c > index c53030a..00bd998 100644 > --- a/sys/kern/vfs_vnops.c > +++ b/sys/kern/vfs_vnops.c > @@ -267,6 +267,8 @@ vn_open_vnode(struct vnode *vp, int fmode, struct > ucred *cred, return (error); > } > } > + if (vp->v_type == VFIFO && VOP_ISLOCKED(vp) != LK_EXCLUSIVE) > + vn_lock(vp, LK_UPGRADE | LK_RETRY); > if ((error = VOP_OPEN(vp, fmode, cred, td, fp)) != 0) > return (error); > > @@ -358,7 +360,7 @@ vn_close(vp, flags, file_cred, td) > struct mount *mp; > int error, lock_flags; > > - if (!(flags & FWRITE) && vp->v_mount != NULL && > + if (vp->v_type != VFIFO && !(flags & FWRITE) && > vp->v_mount != NULL && vp->v_mount->mnt_kern_flag & > MNTK_EXTENDED_SHARED) lock_flags = LK_SHARED; > else Hmmm, So what is the fix for 9.2-STABLE ? As far I can see there is no function vn_open_vnode() here and I don't see where I should patch. I see this panic too (with STABLE of today), while using poudriere + ZFS like Jimmy. Thanks, regards
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20130920151705.33aae120>