All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] A workaround for AMD erratum 411
@ 2010-06-04 11:33 Wei Wang2
  2010-06-04 12:31 ` Keir Fraser
  0 siblings, 1 reply; 2+ messages in thread
From: Wei Wang2 @ 2010-06-04 11:33 UTC (permalink / raw)
  To: xen-devel@lists.xensource.com

[-- Attachment #1: Type: text/plain, Size: 721 bytes --]

Hi,
This patch is a workaround of AMD erratum 411 for family 10h CPUs. This does 
not cause functional issues but may reduce the power saving effectiveness of 
message-triggered C1e mode. This would normally occur only if OS which has 
used the local APIC timer masks the interrupt without clearing Timer Initial 
Count Register.

Thanks,
Wei

Signed-off-by: Wei Wang <wei.wang2@amd.com>
-- 
AMD GmbH, Germany
Operating System Research Center

Legal Information:
Advanced Micro Devices GmbH
Karl-Hammerschmidt-Str. 34
85609 Dornach b. München

Geschäftsführer: Andrew Bowd, Thomas M. McCoy, Giuliano Meroni
Sitz: Dornach, Gemeinde Aschheim, Landkreis München
Registergericht München, HRB Nr. 43632

[-- Attachment #2: erratum411.patch --]
[-- Type: text/x-diff, Size: 882 bytes --]

diff -r e6f751ed8e38 xen/arch/x86/apic.c
--- a/xen/arch/x86/apic.c	Tue Mar 09 10:00:37 2010 +0000
+++ b/xen/arch/x86/apic.c	Fri May 28 12:28:22 2010 +0200
@@ -209,6 +209,11 @@ void clear_local_APIC(void)
      */
     v = apic_read(APIC_LVTT);
     apic_write_around(APIC_LVTT, v | APIC_LVT_MASKED);
+
+    /* Workaround AMD Erratum 411. Please refer to AMD
+    revision guide for more details. */
+    apic_write_around(APIC_TMICT, 0x0);
+
     v = apic_read(APIC_LVT0);
     apic_write_around(APIC_LVT0, v | APIC_LVT_MASKED);
     v = apic_read(APIC_LVT1);
@@ -1187,6 +1192,10 @@ void disable_APIC_timer(void)
         
         v = apic_read(APIC_LVTT);
         apic_write_around(APIC_LVTT, v | APIC_LVT_MASKED);
+
+        /* Workaround AMD Erratum 411. Please refer to AMD
+        revision guide for more details. */
+        apic_write_around(APIC_TMICT, 0x0);
     }
 }
 

[-- Attachment #3: Type: text/plain, Size: 138 bytes --]

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

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

end of thread, other threads:[~2010-06-04 12:31 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-06-04 11:33 [PATCH] A workaround for AMD erratum 411 Wei Wang2
2010-06-04 12:31 ` Keir Fraser

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.