From owner-freebsd-fs Fri May 11 14:19: 3 2001 Delivered-To: freebsd-fs@freebsd.org Received: from salmon.maths.tcd.ie (salmon.maths.tcd.ie [134.226.81.11]) by hub.freebsd.org (Postfix) with SMTP id 1E84E37B423; Fri, 11 May 2001 14:19:01 -0700 (PDT) (envelope-from iedowse@maths.tcd.ie) Received: from walton.maths.tcd.ie by salmon.maths.tcd.ie with SMTP id ; 11 May 2001 22:19:00 +0100 (BST) To: freebsd-fs@freebsd.org Cc: phk@freebsd.org, iedowse@maths.tcd.ie Subject: Re: vflush() In-Reply-To: Your message of "Wed, 09 May 2001 22:38:39 BST." <200105092238.aa48273@salmon.maths.tcd.ie> Date: Fri, 11 May 2001 22:19:00 +0100 From: Ian Dowse Message-ID: <200105112219.aa94946@salmon.maths.tcd.ie> Sender: owner-freebsd-fs@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org In message <200105092238.aa48273@salmon.maths.tcd.ie>, Ian Dowse writes: > >All this suggests that vflush() should subsume the logic for dealing >with the reference count on the filesystem root vnode. This would >simplify the xxx_umount() functions and permits the FORCECLOSE >problem to be solved for all 9 filesystems in one place. A working version of a patch that achieves this is at: http://www.maths.tcd.ie/~iedowse/FreeBSD/vflush_patch As a side-effect, this corrects a vnode leak that currently exists in devfs, as there was a vput() missing for the case where vflush() failed. This bug could result in idle devfs filesystems that refuse to unmount. It seems also, that for future filesystems that may not fit into the simple 'N extra references to the root vnode' model, the situation is not all that bad. These filesystems can simply call vflush with rootrefs==0, and then when it fails check the vnode list to see if any vnodes are really busy. This is no more difficult to deal with than the situation we have now. Ian To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-fs" in the body of the message