Re: [PATCH] x86: fixed mtrr change WP to WB

From: Yinghai Lu
Date: Tue May 06 2008 - 14:24:24 EST


On Tue, May 6, 2008 at 10:48 AM, H. Peter Anvin <hpa@xxxxxxxxx> wrote:
> Yinghai Lu wrote:
>
> > [PATCH] x86: fixed mtrr change WP to WB
> >
> > so we modify mptable near below 1M
> >
> > Signed-off-by: Yinghai Lu <yhlu.kernel@xxxxxxxxx>
> >
>
> Again:
>
> This does not work on even the majority of all systems.
>
> If the mptable should be modified, it should be copied to kernel memory and
> modified there. Modifying it in-place is both unsafe and, in general,
> simply will not work.

but

* 1) Scan the bottom 1K for a signature
* 2) Scan the top 1K of base RAM
* 3) Scan the 64K of bios
*/
if (smp_scan_config(0x0, 0x400, reserve) ||
smp_scan_config(639 * 0x400, 0x400, reserve) ||
smp_scan_config(0xF0000, 0x10000, reserve))
return;

and all these areas are reserved already.

wonder if we could only modify mpf->mpf_physptr to point to another
mpc and reuse mpf?

YH
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/