Josh Poimboeuf c6613521ab cpu/hotplug: detect SMT disabled by BIOS
commit 73d5e2b472640b1fcdb61ae8be389912ef211bda upstream

If SMT is disabled in BIOS, the CPU code doesn't properly detect it.
The /sys/devices/system/cpu/smt/control file shows 'on', and the 'l1tf'
vulnerabilities file shows SMT as vulnerable.

Fix it by forcing 'cpu_smt_control' to CPU_SMT_NOT_SUPPORTED in such a
case.  Unfortunately the detection can only be done after bringing all
the CPUs online, so we have to overwrite any previous writes to the
variable.

Reported-by: Joe Mario <jmario@redhat.com>
Tested-by: Jiri Kosina <jkosina@suse.cz>
Fixes: f048c399e0f7 ("x86/topology: Provide topology_smt_supported()")
Signed-off-by: Josh Poimboeuf <jpoimboe@redhat.com>
Signed-off-by: Peter Zijlstra <peterz@infradead.org>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-08-15 18:12:57 +02:00
..
2018-05-30 07:52:41 +02:00
2017-08-16 16:48:34 -07:00
2018-08-15 18:12:57 +02:00
2017-05-18 10:30:19 -06:00
2018-08-03 07:50:38 +02:00
2018-02-03 17:38:47 +01:00
2018-08-03 07:50:22 +02:00
2017-08-21 12:47:31 -07:00
2017-09-08 18:26:48 -07:00
2018-02-22 15:42:24 +01:00
2018-05-09 09:51:50 +02:00