From owner-p4-projects@FreeBSD.ORG Sat Jul 1 00:58:19 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 9217E16A47B; Sat, 1 Jul 2006 00:58:19 +0000 (UTC) X-Original-To: perforce@freebsd.org Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 55CCF16A417 for ; Sat, 1 Jul 2006 00:58:19 +0000 (UTC) (envelope-from kmacy@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id B795A43D45 for ; Sat, 1 Jul 2006 00:58:18 +0000 (GMT) (envelope-from kmacy@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k610wIk6009105 for ; Sat, 1 Jul 2006 00:58:18 GMT (envelope-from kmacy@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k610wI85009102 for perforce@freebsd.org; Sat, 1 Jul 2006 00:58:18 GMT (envelope-from kmacy@freebsd.org) Date: Sat, 1 Jul 2006 00:58:18 GMT Message-Id: <200607010058.k610wI85009102@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to kmacy@freebsd.org using -f From: Kip Macy To: Perforce Change Reviews Cc: Subject: PERFORCE change 100374 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 01 Jul 2006 00:58:19 -0000 http://perforce.freebsd.org/chv.cgi?CH=100374 Change 100374 by kmacy@kmacy_storage:sun4v_work_stable on 2006/07/01 00:57:47 don't use memory ranges less than 4M Affected files ... .. //depot/projects/kmacy_sun4v_stable/src/sys/sun4v/sun4v/pmap.c#4 edit Differences ... ==== //depot/projects/kmacy_sun4v_stable/src/sys/sun4v/sun4v/pmap.c#4 (text+ko) ==== @@ -694,6 +694,12 @@ pa | TTE_KERNEL | VTD_4M, 0); } + for (i = 0; i < 2; i++) { + pa = nucleus_mappings[i]; + tsb_set_tte_real(&kernel_td[TSB4M_INDEX], TLB_PHYS_TO_DIRECT(pa), + pa | TTE_KERNEL | VTD_4M, 0); + + } /* * Get the available physical memory ranges from /memory/reg. These * are only used for kernel dumps, but it may not be wise to do prom @@ -761,6 +767,10 @@ tte_hash_insert(pm->pm_hash, TLB_PHYS_TO_DIRECT(pa), pa | TTE_KERNEL | VTD_4M); #endif + /* XXX relies on the fact that memory ranges only get smaller */ + for (i = 0; phys_avail[i + 2] != 0; i += 2) + if (phys_avail[i + 1] - phys_avail[i] < PAGE_SIZE_4M) + phys_avail[i] = phys_avail[i+1] = 0; }