From owner-svn-src-all@FreeBSD.ORG Fri Jan 22 15:12:01 2010 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id CF281106566C; Fri, 22 Jan 2010 15:12:01 +0000 (UTC) (envelope-from jhb@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id BE8018FC0A; Fri, 22 Jan 2010 15:12:01 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id o0MFC17w005510; Fri, 22 Jan 2010 15:12:01 GMT (envelope-from jhb@svn.freebsd.org) Received: (from jhb@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id o0MFC1Ne005509; Fri, 22 Jan 2010 15:12:01 GMT (envelope-from jhb@svn.freebsd.org) Message-Id: <201001221512.o0MFC1Ne005509@svn.freebsd.org> From: John Baldwin Date: Fri, 22 Jan 2010 15:12:01 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-7@freebsd.org X-SVN-Group: stable-7 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r202811 - stable/7/sys/kern X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 22 Jan 2010 15:12:01 -0000 Author: jhb Date: Fri Jan 22 15:12:01 2010 New Revision: 202811 URL: http://svn.freebsd.org/changeset/base/202811 Log: MFC 191028: Use a shared vnode lock for reads in vn_rdwr(). Modified: stable/7/sys/kern/vfs_vnops.c Directory Properties: stable/7/sys/ (props changed) stable/7/sys/cddl/contrib/opensolaris/ (props changed) stable/7/sys/contrib/dev/acpica/ (props changed) stable/7/sys/contrib/pf/ (props changed) Modified: stable/7/sys/kern/vfs_vnops.c ============================================================================== --- stable/7/sys/kern/vfs_vnops.c Fri Jan 22 14:44:15 2010 (r202810) +++ stable/7/sys/kern/vfs_vnops.c Fri Jan 22 15:12:01 2010 (r202811) @@ -377,15 +377,8 @@ vn_rdwr(rw, vp, base, len, offset, segfl lock_flags = LK_EXCLUSIVE; } vn_lock(vp, lock_flags | LK_RETRY, td); - } else { - /* - * XXX This should be LK_SHARED but the VFS in releng7 - * needs some patches before this can be done. - * The same applies to the lock_flags above and to a - * similar place below. - */ - vn_lock(vp, LK_EXCLUSIVE | LK_RETRY, td); - } + } else + vn_lock(vp, LK_SHARED | LK_RETRY, td); } ASSERT_VOP_LOCKED(vp, "IO_NODELOCKED with no vp lock held");