From owner-cvs-src-old@FreeBSD.ORG Sun May 31 14:58:37 2009 Return-Path: Delivered-To: cvs-src-old@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 0AF761065675 for ; Sun, 31 May 2009 14:58:37 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [IPv6:2001:4f8:fff6::29]) by mx1.freebsd.org (Postfix) with ESMTP id EC2988FC16 for ; Sun, 31 May 2009 14:58:36 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.14.3/8.14.3) with ESMTP id n4VEwaFS088863 for ; Sun, 31 May 2009 14:58:36 GMT (envelope-from kib@repoman.freebsd.org) Received: (from svn2cvs@localhost) by repoman.freebsd.org (8.14.3/8.14.3/Submit) id n4VEwaxq088862 for cvs-src-old@freebsd.org; Sun, 31 May 2009 14:58:36 GMT (envelope-from kib@repoman.freebsd.org) Message-Id: <200905311458.n4VEwaxq088862@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: svn2cvs set sender to kib@repoman.freebsd.org using -f From: Konstantin Belousov Date: Sun, 31 May 2009 14:57:43 +0000 (UTC) To: cvs-src-old@freebsd.org X-FreeBSD-CVS-Branch: HEAD Subject: cvs commit: src/sys/kern vfs_cache.c src/sys/sys vnode.h X-BeenThere: cvs-src-old@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: **OBSOLETE** CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 31 May 2009 14:58:37 -0000 kib 2009-05-31 14:57:43 UTC FreeBSD src repository Modified files: sys/kern vfs_cache.c sys/sys vnode.h Log: SVN rev 193174 on 2009-05-31 14:57:43Z by kib Eliminate code duplication in vn_fullpath1() around the cache lookups and calls to vn_vptocnp() by moving more of the common code to vn_vptocnp(). Rename vn_vptocnp() to vn_vptocnp_locked() to signify that cache is locked around the call. Do not track buffer position by both the pointer and offset, use only buflen to record the start of the free space. Export vn_vptocnp() for external consumers as a wrapper around vn_vptocnp_locked() that locks the cache and handles hold counts. Tested by: pho Revision Changes Path 1.155 +75 -85 src/sys/kern/vfs_cache.c 1.355 +1 -0 src/sys/sys/vnode.h