Skip to content

x86/asm: Remove some static_cpu_has() usage

Borislav Petkov kvm linux-edac linux-pm lkml virtualization 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest5 patches 12 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/5x86/asm: Clarify static_cpu_has()'s intended usearch/x86/include/asm/cpufeature.h+6 -31 reply
2/5x86: Convert some slow-path static_cpu_has() callers to boot_cpu_has()arch/x86/include/asm/fpu/internal.h arch/x86/kernel/apic/apic_numachip.c arch/x86/kernel/cpu/aperfmperf.c +8 more+26 -273 replies
2/5x86: Convert some slow-path static_cpu_has() callers to boot_cpu_has()arch/x86/include/asm/fpu/internal.h arch/x86/kernel/apic/apic_numachip.c arch/x86/kernel/cpu/aperfmperf.c +8 more+26 -270 replies
3/5x86/kvm: Convert some slow-path static_cpu_has() callers to boot_cpu_has()arch/x86/kvm/svm.c arch/x86/kvm/vmx/vmx.c+7 -74 replies
4/5x86/mm: Convert some slow-path static_cpu_has() callers to boot_cpu_has()arch/x86/mm/dump_pagetables.c arch/x86/mm/pgtable.c arch/x86/mm/pti.c+5 -50 replies
5/5drivers/cpufreq: Convert some slow-path static_cpu_has() callers to boot_cpu_has()drivers/cpufreq/amd_freq_sensitivity.c drivers/cpufreq/intel_pstate.c drivers/cpufreq/powernow-k8.c+11 -114 replies

Reviews trailers per patch

3 of 6 patches have a Reviewed-by or Acked-by.

PatchNadav AmitRik van RielRafael J. Wysocki
1/5Requested-by
2/5R-b
2/5R-b
3/5
4/5
5/5A-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes. Scroll the table sideways for all 3 reviewers.

Read the v1 thread

Cover letter [PATCH 0/5] x86/asm: Remove some static_cpu_has() usage

From: Borislav Petkov <[email protected]>

Hi,

this came about after Nadav asked about static_cpu_has() and when it should be used. The resulting converts a bunch of slow-paths to use the plain boot_cpu_has() tester which is straight-forward and doesn't require to be patched in by alternatives, leaving static_cpu_has() only to the fast paths, where it should be used anyway.

Thx.

Borislav Petkov (5):
x86/asm: Clarify static_cpu_has()'s intended use
x86: Convert some slow-path static_cpu_has() callers to boot_cpu_has() x86/kvm: Convert some slow-path static_cpu_has() callers to

    boot_cpu_has()
  x86/mm: Convert some slow-path static_cpu_has() callers to
    boot_cpu_has()
  drivers/cpufreq: Convert some slow-path static_cpu_has() callers to
    boot_cpu_has()
 arch/x86/include/asm/cpufeature.h      |  9 ++++++---
 arch/x86/include/asm/fpu/internal.h    |  7 +++----
 arch/x86/kernel/apic/apic_numachip.c   |  2 +-
 arch/x86/kernel/cpu/aperfmperf.c       |  6 +++---
 arch/x86/kernel/cpu/common.c           |  2 +-
 arch/x86/kernel/cpu/mce/inject.c       |  2 +-
 arch/x86/kernel/cpu/proc.c             | 10 +++++-----
 arch/x86/kernel/ldt.c                  | 14 +++++++-------
 arch/x86/kernel/paravirt.c             |  2 +-
 arch/x86/kernel/process.c              |  4 ++--
 arch/x86/kernel/reboot.c               |  2 +-
 arch/x86/kernel/vm86_32.c              |  2 +-
 arch/x86/kvm/svm.c                     | 10 +++++-----
 arch/x86/kvm/vmx/vmx.c                 |  4 ++--
 arch/x86/mm/dump_pagetables.c          |  4 ++--
 arch/x86/mm/pgtable.c                  |  4 ++--
 arch/x86/mm/pti.c                      |  2 +-
 drivers/cpufreq/amd_freq_sensitivity.c |  2 +-
 drivers/cpufreq/intel_pstate.c         | 18 +++++++++---------
 drivers/cpufreq/powernow-k8.c          |  2 +-
 20 files changed, 55 insertions(+), 53 deletions(-)
Signature · 1 line
2.21.0