public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] x86: process fam 10h like k8 with fixed mtrr setting
@ 2008-05-05 22:57 Yinghai Lu
  2008-05-06 12:40 ` Ingo Molnar
  2008-05-20 12:54 ` Pavel Machek
  0 siblings, 2 replies; 4+ messages in thread
From: Yinghai Lu @ 2008-05-05 22:57 UTC (permalink / raw)
  To: Ingo Molnar, H. Peter Anvin, Thomas Gleixner, Andrew Morton
  Cc: linux-kernel@vger.kernel.org


otherwise fixed MTRR for family 10h may not be changed

Signed-off-by: Yinghai Lu <yhlu.kernel@gmail.com>

Index: linux-2.6/arch/x86/kernel/cpu/mtrr/generic.c
===================================================================
--- linux-2.6.orig/arch/x86/kernel/cpu/mtrr/generic.c
+++ linux-2.6/arch/x86/kernel/cpu/mtrr/generic.c
@@ -342,7 +342,7 @@ static void set_fixed_range(int msr, boo
 
 	if (lo != msrwords[0] || hi != msrwords[1]) {
 		if (boot_cpu_data.x86_vendor == X86_VENDOR_AMD &&
-		    boot_cpu_data.x86 == 15 &&
+		    (boot_cpu_data.x86 >= 0x0f && boot_cpu_data.x86 <= 0x11) &&
 		    ((msrwords[0] | msrwords[1]) & K8_MTRR_RDMEM_WRMEM_MASK))
 			k8_enable_fixed_iorrs();
 		mtrr_wrmsr(msr, msrwords[0], msrwords[1]);

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] x86: process fam 10h like k8 with fixed mtrr setting
  2008-05-05 22:57 [PATCH] x86: process fam 10h like k8 with fixed mtrr setting Yinghai Lu
@ 2008-05-06 12:40 ` Ingo Molnar
  2008-05-20 12:54 ` Pavel Machek
  1 sibling, 0 replies; 4+ messages in thread
From: Ingo Molnar @ 2008-05-06 12:40 UTC (permalink / raw)
  To: yhlu.kernel
  Cc: H. Peter Anvin, Thomas Gleixner, Andrew Morton,
	linux-kernel@vger.kernel.org


* Yinghai Lu <yhlu.kernel.send@gmail.com> wrote:

> otherwise fixed MTRR for family 10h may not be changed

applied, thanks.

	Ingo

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] x86: process fam 10h like k8 with fixed mtrr setting
  2008-05-05 22:57 [PATCH] x86: process fam 10h like k8 with fixed mtrr setting Yinghai Lu
  2008-05-06 12:40 ` Ingo Molnar
@ 2008-05-20 12:54 ` Pavel Machek
  2008-05-20 17:24   ` Yinghai Lu
  1 sibling, 1 reply; 4+ messages in thread
From: Pavel Machek @ 2008-05-20 12:54 UTC (permalink / raw)
  To: yhlu.kernel
  Cc: Ingo Molnar, H. Peter Anvin, Thomas Gleixner, Andrew Morton,
	linux-kernel@vger.kernel.org

On Mon 2008-05-05 15:57:38, Yinghai Lu wrote:
> 
> otherwise fixed MTRR for family 10h may not be changed
> 
> Signed-off-by: Yinghai Lu <yhlu.kernel@gmail.com>
> 
> Index: linux-2.6/arch/x86/kernel/cpu/mtrr/generic.c
> ===================================================================
> --- linux-2.6.orig/arch/x86/kernel/cpu/mtrr/generic.c
> +++ linux-2.6/arch/x86/kernel/cpu/mtrr/generic.c
> @@ -342,7 +342,7 @@ static void set_fixed_range(int msr, boo
>  
>  	if (lo != msrwords[0] || hi != msrwords[1]) {
>  		if (boot_cpu_data.x86_vendor == X86_VENDOR_AMD &&
> -		    boot_cpu_data.x86 == 15 &&
> +		    (boot_cpu_data.x86 >= 0x0f && boot_cpu_data.x86 <= 0x11) &&
>  		    ((msrwords[0] | msrwords[1]) & K8_MTRR_RDMEM_WRMEM_MASK))
>  			k8_enable_fixed_iorrs();
>  		mtrr_wrmsr(msr, msrwords[0], msrwords[1]);

This also changes family 0x11. Is that ok?

-- 
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] x86: process fam 10h like k8 with fixed mtrr setting
  2008-05-20 12:54 ` Pavel Machek
@ 2008-05-20 17:24   ` Yinghai Lu
  0 siblings, 0 replies; 4+ messages in thread
From: Yinghai Lu @ 2008-05-20 17:24 UTC (permalink / raw)
  To: Pavel Machek
  Cc: Ingo Molnar, H. Peter Anvin, Thomas Gleixner, Andrew Morton,
	linux-kernel@vger.kernel.org

On Tue, May 20, 2008 at 5:54 AM, Pavel Machek <pavel@ucw.cz> wrote:
> On Mon 2008-05-05 15:57:38, Yinghai Lu wrote:
>>
>> otherwise fixed MTRR for family 10h may not be changed
>>
>> Signed-off-by: Yinghai Lu <yhlu.kernel@gmail.com>
>>
>> Index: linux-2.6/arch/x86/kernel/cpu/mtrr/generic.c
>> ===================================================================
>> --- linux-2.6.orig/arch/x86/kernel/cpu/mtrr/generic.c
>> +++ linux-2.6/arch/x86/kernel/cpu/mtrr/generic.c
>> @@ -342,7 +342,7 @@ static void set_fixed_range(int msr, boo
>>
>>       if (lo != msrwords[0] || hi != msrwords[1]) {
>>               if (boot_cpu_data.x86_vendor == X86_VENDOR_AMD &&
>> -                 boot_cpu_data.x86 == 15 &&
>> +                 (boot_cpu_data.x86 >= 0x0f && boot_cpu_data.x86 <= 0x11) &&
>>                   ((msrwords[0] | msrwords[1]) & K8_MTRR_RDMEM_WRMEM_MASK))
>>                       k8_enable_fixed_iorrs();
>>               mtrr_wrmsr(msr, msrwords[0], msrwords[1]);
>
> This also changes family 0x11. Is that ok?

Yes.

YH

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2008-05-20 17:25 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-05-05 22:57 [PATCH] x86: process fam 10h like k8 with fixed mtrr setting Yinghai Lu
2008-05-06 12:40 ` Ingo Molnar
2008-05-20 12:54 ` Pavel Machek
2008-05-20 17:24   ` Yinghai Lu

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox