From owner-svn-src-user@FreeBSD.ORG Tue Apr 3 20:06:08 2012 Return-Path: Delivered-To: svn-src-user@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 89C64106564A; Tue, 3 Apr 2012 20:06:08 +0000 (UTC) (envelope-from attilio@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 769AB8FC0A; Tue, 3 Apr 2012 20:06:08 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q33K685x066587; Tue, 3 Apr 2012 20:06:08 GMT (envelope-from attilio@svn.freebsd.org) Received: (from attilio@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q33K68Dh066585; Tue, 3 Apr 2012 20:06:08 GMT (envelope-from attilio@svn.freebsd.org) Message-Id: <201204032006.q33K68Dh066585@svn.freebsd.org> From: Attilio Rao Date: Tue, 3 Apr 2012 20:06:08 +0000 (UTC) To: src-committers@freebsd.org, svn-src-user@freebsd.org X-SVN-Group: user MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r233852 - user/attilio/vmcontention/sys/vm X-BeenThere: svn-src-user@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the experimental " user" src tree" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 03 Apr 2012 20:06:08 -0000 Author: attilio Date: Tue Apr 3 20:06:07 2012 New Revision: 233852 URL: http://svn.freebsd.org/changeset/base/233852 Log: The cached_pages_counter is not reset even when shared pages are present if the obj is not a vnode. Fix this. Reported and tested by: flo Modified: user/attilio/vmcontention/sys/vm/vm_object.c Modified: user/attilio/vmcontention/sys/vm/vm_object.c ============================================================================== --- user/attilio/vmcontention/sys/vm/vm_object.c Tue Apr 3 19:34:00 2012 (r233851) +++ user/attilio/vmcontention/sys/vm/vm_object.c Tue Apr 3 20:06:07 2012 (r233852) @@ -784,9 +784,10 @@ vm_object_terminate(vm_object_t object) if (object->type == OBJT_VNODE) vdrop(object->handle); } - if (object->cached_page_count != 0 && object->type == OBJT_VNODE) { + if (object->cached_page_count != 0) { object->cached_page_count = 0; - vdrop(object->handle); + if (object->type == OBJT_VNODE) + vdrop(object->handle); } #if VM_NRESERVLEVEL > 0