From owner-cvs-src@FreeBSD.ORG Tue Jun 17 01:52:46 2003 Return-Path: Delivered-To: cvs-src@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6DC9937B401; Tue, 17 Jun 2003 01:52:46 -0700 (PDT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 1A75B43F85; Tue, 17 Jun 2003 01:52:46 -0700 (PDT) (envelope-from tjr@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 h5H8qj0U087303; Tue, 17 Jun 2003 01:52:45 -0700 (PDT) (envelope-from tjr@repoman.freebsd.org) Received: (from tjr@localhost) by repoman.freebsd.org (8.12.6/8.12.6/Submit) id h5H8qjgg087299; Tue, 17 Jun 2003 01:52:45 -0700 (PDT) Message-Id: <200306170852.h5H8qjgg087299@repoman.freebsd.org> From: "Tim J. Robbins" Date: Tue, 17 Jun 2003 01:52:45 -0700 (PDT) To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org X-FreeBSD-CVS-Branch: HEAD Subject: cvs commit: src/sys/fs/nullfs null.h null_subr.c null_vnops.c X-BeenThere: cvs-src@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 17 Jun 2003 08:52:46 -0000 tjr 2003/06/17 01:52:45 PDT FreeBSD src repository Modified files: sys/fs/nullfs null.h null_subr.c null_vnops.c Log: MFp4: Fix two bugs causing possible deadlocks or panics, and one nit: - Emulate lock draining (LK_DRAIN) in null_lock() to avoid deadlocks when the vnode is being recycled. - Don't allow null_nodeget() to return a nullfs vnode from the wrong mount when multiple nullfs's are mounted. It's unclear why these checks were removed in null_subr.c 1.35, but they are definitely necessary. Without the checks, trying to unmount a nullfs mount will erroneously return EBUSY, and forcibly unmounting with -f will cause a panic. - Bump LOG2_SIZEVNODE up to 8, since vnodes are >256 bytes now. The old value (7) didn't cause any problems, but made the hash algorithm suboptimal. These changes fix nullfs enough that a parallel buildworld succeeds. Submitted by: tegge (partially; LK_DRAIN) Tested by: kris Revision Changes Path 1.19 +2 -0 src/sys/fs/nullfs/null.h 1.41 +36 -9 src/sys/fs/nullfs/null_subr.c 1.63 +57 -4 src/sys/fs/nullfs/null_vnops.c