From: "H. Peter Anvin" Subject: Re: [Xen-devel] Re: [PATCH 06/16] xen: disable PAT Date: Sat, 09 May 2009 11:36:25 -0700 Message-ID: <4A05CD29.6050505@zytor.com> References: Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: Sender: linux-kernel-owner@vger.kernel.org To: Keir Fraser Cc: Alan Cox , Ian Campbell , Jeremy Fitzhardinge , the arch/x86 maintainers , Suresh Siddha , Linux@zytor.com, "Pallipadi, Venkatesh" , Kernel Mailing List , Jeremy Fitzhardinge , Xen-devel , Jan Beulich , Ingo Molnar , Lu , Thomas Gleixner , Arjan van de Ven List-Id: xen-devel@lists.xenproject.org Keir Fraser wrote: > > My suggestion is that Xen changes its PAT[1] from WT to WC. AFAIK only > suse's Linux port is currently using Xen's PAT support, and it does not > actually use the WT cache attribute. Then Xen's PAT[0-3] would match what > Linux expects, and Linux apparently does not risk using PAT[4-7] because of > processor errata so their values are irrelevant. Linux can check that it is > running on Xen with suitable PAT setup by reading MSR_IA32_CR_PAT and > checking PAT[0-3], and only enable PAT usage in case of a match. > There exists at least one processor erratum where the CPU will use PAT[4-7] when the user requested PAT[0-3]. For those CPUs, it is unsafe for *any* OS to have PAT[4-7] != PAT[0-3]. -hpa -- H. Peter Anvin, Intel Open Source Technology Center I work for Intel. I don't speak on their behalf.