From owner-svn-src-user@freebsd.org Thu Oct 27 15:51:40 2016 Return-Path: Delivered-To: svn-src-user@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 6528FC230C7 for ; Thu, 27 Oct 2016 15:51:40 +0000 (UTC) (envelope-from alc@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 322D5DAA; Thu, 27 Oct 2016 15:51:40 +0000 (UTC) (envelope-from alc@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id u9RFpd1W051165; Thu, 27 Oct 2016 15:51:39 GMT (envelope-from alc@FreeBSD.org) Received: (from alc@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id u9RFpdNa051164; Thu, 27 Oct 2016 15:51:39 GMT (envelope-from alc@FreeBSD.org) Message-Id: <201610271551.u9RFpdNa051164@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: alc set sender to alc@FreeBSD.org using -f From: Alan Cox Date: Thu, 27 Oct 2016 15:51:39 +0000 (UTC) To: src-committers@freebsd.org, svn-src-user@freebsd.org Subject: svn commit: r308002 - user/alc/PQ_LAUNDRY/sys/vm X-SVN-Group: user MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-user@freebsd.org X-Mailman-Version: 2.1.23 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: Thu, 27 Oct 2016 15:51:40 -0000 Author: alc Date: Thu Oct 27 15:51:39 2016 New Revision: 308002 URL: https://svnweb.freebsd.org/changeset/base/308002 Log: It's already the case that we repurpose the variable "pq" over the course of vm_pageout_scan() to refer to both the inactive and active queues. Use it for the laundry queue as well. Modified: user/alc/PQ_LAUNDRY/sys/vm/vm_pageout.c Modified: user/alc/PQ_LAUNDRY/sys/vm/vm_pageout.c ============================================================================== --- user/alc/PQ_LAUNDRY/sys/vm/vm_pageout.c Thu Oct 27 14:21:54 2016 (r308001) +++ user/alc/PQ_LAUNDRY/sys/vm/vm_pageout.c Thu Oct 27 15:51:39 2016 (r308002) @@ -1265,7 +1265,7 @@ static bool vm_pageout_scan(struct vm_domain *vmd, int pass) { vm_page_t m, next; - struct vm_pagequeue *pq, *laundryq; + struct vm_pagequeue *pq; vm_object_t object; long min_scan; int act_delta, addl_page_shortage, deficit, inactq_shortage, maxscan; @@ -1494,15 +1494,15 @@ drop_page: */ if (vm_laundry_request == VM_LAUNDRY_IDLE && starting_page_shortage > 0) { - laundryq = &vm_dom[0].vmd_pagequeues[PQ_LAUNDRY]; - vm_pagequeue_lock(laundryq); + pq = &vm_dom[0].vmd_pagequeues[PQ_LAUNDRY]; + vm_pagequeue_lock(pq); if (page_shortage > 0) { vm_laundry_request = VM_LAUNDRY_SHORTFALL; PCPU_INC(cnt.v_pdshortfalls); } else if (vm_laundry_request != VM_LAUNDRY_SHORTFALL) vm_laundry_request = VM_LAUNDRY_BACKGROUND; wakeup(&vm_laundry_request); - vm_pagequeue_unlock(laundryq); + vm_pagequeue_unlock(pq); } #if !defined(NO_SWAPPING)