From owner-svn-src-stable-8@FreeBSD.ORG Thu Jan 6 13:09:03 2011 Return-Path: Delivered-To: svn-src-stable-8@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 50F9C1065695; Thu, 6 Jan 2011 13:09:03 +0000 (UTC) (envelope-from cperciva@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 3FDBB8FC14; Thu, 6 Jan 2011 13:09:03 +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 p06D93vE015769; Thu, 6 Jan 2011 13:09:03 GMT (envelope-from cperciva@svn.freebsd.org) Received: (from cperciva@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id p06D93DG015767; Thu, 6 Jan 2011 13:09:03 GMT (envelope-from cperciva@svn.freebsd.org) Message-Id: <201101061309.p06D93DG015767@svn.freebsd.org> From: Colin Percival Date: Thu, 6 Jan 2011 13:09:03 +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: r217052 - stable/8/sys/i386/xen X-BeenThere: svn-src-stable-8@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for only the 8-stable src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 06 Jan 2011 13:09:03 -0000 Author: cperciva Date: Thu Jan 6 13:09:02 2011 New Revision: 217052 URL: http://svn.freebsd.org/changeset/base/217052 Log: MFC r216762: Don't panic when exiting gstat or 'mdconfig -l' Modified: stable/8/sys/i386/xen/pmap.c Directory Properties: stable/8/sys/ (props changed) stable/8/sys/amd64/include/xen/ (props changed) stable/8/sys/cddl/contrib/opensolaris/ (props changed) stable/8/sys/contrib/dev/acpica/ (props changed) stable/8/sys/contrib/pf/ (props changed) Modified: stable/8/sys/i386/xen/pmap.c ============================================================================== --- stable/8/sys/i386/xen/pmap.c Thu Jan 6 13:02:29 2011 (r217051) +++ stable/8/sys/i386/xen/pmap.c Thu Jan 6 13:09:02 2011 (r217052) @@ -2293,19 +2293,8 @@ pmap_remove_pte(pmap_t pmap, pt_entry_t if (oldpte & PG_G) pmap_invalidate_page(kernel_pmap, va); pmap->pm_stats.resident_count -= 1; - /* - * XXX This is not strictly correctly, but somewhere along the line - * we are losing the managed bit on some pages. It is unclear to me - * why, but I think the most likely explanation is that xen's writable - * page table implementation doesn't respect the unused bits. - */ - if ((oldpte & PG_MANAGED) || ((oldpte & PG_V) && (va < VM_MAXUSER_ADDRESS)) - ) { + if (oldpte & PG_MANAGED) { m = PHYS_TO_VM_PAGE(xpmap_mtop(oldpte) & PG_FRAME); - - if (!(oldpte & PG_MANAGED)) - printf("va=0x%x is unmanaged :-( pte=0x%llx\n", va, oldpte); - if (oldpte & PG_M) { KASSERT((oldpte & PG_RW), ("pmap_remove_pte: modified page not writable: va: %#x, pte: %#jx", @@ -2315,9 +2304,7 @@ pmap_remove_pte(pmap_t pmap, pt_entry_t if (oldpte & PG_A) vm_page_flag_set(m, PG_REFERENCED); pmap_remove_entry(pmap, m, va); - } else if ((va < VM_MAXUSER_ADDRESS) && (oldpte & PG_V)) - printf("va=0x%x is unmanaged :-( pte=0x%llx\n", va, oldpte); - + } return (pmap_unuse_pt(pmap, va, free)); }