From owner-cvs-all Sun Dec 29 10:30:51 2002 Delivered-To: cvs-all@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 5C9FB37B401; Sun, 29 Dec 2002 10:30:50 -0800 (PST) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 1B09F43ED8; Sun, 29 Dec 2002 10:30:50 -0800 (PST) (envelope-from iedowse@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.12.6/8.12.6) with ESMTP id gBTIUnfh083528; Sun, 29 Dec 2002 10:30:49 -0800 (PST) (envelope-from iedowse@repoman.freebsd.org) Received: (from iedowse@localhost) by repoman.freebsd.org (8.12.6/8.12.6/Submit) id gBTIUnfG083520; Sun, 29 Dec 2002 10:30:49 -0800 (PST) Message-Id: <200212291830.gBTIUnfG083520@repoman.freebsd.org> From: Ian Dowse Date: Sun, 29 Dec 2002 10:30:49 -0800 (PST) To: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org Subject: cvs commit: src/sys/sys vnode.h src/sys/kern vfs_subr.c X-FreeBSD-CVS-Branch: HEAD Sender: owner-cvs-all@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG iedowse 2002/12/29 10:30:49 PST Modified files: sys/sys vnode.h sys/kern vfs_subr.c Log: Add a new vnode flag VI_DOINGINACT to indicate that a VOP_INACTIVE call is in progress on the vnode. When vput() or vrele() sees a 1->0 reference count transition, it now return without any further action if this flag is set. This flag is necessary to avoid recursion into VOP_INACTIVE if the filesystem inactive routine causes the reference count to increase and then drop back to zero. It is also used to guarantee that an unlocked vnode will not be recycled while blocked in VOP_INACTIVE(). There are at least two cases where the recursion can occur: one is that the softupdates code called by ufs_inactive() via ffs_truncate() can call vput() on the vnode. This has been reported by many people as "lockmgr: draining against myself" panics. The other case is that nfs_inactive() can call vget() and then vrele() on the vnode to clean up a sillyrename file. Reviewed by: mckusick (an older version of the patch) Revision Changes Path 1.426 +38 -15 src/sys/kern/vfs_subr.c 1.219 +3 -2 src/sys/sys/vnode.h To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message