linux_dsm_epyc7002/arch/x86/kernel/cpu
Brian Gerst 2476f2fa20 x86/alternatives: Discard dynamic check after init
Move the code to do the dynamic check to the altinstr_aux
section so that it is discarded after alternatives have run and
a static branch has been chosen.

This way we're changing the dynamic branch from C code to
assembly, which makes it *substantially* smaller while avoiding
a completely unnecessary call to an out of line function.

Signed-off-by: Brian Gerst <brgerst@gmail.com>
[ Changed it to do TESTB, as hpa suggested. ]
Signed-off-by: Borislav Petkov <bp@suse.de>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: Andy Lutomirski <luto@amacapital.net>
Cc: Andy Lutomirski <luto@kernel.org>
Cc: Boris Ostrovsky <boris.ostrovsky@oracle.com>
Cc: Borislav Petkov <bp@alien8.de>
Cc: Dave Young <dyoung@redhat.com>
Cc: Denys Vlasenko <dvlasenk@redhat.com>
Cc: H. Peter Anvin <hpa@zytor.com>
Cc: Kristen Carlson Accardi <kristen@linux.intel.com>
Cc: Laura Abbott <labbott@fedoraproject.org>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Peter Zijlstra (Intel) <peterz@infradead.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Prarit Bhargava <prarit@redhat.com>
Cc: Ross Zwisler <ross.zwisler@linux.intel.com>
Cc: Thomas Gleixner <tglx@linutronix.de>
Link: http://lkml.kernel.org/r/1452972124-7380-1-git-send-email-brgerst@gmail.com
Link: http://lkml.kernel.org/r/20160127084525.GC30712@pd.tnic
Signed-off-by: Ingo Molnar <mingo@kernel.org>
2016-01-30 11:22:22 +01:00
..
mcheck Merge branch 'ras-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip 2016-01-11 15:07:19 -08:00
microcode Merge branch 'x86-cpu-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip 2016-01-11 16:46:20 -08:00
mtrr x86/cpufeature: Carve out X86_FEATURE_* 2016-01-30 11:22:17 +01:00
.gitignore
amd.c x86/cpu/amd: Remove an unneeded condition in srat_detect_node() 2016-01-14 09:46:00 +01:00
bugs_64.c
bugs.c x86/fpu: Move various internal function prototypes to fpu/internal.h 2015-05-19 15:47:48 +02:00
centaur.c x86/cpufeature: Carve out X86_FEATURE_* 2016-01-30 11:22:17 +01:00
common.c x86/alternatives: Discard dynamic check after init 2016-01-30 11:22:22 +01:00
cpu.h x86/cpu: Restore MSR_IA32_ENERGY_PERF_BIAS after resume 2015-07-21 07:51:38 +02:00
cyrix.c x86/cpufeature: Carve out X86_FEATURE_* 2016-01-30 11:22:17 +01:00
hypervisor.c hypervisor/x86/xen: Unset X86_BUG_SYSRET_SS_ATTRS on Xen PV guests 2015-05-05 18:27:43 +01:00
intel_cacheinfo.c x86/cpufeature: Carve out X86_FEATURE_* 2016-01-30 11:22:17 +01:00
intel_pt.h perf/x86/intel/pt: Clean up files of Intel Processor Trace 2015-08-12 11:43:22 +02:00
intel.c x86/cpufeature: Carve out X86_FEATURE_* 2016-01-30 11:22:17 +01:00
Makefile x86/cpufeature: Carve out X86_FEATURE_* 2016-01-30 11:22:17 +01:00
match.c x86/cpufeature: Carve out X86_FEATURE_* 2016-01-30 11:22:17 +01:00
mkcapflags.sh x86/cpufeature: Carve out X86_FEATURE_* 2016-01-30 11:22:17 +01:00
mshyperv.c x86/hyperv: Fix the build in the !CONFIG_KEXEC_CORE case 2015-09-30 07:44:15 +02:00
perf_event_amd_ibs.c perf/x86/amd/ibs: Convert force_ibs_eilvt_setup() to void 2015-02-18 17:01:46 +01:00
perf_event_amd_iommu.c cpumask: factor out show_cpumap into separate helper function 2014-11-07 11:45:00 -08:00
perf_event_amd_iommu.h perf/x86/amd: AMD IOMMU Performance Counter PERF uncore PMU implementation 2013-06-19 13:04:53 +02:00
perf_event_amd_uncore.c x86/cpufeature: Remove unused and seldomly used cpu_has_xx macros 2015-12-19 11:49:55 +01:00
perf_event_amd.c Merge branch 'x86-cleanups-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip 2016-01-11 16:26:03 -08:00
perf_event_intel_bts.c perf/x86/intel/bts: Disallow use by unprivileged users on paranoid systems 2015-09-13 11:27:22 +02:00
perf_event_intel_cqm.c perf/core: Robustify the perf_cgroup_from_task() RCU checks 2015-11-23 09:21:03 +01:00
perf_event_intel_cstate.c perf/x86: Add Intel cstate PMUs support 2015-10-06 17:31:51 +02:00
perf_event_intel_ds.c perf/x86: Enable cycles:pp for Intel Atom 2016-01-06 11:15:34 +01:00
perf_event_intel_lbr.c perf/x86/intel: Add perf core PMU support for Intel Knights Landing 2016-01-06 11:15:37 +01:00
perf_event_intel_pt.c perf/x86/intel/pt: Add interface to stop Intel PT logging 2015-11-23 09:58:26 +01:00
perf_event_intel_rapl.c perf/x86/rapl: Use unified perf_event_sysfs_show instead of special interface 2016-01-06 11:15:35 +01:00
perf_event_intel_uncore_nhmex.c perf/x86/uncore: Fix coccinelle warnings 2014-08-13 07:51:09 +02:00
perf_event_intel_uncore_snb.c perf/x86/intel/uncore: Add Knights Landing uncore PMU support 2016-01-06 11:15:38 +01:00
perf_event_intel_uncore_snbep.c perf/x86/intel/uncore: Add Knights Landing uncore PMU support 2016-01-06 11:15:38 +01:00
perf_event_intel_uncore.c perf/x86/intel/uncore: Add Knights Landing uncore PMU support 2016-01-06 11:15:38 +01:00
perf_event_intel_uncore.h perf/x86/intel/uncore: Add Knights Landing uncore PMU support 2016-01-06 11:15:38 +01:00
perf_event_intel.c perf/x86/intel: Add perf core PMU support for Intel Knights Landing 2016-01-06 11:15:37 +01:00
perf_event_knc.c x86: Replace __get_cpu_var uses 2014-08-26 13:45:49 -04:00
perf_event_msr.c arch/x86/kernel/cpu/perf_event_msr.c: use sign_extend64() for sign extension 2015-11-06 17:50:42 -08:00
perf_event_p4.c x86: Replace __get_cpu_var uses 2014-08-26 13:45:49 -04:00
perf_event_p6.c perf/x86/intel/p6: Add userspace RDPMC quirk for PPro 2014-02-09 13:08:24 +01:00
perf_event.c perf/x86: Fix filter_events() bug with event mappings 2016-01-06 11:15:33 +01:00
perf_event.h perf/x86/intel: Add perf core PMU support for Intel Knights Landing 2016-01-06 11:15:37 +01:00
perfctr-watchdog.c
powerflags.c update AMD powerflags comments 2013-05-28 12:02:10 +02:00
proc.c x86: Replace cpu_**_mask() with topology_**_cpumask() 2015-05-27 15:22:17 +02:00
rdrand.c x86: Replace RDRAND forced-reseed with simple sanity check 2015-11-25 22:46:43 +01:00
scattered.c x86/cpufeature: Move some of the scattered feature bits to x86_capability 2015-12-19 11:49:53 +01:00
topology.c x86: delete __cpuinit usage from all x86 files 2013-07-14 19:36:56 -04:00
transmeta.c x86/cpufeature: Carve out X86_FEATURE_* 2016-01-30 11:22:17 +01:00
umc.c x86: Delete non-required instances of include <linux/init.h> 2014-01-06 21:25:18 -08:00
vmware.c x86: Correctly detect hypervisor 2013-08-05 06:35:33 -07:00