linux-stable/arch/x86/kernel/cpu
Thomas Gleixner 0becc0ae5b x86/mce: Make timer handling more robust
Erik reported that on a preproduction hardware a CMCI storm triggers the
BUG_ON in add_timer_on(). The reason is that the per CPU MCE timer is
started by the CMCI logic before the MCE CPU hotplug callback starts the
timer with add_timer_on(). So the timer is already queued which triggers
the BUG.

Using add_timer_on() is pretty pointless in this code because the timer is
strictlty per CPU, initialized as pinned and all operations which arm the
timer happen on the CPU to which the timer belongs.

Simplify the whole machinery by using mod_timer() instead of add_timer_on()
which avoids the problem because mod_timer() can handle already queued
timers. Use __start_timer() everywhere so the earliest armed expiry time is
preserved.

Reported-by: Erik Veijola <erik.veijola@intel.com>
Tested-by: Borislav Petkov <bp@alien8.de>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Reviewed-by: Borislav Petkov <bp@alien8.de>
Cc: Tony Luck <tony.luck@intel.com>
Link: http://lkml.kernel.org/r/alpine.DEB.2.20.1701310936080.3457@nanos
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
2017-01-31 21:47:58 +01:00
..
mcheck x86/mce: Make timer handling more robust 2017-01-31 21:47:58 +01:00
microcode x86/microcode: Do not access the initrd after it has been freed 2017-01-30 09:32:42 +01:00
mtrr x86: Apply more __ro_after_init and const 2016-08-10 14:55:05 +02:00
.gitignore
Makefile Merge branch 'x86-cache-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip 2016-12-22 09:25:45 -08:00
amd.c x86/CPU/AMD: Fix Bulldozer topology 2017-01-06 08:37:41 +01:00
bugs.c x86/cpu: Merge bugs.c and bugs_64.c 2016-10-25 11:48:50 +02: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 x86/cpu: Fix bootup crashes by sanitizing the argument of the 'clearcpuid=' command-line option 2017-01-05 08:54:34 +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: 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 x86/microcode/intel: Add a helper which gives the microcode revision 2017-01-09 23:11:14 +01:00
intel_cacheinfo.c Merge branch 'x86-cache-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip 2016-12-22 09:25:45 -08:00
intel_rdt.c x86/intel_rdt: Add scheduler hook 2016-10-30 19:10:16 -06:00
intel_rdt_rdtgroup.c x86/intel_rdt: Implement show_options() for resctrlfs 2016-12-09 14:12:18 +01:00
intel_rdt_schemata.c x86/intel_rdt: Add schemata file 2016-10-30 19:10:16 -06: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 clocksource: Use a plain u64 instead of cycle_t 2016-12-25 11:04:12 +01: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 Merge branch 'x86/cpufeature' into x86/cache 2016-11-16 14:19:34 +01: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 Merge branch 'x86-platform-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip 2016-12-12 15:29:06 -08:00