]> www.infradead.org Git - users/jedix/linux-maple.git/commit
x86/spectre_v2: Don't allow {ibrs,ipbp,lfence}_enabled to be toggled if retpoline
authorKonrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Thu, 1 Feb 2018 17:25:54 +0000 (12:25 -0500)
committerJack Vogel <jack.vogel@oracle.com>
Thu, 8 Feb 2018 18:15:15 +0000 (10:15 -0800)
commita152f9821dc56887544d287649c1d727e56567d7
treefa19f2475404d77ae914ac972ff52133ba056dac
parentccdb54f5c9d885eefff9325e5aab275127ee9090
x86/spectre_v2: Don't allow {ibrs,ipbp,lfence}_enabled to be toggled if retpoline

is enabled.

And also refresh the spectre_v2_enabled mode depending on whether
the sysfs knobs are turned on/off.

Preserve the ability to tweak IBPB if retpoline is enabled.

Orabug: 27477743
CVE: CVE-2017-5715

Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Reviewed-by: Darren Kenny <darren.kenny@oracle.com>
Reviewed-by: Pavel Tatashin <pasha.tatashin@oracle.com>
arch/x86/include/asm/processor.h
arch/x86/kernel/cpu/bugs_64.c
arch/x86/kernel/cpu/spec_ctrl.c