diff options
Diffstat (limited to 'arch/x86/kernel/tsc.c')
-rw-r--r-- | arch/x86/kernel/tsc.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/arch/x86/kernel/tsc.c b/arch/x86/kernel/tsc.c index 4b9ea101fe3b..098b3cfda72e 100644 --- a/arch/x86/kernel/tsc.c +++ b/arch/x86/kernel/tsc.c | |||
@@ -768,7 +768,8 @@ static cycle_t read_tsc(struct clocksource *cs) | |||
768 | 768 | ||
769 | static void resume_tsc(struct clocksource *cs) | 769 | static void resume_tsc(struct clocksource *cs) |
770 | { | 770 | { |
771 | clocksource_tsc.cycle_last = 0; | 771 | if (!boot_cpu_has(X86_FEATURE_NONSTOP_TSC_S3)) |
772 | clocksource_tsc.cycle_last = 0; | ||
772 | } | 773 | } |
773 | 774 | ||
774 | static struct clocksource clocksource_tsc = { | 775 | static struct clocksource clocksource_tsc = { |
@@ -939,6 +940,9 @@ static int __init init_tsc_clocksource(void) | |||
939 | clocksource_tsc.flags &= ~CLOCK_SOURCE_IS_CONTINUOUS; | 940 | clocksource_tsc.flags &= ~CLOCK_SOURCE_IS_CONTINUOUS; |
940 | } | 941 | } |
941 | 942 | ||
943 | if (boot_cpu_has(X86_FEATURE_NONSTOP_TSC_S3)) | ||
944 | clocksource_tsc.flags |= CLOCK_SOURCE_SUSPEND_NONSTOP; | ||
945 | |||
942 | /* | 946 | /* |
943 | * Trust the results of the earlier calibration on systems | 947 | * Trust the results of the earlier calibration on systems |
944 | * exporting a reliable TSC. | 948 | * exporting a reliable TSC. |