From c4bd5f6e084a6ced2c7a2f76798d0a34947ffeb7 Mon Sep 17 00:00:00 2001 From: Martin Borg Date: Fri, 23 Mar 2018 14:01:03 +0100 Subject: boot_time_opt: update host boot time optimization patches for 4.14 The new patches are based on: https://github.com/clearlinux-pkgs/linux-lts commit 5595fe425a52af6734235a1a953b6b03210060ec Signed-off-by: Martin Borg Signed-off-by: Adrian Dudau --- .../0114-smpboot-reuse-timer-calibration.patch | 31 ++++++++++++++++++++++ 1 file changed, 31 insertions(+) create mode 100644 patches/boot_time_opt/0114-smpboot-reuse-timer-calibration.patch (limited to 'patches/boot_time_opt/0114-smpboot-reuse-timer-calibration.patch') diff --git a/patches/boot_time_opt/0114-smpboot-reuse-timer-calibration.patch b/patches/boot_time_opt/0114-smpboot-reuse-timer-calibration.patch new file mode 100644 index 0000000..5fe8cdf --- /dev/null +++ b/patches/boot_time_opt/0114-smpboot-reuse-timer-calibration.patch @@ -0,0 +1,31 @@ +From 283fcb879f66da9659f1983bcf173476bae9292b Mon Sep 17 00:00:00 2001 +From: Arjan van de Ven +Date: Wed, 11 Feb 2015 17:28:14 -0600 +Subject: [PATCH 114/126] 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 ad2b925a808e..6aed4e79f290 100644 +--- a/arch/x86/kernel/tsc.c ++++ b/arch/x86/kernel/tsc.c +@@ -1352,6 +1352,9 @@ unsigned long calibrate_delay_is_known(void) + if (tsc_disabled || !constant_tsc || !mask) + return 0; + ++ if (cpu != 0) ++ return cpu_data(0).loops_per_jiffy; ++ + sibling = cpumask_any_but(mask, cpu); + if (sibling < nr_cpu_ids) + return cpu_data(sibling).loops_per_jiffy; +-- +2.15.0 + -- cgit v1.2.3-54-g00ecf