From owner-freebsd-current@FreeBSD.ORG Mon Sep 20 21:50:11 2004 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E840216A4D0 for ; Mon, 20 Sep 2004 21:50:11 +0000 (GMT) Received: from hanoi.cronyx.ru (hanoi.cronyx.ru [144.206.181.53]) by mx1.FreeBSD.org (Postfix) with ESMTP id 076F143D1D for ; Mon, 20 Sep 2004 21:50:11 +0000 (GMT) (envelope-from rik@cronyx.ru) Received: (from root@localhost) by hanoi.cronyx.ru id i8KLl5td065904 for freebsd-current@FreeBSD.org.checked; (8.12.8/vak/2.1) Tue, 21 Sep 2004 01:47:05 +0400 (MSD) (envelope-from rik@cronyx.ru) Received: from cronyx.ru (hanoi.cronyx.ru [144.206.181.53]) by hanoi.cronyx.ru with ESMTP id i8KLjuQM065830; (8.12.8/vak/2.1) Tue, 21 Sep 2004 01:45:56 +0400 (MSD) (envelope-from rik@cronyx.ru) Message-ID: <414F4DC6.9020509@cronyx.ru> Date: Tue, 21 Sep 2004 01:38:14 +0400 From: Roman Kurakin User-Agent: Mozilla/5.0 (X11; U; Linux i686; ru-RU; rv:1.2.1) Gecko/20030426 X-Accept-Language: ru-ru, en MIME-Version: 1.0 To: Nate Lawson References: <41421D6A.8070805@cronyx.ru> <414E7581.2070505@root.org> <414F256B.1030304@cronyx.ru> <200409201652.24457.jhb@FreeBSD.org> <414F4CF2.2050404@root.org> In-Reply-To: <414F4CF2.2050404@root.org> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit cc: Roman Kurakin cc: FreeBSD Current cc: John Baldwin Subject: Re: mp_machdep.c (was Re: [Fwd: Re: Bug reports requested - acpi]) X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 20 Sep 2004 21:50:12 -0000 Nate Lawson: > John Baldwin wrote: > >> It's probably cleaner to use pmap_invalidate_range(). Something like: >> >> Index: mp_machdep.c >> =================================================================== >> RCS file: /usr/cvs/src/sys/i386/i386/mp_machdep.c,v >> retrieving revision 1.238 >> diff -u -r1.238 mp_machdep.c >> --- mp_machdep.c 1 Sep 2004 06:42:01 -0000 1.238 >> +++ mp_machdep.c 20 Sep 2004 20:50:35 -0000 >> @@ -738,15 +738,19 @@ >> int x; >> int size = *(int *) ((u_long) & bootMP_size); >> u_char *src = (u_char *) ((u_long) bootMP); >> - u_char *dst = (u_char *) boot_address + KERNBASE; >> + u_char *dst; >> u_int boot_base = (u_int) bootMP; >> u_int8_t *dst8; >> u_int16_t *dst16; >> u_int32_t *dst32; >> + vm_offset_t va; >> >> POSTCODE(INSTALL_AP_TRAMP_POST); >> >> - pmap_kenter(boot_address + KERNBASE, boot_address); >> + va = boot_address + KERNBASE; >> + pmap_kenter(va, boot_address); >> + pmap_invalidate_range(kernel_pmap, va, va + size); >> + dst = (u_char *)va; >> for (x = 0; x < size; ++x) >> *dst++ = *src++; >> >> It seems odd that this is needed though. Does it go away if you use >> DISABLE_PSE or DISABLE_PGE? > > He's on a Pentium 2 or something. Yes, it is PII. You want to tell that these settings shouldn't affect? (I don't know much about these features.) rik