From owner-svn-src-all@FreeBSD.ORG Tue Jun 8 04:41:31 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 C87D4106567B; Tue, 8 Jun 2010 04:41:31 +0000 (UTC) (envelope-from alc@FreeBSD.org) Received: from svn.freebsd.org (unknown [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id B73268FC14; Tue, 8 Jun 2010 04:41:31 +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 o584fVsU092807; Tue, 8 Jun 2010 04:41:31 GMT (envelope-from alc@svn.freebsd.org) Received: (from alc@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id o584fVrG092805; Tue, 8 Jun 2010 04:41:31 GMT (envelope-from alc@svn.freebsd.org) Message-Id: <201006080441.o584fVrG092805@svn.freebsd.org> From: Alan Cox Date: Tue, 8 Jun 2010 04:41:31 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-8@freebsd.org X-SVN-Group: stable-8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r208903 - stable/8/sys/i386/i386 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: Tue, 08 Jun 2010 04:41:31 -0000 Author: alc Date: Tue Jun 8 04:41:31 2010 New Revision: 208903 URL: http://svn.freebsd.org/changeset/base/208903 Log: MFC r208765 In the unlikely event that pmap_ts_referenced() demoted five superpage mappings to the same underlying physical page, the calling thread would be left forever pinned to the same processor. Approved by: re (kib) Modified: stable/8/sys/i386/i386/pmap.c Modified: stable/8/sys/i386/i386/pmap.c ============================================================================== --- stable/8/sys/i386/i386/pmap.c Tue Jun 8 03:39:31 2010 (r208902) +++ stable/8/sys/i386/i386/pmap.c Tue Jun 8 04:41:31 2010 (r208903) @@ -4461,7 +4461,7 @@ pmap_ts_referenced(vm_page_t m) rtval++; if (rtval > 4) { PMAP_UNLOCK(pmap); - return (rtval); + goto out; } } } @@ -4490,6 +4490,7 @@ pmap_ts_referenced(vm_page_t m) PMAP_UNLOCK(pmap); } while ((pv = pvn) != NULL && pv != pvf); } +out: sched_unpin(); return (rtval); }