Date: Thu, 7 May 2009 20:28:06 +0000 (UTC) From: Kip Macy <kmacy@FreeBSD.org> To: cvs-src-old@freebsd.org Subject: cvs commit: src/sys/cddl/contrib/opensolaris/uts/common/fs vnode.c src/sys/cddl/contrib/opensolaris/uts/common/fs/zfs dmu.c zfs_vnops.c zil.c src/sys/cddl/contrib/opensolaris/uts/common/sys vnode.h Message-ID: <200905072028.n47KS9dj081254@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
kmacy 2009-05-07 20:28:06 UTC FreeBSD src repository Modified files: sys/cddl/contrib/opensolaris/uts/common/fs vnode.c sys/cddl/contrib/opensolaris/uts/common/fs/zfs dmu.c zfs_vnops.c zil.c sys/cddl/contrib/opensolaris/uts/common/sys vnode.h Log: SVN rev 191900 on 2009-05-07 20:28:06Z by kmacy Asynchronously release vnodes to avoid blocking on range locks when calling back in to zfs. This is based on a fix that went in to opensolaris on March 9th. However, it uses a dedicated thread instead of a Solaris' taskq to avoid doing a blocking memory allocation with the vnode interlock held. This fixes a long-time deadlock in ZFS. This is not, strictly speaking, an LOR. The spa_zio thread releases a vnode, this calls in to vn_reclaim which in turn needs to acquire range locks to sync dirty data out to disk. The range locks are already held by a user-level process waiting on a condition variable that it the process is waiting on a spa_zio thread to signal it on. The process could not be signalled because the spa_zio thread could not proceed. The nature of this problem was not apparent due to ZFS locks opting out of witness which meant that DDB did not know about the locks that were held by ZFS. Reviewed by: pjd MFC after: 7 days Revision Changes Path 1.2 +137 -0 src/sys/cddl/contrib/opensolaris/uts/common/fs/vnode.c 1.4 +1 -0 src/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu.c 1.40 +17 -3 src/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_vnops.c 1.6 +1 -1 src/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zil.c 1.2 +9 -0 src/sys/cddl/contrib/opensolaris/uts/common/sys/vnode.h
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200905072028.n47KS9dj081254>