Date: Mon, 20 Sep 2004 17:48:23 -0400 From: John Baldwin <jhb@FreeBSD.org> To: Nate Lawson <nate@root.org> Cc: Roman Kurakin <rik@cronyx.ru> Subject: Re: mp_machdep.c (was Re: [Fwd: Re: Bug reports requested - acpi]) Message-ID: <200409201748.23097.jhb@FreeBSD.org> In-Reply-To: <414F4CF2.2050404@root.org> References: <41421D6A.8070805@cronyx.ru> <200409201652.24457.jhb@FreeBSD.org> <414F4CF2.2050404@root.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Monday 20 September 2004 05:34 pm, Nate Lawson wrote: > 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. PSE was introduced on the original Pentium and even on some 486's (I had a 486dx4/100 that had PSE). PGE is present on Pentium II's as well I think. -- John Baldwin <jhb@FreeBSD.org> <>< http://www.FreeBSD.org/~jhb/ "Power Users Use the Power to Serve" = http://www.FreeBSD.org
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200409201748.23097.jhb>