From 16b0e3313f53566481c106ace9992e477f8efe9b Mon Sep 17 00:00:00 2001 From: Adrian Calianu Date: Mon, 22 May 2017 08:43:50 +0200 Subject: patches: Boot time optimizations with ClearLinux patches Signed-off-by: Adrian Calianu Signed-off-by: Adrian Dudau --- .../0116-smpboot-reuse-timer-calibration.patch | 31 ++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 patches/boot_time_opt/0116-smpboot-reuse-timer-calibration.patch (limited to 'patches/boot_time_opt/0116-smpboot-reuse-timer-calibration.patch') diff --git a/patches/boot_time_opt/0116-smpboot-reuse-timer-calibration.patch b/patches/boot_time_opt/0116-smpboot-reuse-timer-calibration.patch new file mode 100644 index 0000000..d1f71b5 --- /dev/null +++ b/patches/boot_time_opt/0116-smpboot-reuse-timer-calibration.patch @@ -0,0 +1,31 @@ +From 16104411cc5a7b20f310e3ecede85343ee6ce6b9 Mon Sep 17 00:00:00 2001 +From: Arjan van de Ven +Date: Wed, 11 Feb 2015 17:28:14 -0600 +Subject: [PATCH 116/124] smpboot: reuse timer calibration + +NO point recalibrating for known-constant tsc... saves 200ms+ of boot time. + +Author: Arjan van de Ven + +Signed-off-by: Miguel Bernal Marin +--- + arch/x86/kernel/tsc.c | 3 +++ + 1 file changed, 3 insertions(+) + +diff --git a/arch/x86/kernel/tsc.c b/arch/x86/kernel/tsc.c +index 46b2f41f8b05..88553c1f21f1 100644 +--- a/arch/x86/kernel/tsc.c ++++ b/arch/x86/kernel/tsc.c +@@ -1384,6 +1384,9 @@ unsigned long calibrate_delay_is_known(void) + if (!tsc_disabled && !cpu_has(&cpu_data(cpu), X86_FEATURE_CONSTANT_TSC)) + return 0; + ++ if (cpu != 0) ++ return cpu_data(0).loops_per_jiffy; ++ + if (!mask) + return 0; + +-- +2.11.1 + -- cgit v1.2.3-54-g00ecf