Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 11 Aug 2016 23:13:17 +0000
From:      Glen Barber <gjb@FreeBSD.org>
To:        Slawa Olhovchenkov <slw@zxy.spb.ru>
Cc:        Andriy Gapon <avg@FreeBSD.org>, src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org
Subject:   Re: svn commit: r303970 - in stable/11/sys/cddl: compat/opensolaris/sys contrib/opensolaris/uts/common/fs/zfs contrib/opensolaris/uts/common/fs/zfs/sys
Message-ID:  <20160811231317.GH51184@FreeBSD.org>
In-Reply-To: <20160811230747.GJ8192@zxy.spb.ru>
References:  <201608112048.u7BKm4OH076291@repo.freebsd.org> <20160811223331.GF22212@zxy.spb.ru> <20160811223637.GE51184@FreeBSD.org> <20160811225202.GI8192@zxy.spb.ru> <20160811225723.GG51184@FreeBSD.org> <20160811230747.GJ8192@zxy.spb.ru>

next in thread | previous in thread | raw e-mail | index | archive | help

[-- Attachment #1 --]
On Fri, Aug 12, 2016 at 02:07:47AM +0300, Slawa Olhovchenkov wrote:
> On Thu, Aug 11, 2016 at 10:57:23PM +0000, Glen Barber wrote:
> 
> > On Fri, Aug 12, 2016 at 01:52:02AM +0300, Slawa Olhovchenkov wrote:
> > > On Thu, Aug 11, 2016 at 10:36:37PM +0000, Glen Barber wrote:
> > > 
> > > > On Fri, Aug 12, 2016 at 01:33:31AM +0300, Slawa Olhovchenkov wrote:
> > > > > On Thu, Aug 11, 2016 at 08:48:04PM +0000, Andriy Gapon wrote:
> > > > > 
> > > > > > Author: avg
> > > > > > Date: Thu Aug 11 20:48:03 2016
> > > > > > New Revision: 303970
> > > > > > URL: https://svnweb.freebsd.org/changeset/base/303970
> > > > > > 
> > > > > > Log:
> > > > > >   MFC r303763,303791,303869: zfs: honour and make use of vfs vnode locking protocol
> > > > > >   
> > > > > >   ZFS POSIX Layer is originally written for Solaris VFS which is very
> > > > > >   different from FreeBSD VFS.  Most importantly many things that FreeBSD VFS
> > > > > >   manages on behalf of all filesystems are implemented in ZPL in a different
> > > > > >   way.
> > > > > >   Thus, ZPL contains code that is redundant on FreeBSD or duplicates VFS
> > > > > >   functionality or, in the worst cases, badly interacts / interferes
> > > > > >   with VFS.
> > > > > >   
> > > > > >   The most prominent problem is a deadlock caused by the lock order reversal
> > > > > >   of vnode locks that may happen with concurrent zfs_rename() and lookup().
> > > > > >   The deadlock is a result of zfs_rename() not observing the vnode locking
> > > > > >   contract expected by VFS.
> > > > > >   
> > > > > >   This commit removes all ZPL internal locking that protects parent-child
> > > > > >   relationships of filesystem nodes.  These relationships are protected
> > > > > >   by vnode locks and the code is changed to take advantage of that fact
> > > > > >   and to properly interact with VFS.
> > > > > >   
> > > > > >   Removal of the internal locking allowed all ZPL dmu_tx_assign calls to
> > > > > >   use TXG_WAIT mode.
> > > > > >   
> > > > > >   Another victim, disputable perhaps, is ZFS support for filesystems with
> > > > > >   mixed case sensitivity.  That support is not provided by the OS anyway,
> > > > > >   so in ZFS it was a buch of dead code.
> > > > > >   
> > > > > >   To do:
> > > > > >   - replace ZFS_ENTER mechanism with VFS managed / visible mechanism
> > > > > >   - replace zfs_zget with zfs_vget[f] as much as possible
> > > > > >   - get rid of not really useful now zfs_freebsd_* adapters
> > > > > >   - more cleanups of unneeded / unused code
> > > > > >   - fix / replace .zfs support
> > > > > 
> > > > > MFC to 10.x/9.x planed?
> > > > > 
> > > > 
> > > > As I understand it, this does not affect stable/10.
> > > 
> > > Sure?
> > > I think ZFS/VFS layers don't change between 9.x and 11.x
> > > 
> > 
> > No, but as I understand it, a commit to head tickled this bug.  avg@ can
> > correct me if I am wrong.
> 
> May be I am wrong, I see messages about like issuses in 9.x/10.x.
> As I understund this is more clear implementation.
> Also, unification in 12.x/10.x take benefit for MFC other ZFS diffs.
> 

I agree with you.  I am just unsure if this particular bug affects 10.x
and 9.x.

Glen


[-- Attachment #2 --]
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2

iQIcBAEBCAAGBQJXrQaNAAoJEAMUWKVHj+KT44IP/2p+8QbGfaZiZ5fmnGMNu3SO
xByEFNL9WN8TlZWOXVH9FYgynD3AOlyU0il57+tNvbhUsfh2b1iwThMW0KUaDac8
zGptk97rzO2j5Oe5H3gAhlmk3jnKTAPbcBhAiFuzraLmAvGq/hLxnO4bE/kKkY4W
Nzm0L9fOoeCcTE1YRgRobNIWP2WAtE+h5qwTMaww+dsI4dsPtfy2aRzQlbR47y3O
k+h5S37vuE9FtX4cBTOmGvH1rmlRnKXJIm+awEAFWswfOVJ4tZCTSCWmmEIlDQ2K
oEp68eLtzP3MlRdRVSSpznGNZZjWAGaoTYM+WGXrt+oennQbA6iHiYVNrp5kWg7e
TQGwozz33Dx3FNpj4QtO0PQ82lHP4VeMNO9xODBrBYV4uQ8i5kol9heZ3Vm+hpf/
lxjFXvSGHuh55UUMXfffHEUZx2Sook07eKwwnBM3Ohbh+gtESCQmzaYWbtnY5CPk
Mw3lF/msGwHGTz2KPIUuzhEzSQRYzz9mcOOT8HViK7kiWXL/2L3YFBiO7T9klfxw
IORrn1Eq76x+FxW67rJVGYf5T0RALsy/lCVsd53KR2o6nzrsiDNMG/DTwNWoFy2J
c52+gkgDeG0PdnFoJ9kTCL4IP6FMR0SvhkEc5I8PJGXpcOMnfpNBkO3TBVWOArby
TipHoLUcDmFUgPiouOnb
=BHb/
-----END PGP SIGNATURE-----

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