alistair23-linux/arch/x86/kernel/cpu
Thomas Gleixner 3344ed3079 x86/bugs: Separate AMD E400 erratum and C1E bug
The workaround for the AMD Erratum E400 (Local APIC timer stops in C1E
state) is a two step process:

 - Selection of the E400 aware idle routine

 - Detection whether the platform is affected

The idle routine selection happens for possibly affected CPUs depending on
family/model/stepping information. These range of CPUs is not necessarily
affected as the decision whether to enable the C1E feature is made by the
firmware. Unfortunately there is no way to query this at early boot.

The current implementation polls a MSR in the E400 aware idle routine to
detect whether the CPU is affected. This is inefficient on non affected
CPUs because every idle entry has to do the MSR read.

There is a better way to detect this before going idle for the first time
which requires to seperate the bug flags:

  X86_BUG_AMD_E400 	- Selects the E400 aware idle routine and
  			  enables the detection
			  
  X86_BUG_AMD_APIC_C1E  - Set when the platform is affected by E400

Replace the current X86_BUG_AMD_APIC_C1E usage by the new X86_BUG_AMD_E400
bug bit to select the idle routine which currently does an unconditional
detection poll. X86_BUG_AMD_APIC_C1E is going to be used in later patches
to remove the MSR polling and simplify the handling of this misfeature.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Borislav Petkov <bp@suse.de>
Cc: Jiri Olsa <jolsa@redhat.com>
Link: http://lkml.kernel.org/r/20161209182912.2726-3-bp@alien8.de
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
2016-12-09 21:23:20 +01:00
..
mcheck x86/mce/AMD: Extract the error address on SMCA systems 2016-09-13 15:23:13 +02:00
microcode x86/microcode/AMD: Fix more fallout from CONFIG_RANDOMIZE_MEMORY=y 2016-10-28 10:29:59 +02:00
mtrr x86: Apply more __ro_after_init and const 2016-08-10 14:55:05 +02:00
.gitignore Update .gitignore files for generated targets 2008-10-20 11:24:31 -07:00
amd.c x86/bugs: Separate AMD E400 erratum and C1E bug 2016-12-09 21:23:20 +01:00
bugs.c x86/fpu: Move various internal function prototypes to fpu/internal.h 2015-05-19 15:47:48 +02:00
bugs_64.c x86/cpu: Convert printk(KERN_<LEVEL> ...) to pr_<level>(...) 2016-02-03 10:30:03 +01:00
centaur.c Merge branch 'x86-asm-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip 2016-03-15 09:32:27 -07:00
common.c Merge branch 'x86-asm-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip 2016-10-03 16:13:28 -07: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: Replace cpu_has_fpu with boot_cpu_has() usage 2016-04-13 11:37:40 +02:00
hypervisor.c virt, sched: Add generic vCPU pinning support 2016-09-05 13:52:38 +02:00
intel.c Merge branch 'x86-headers-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip 2016-08-01 14:23:42 -04:00
intel_cacheinfo.c Merge branch 'x86-asm-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip 2016-03-15 09:32:27 -07:00
Makefile kernel: add kcov code coverage 2016-03-22 15:36:02 -07:00
match.c x86/kernel: Audit and remove any unnecessary uses of module.h 2016-07-14 15:06:41 +02:00
mkcapflags.sh x86/cpufeature: Carve out X86_FEATURE_* 2016-01-30 11:22:17 +01:00
mshyperv.c x86/kernel: Audit and remove any unnecessary uses of module.h 2016-07-14 15:06:41 +02:00
perfctr-watchdog.c x86/kernel: Audit and remove any unnecessary uses of module.h 2016-07-14 15:06:41 +02:00
powerflags.c x86/cpu: Add advanced power management bits 2016-03-29 11:12:11 +02:00
proc.c x86: Replace cpu_**_mask() with topology_**_cpumask() 2015-05-27 15:22:17 +02:00
rdrand.c x86, asm: Use CC_SET()/CC_OUT() and static_cpu_has() in archrandom.h 2016-06-08 12:41:20 -07:00
scattered.c x86/cpufeature: Add AVX512_4VNNIW and AVX512_4FMAPS features 2016-10-19 17:37:13 +02:00
topology.c x86/cpu: Convert printk(KERN_<LEVEL> ...) to pr_<level>(...) 2016-02-03 10:30:03 +01:00
transmeta.c Merge branch 'x86-asm-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip 2016-03-15 09:32:27 -07:00
umc.c x86: Delete non-required instances of include <linux/init.h> 2014-01-06 21:25:18 -08:00
vmware.c x86/vmware: Skip timer_irq_works() check on VMware 2016-10-19 17:36:33 +02:00