[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Xen-changelog] [xen-4.0-testing] x86: No need for disable_tsc_sync when full 64-bit TSC cannot be written



# HG changeset patch
# User Keir Fraser <keir@xxxxxxx>
# Date 1303823715 -3600
# Node ID 8e17a5f35905586deb8bb63aeef87f3d63720c11
# Parent  8b5cb0931ec253aea589c74e7a71b17f9cd3868a
x86: No need for disable_tsc_sync when full 64-bit TSC cannot be written

During boot we only write zero to the TSCs, which is safe.

Signed-off-by: Keir Fraser <keir@xxxxxxx>
---


diff -r 8b5cb0931ec2 -r 8e17a5f35905 xen/arch/x86/smpboot.c
--- a/xen/arch/x86/smpboot.c    Tue Apr 26 14:12:26 2011 +0100
+++ b/xen/arch/x86/smpboot.c    Tue Apr 26 14:15:15 2011 +0100
@@ -172,12 +172,6 @@
  * then we print a warning if not, and always resync.
  */
 
-/*
- * TSC's upper 32 bits can't be written in earlier CPUs (before
- * Prescott), there is no way to resync one AP against BP.
- */
-bool_t disable_tsc_sync;
-
 static atomic_t tsc_start_flag = ATOMIC_INIT(0);
 static atomic_t tsc_count_start = ATOMIC_INIT(0);
 static atomic_t tsc_count_stop = ATOMIC_INIT(0);
@@ -194,9 +188,6 @@
        unsigned int one_usec;
        int buggy = 0;
 
-       if ( disable_tsc_sync )
-               return;
-
        if (boot_cpu_has(X86_FEATURE_TSC_RELIABLE)) {
                printk("TSC is reliable, synchronization unnecessary\n");
                return;
@@ -294,9 +285,6 @@
 {
        int i;
 
-       if ( disable_tsc_sync )
-               return;
-
        if (boot_cpu_has(X86_FEATURE_TSC_RELIABLE))
                return;
 
diff -r 8b5cb0931ec2 -r 8e17a5f35905 xen/arch/x86/time.c
--- a/xen/arch/x86/time.c       Tue Apr 26 14:12:26 2011 +0100
+++ b/xen/arch/x86/time.c       Tue Apr 26 14:15:15 2011 +0100
@@ -1473,9 +1473,6 @@
     /* cstate_restore_tsc() must not be used (or do nothing) */
     if ( !boot_cpu_has(X86_FEATURE_NONSTOP_TSC) )
         cpuidle_disable_deep_cstate();
-
-    /* synchronize_tsc_slave() must do nothing */
-    disable_tsc_sync = 1;
 }
 
 /* Late init function (after all CPUs are booted). */
diff -r 8b5cb0931ec2 -r 8e17a5f35905 xen/include/asm-x86/time.h
--- a/xen/include/asm-x86/time.h        Tue Apr 26 14:12:26 2011 +0100
+++ b/xen/include/asm-x86/time.h        Tue Apr 26 14:15:15 2011 +0100
@@ -27,8 +27,6 @@
 
 typedef u64 cycles_t;
 
-extern bool_t disable_tsc_sync;
-
 static inline cycles_t get_cycles(void)
 {
     cycles_t c;

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


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.