From owner-cvs-src@FreeBSD.ORG Wed Sep 29 19:20:40 2004 Return-Path: Delivered-To: cvs-src@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 7675616A4CE; Wed, 29 Sep 2004 19:20:40 +0000 (GMT) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id 6B37743D4C; Wed, 29 Sep 2004 19:20:40 +0000 (GMT) (envelope-from alc@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.12.11/8.12.11) with ESMTP id i8TJKeE1089720; Wed, 29 Sep 2004 19:20:40 GMT (envelope-from alc@repoman.freebsd.org) Received: (from alc@localhost) by repoman.freebsd.org (8.12.11/8.12.11/Submit) id i8TJKecC089719; Wed, 29 Sep 2004 19:20:40 GMT (envelope-from alc) Message-Id: <200409291920.i8TJKecC089719@repoman.freebsd.org> From: Alan Cox Date: Wed, 29 Sep 2004 19:20:40 +0000 (UTC) To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org X-FreeBSD-CVS-Branch: HEAD Subject: cvs commit: src/sys/amd64/amd64 pmap.c src/sys/amd64/include pmap.h src/sys/i386/i386 pmap.c src/sys/i386/include pmap.h X-BeenThere: cvs-src@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 29 Sep 2004 19:20:40 -0000 alc 2004-09-29 19:20:40 UTC FreeBSD src repository Modified files: sys/amd64/amd64 pmap.c sys/amd64/include pmap.h sys/i386/i386 pmap.c sys/i386/include pmap.h Log: Prevent the unexpected deallocation of a page table page while performing pmap_copy(). This entails additional locking in pmap_copy() and the addition of a "flags" parameter to the page table page allocator for specifying whether it may sleep when memory is unavailable. (Already, pmap_copy() checks the availability of memory, aborting if it is scarce. In theory, another CPU could, however, allocate memory between pmap_copy()'s check and the call to the page table page allocator, causing the current thread to release its locks and sleep. This change makes this scenario impossible.) Reviewed by: tegge@ Revision Changes Path 1.503 +44 -21 src/sys/amd64/amd64/pmap.c 1.124 +1 -1 src/sys/amd64/include/pmap.h 1.509 +38 -18 src/sys/i386/i386/pmap.c 1.114 +1 -1 src/sys/i386/include/pmap.h