WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-changelog

[Xen-changelog] [xen-4.1-testing] x86, amd, MTRR: remove k8_enable_fixed

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-4.1-testing] x86, amd, MTRR: remove k8_enable_fixed_iorrs()
From: Xen patchbot-4.1-testing <patchbot@xxxxxxx>
Date: Fri, 08 Apr 2011 16:35:12 +0100
Delivery-date: Fri, 08 Apr 2011 08:35:47 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-changelog-request@lists.xensource.com?subject=help>
List-id: BK change log <xen-changelog.lists.xensource.com>
List-post: <mailto:xen-changelog@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=unsubscribe>
Reply-to: xen-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
# HG changeset patch
# User Wei Huang <wei.huang2@xxxxxxx>
# Date 1302186126 -3600
# Node ID 6b9cca2fc3df4da5de643619a6d20f7e43449a2f
# Parent  4db893357babd205f04db1c45a517fb5836d1c9b
x86, amd, MTRR: remove k8_enable_fixed_iorrs()

AMD64 defines two special bits (bit 3 and 4) RdMem and WrMem in fixed
MTRR type. Their values are supposed to be 0 after BIOS hands the
control to OS according to AMD BKDG. Unless OS specificially turn them
on, they are kept 0 all the time. As a result, k8_enable_fixed_iorrs()
is unnecessary and removed from upstream kernel (see
https://patchwork.kernel.org/patch/11425/). This patch does the same
thing.

Signed-off-by: Wei Huang <wei.huang2@xxxxxxx>
xen-unstable changeset:   23154:42fa70e0761b
xen-unstable date:        Wed Apr 06 09:02:13 2011 +0100
---


diff -r 4db893357bab -r 6b9cca2fc3df xen/arch/x86/cpu/mtrr/generic.c
--- a/xen/arch/x86/cpu/mtrr/generic.c   Thu Apr 07 15:21:41 2011 +0100
+++ b/xen/arch/x86/cpu/mtrr/generic.c   Thu Apr 07 15:22:06 2011 +0100
@@ -116,20 +116,6 @@
 }
 
 /**
- * Enable and allow read/write of extended fixed-range MTRR bits on K8 CPUs
- * see AMD publication no. 24593, chapter 3.2.1 for more information
- */
-static inline void k8_enable_fixed_iorrs(void)
-{
-       uint64_t msr_content;
-
-       rdmsrl(MSR_K8_SYSCFG, msr_content);
-       mtrr_wrmsr(MSR_K8_SYSCFG, msr_content 
-                               | K8_MTRRFIXRANGE_DRAM_ENABLE
-                               | K8_MTRRFIXRANGE_DRAM_MODIFY);
-}
-
-/**
  * Checks and updates an fixed-range MTRR if it differs from the value it
  * should have. If K8 extenstions are wanted, update the K8 SYSCFG MSR also.
  * see AMD publication no. 24593, chapter 7.8.1, page 233 for more information
@@ -145,10 +131,6 @@
        val = ((uint64_t)msrwords[1] << 32) | msrwords[0];
 
        if (msr_content != val) {
-               if (boot_cpu_data.x86_vendor == X86_VENDOR_AMD &&
-                   boot_cpu_data.x86 == 15 &&
-                   ((msrwords[0] | msrwords[1]) & K8_MTRR_RDMEM_WRMEM_MASK))
-                       k8_enable_fixed_iorrs();
                mtrr_wrmsr(msr, val);
                *changed = TRUE;
        }

_______________________________________________
Xen-changelog mailing list
Xen-changelog@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-changelog

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] [xen-4.1-testing] x86, amd, MTRR: remove k8_enable_fixed_iorrs(), Xen patchbot-4 . 1-testing <=