]> www.infradead.org Git - users/jedix/linux-maple.git/commit
x86/l1tf: Handle EPT disabled state proper
authorThomas Gleixner <tglx@linutronix.de>
Fri, 13 Jul 2018 14:23:18 +0000 (16:23 +0200)
committerKonrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Sat, 11 Aug 2018 00:44:42 +0000 (20:44 -0400)
commite04f5b91baf8576494ab970f5719f3ce6c2d767f
tree665ea040e46ea3121d8ce424ff4d67cfc8621557
parent33e91f445c8b5fa894e7750b724c9d35c6b21eba
x86/l1tf: Handle EPT disabled state proper

If Extended Page Tables (EPT) are disabled or not supported, no L1D
flushing is required. The setup function can just avoid setting up the L1D
flush for the EPT=n case.

Invoke it after the hardware setup has be done and enable_ept has the
correct state and expose the EPT disabled state in the mitigation status as
well.

Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Tested-by: Jiri Kosina <jkosina@suse.cz>
Reviewed-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Reviewed-by: Josh Poimboeuf <jpoimboe@redhat.com>
Link: https://lkml.kernel.org/r/20180713142322.612160168@linutronix.de
Orabug: 28220625
CVE: CVE-2018-3620

(cherry picked from commit a7b9020b06ec6d7c3f3b0d4ef1a9eba12654f4f7)

Signed-off-by: Mihai Carabas <mihai.carabas@oracle.com>
Reviewed-by: Darren Kenny <darren.kenny@oracle.com>
Conflicts:
arch/x86/kernel/cpu/bugs_64.c
arch/x86/kvm/vmx.c
Contextual: different content; Modified arch/x86/kernel/cpu/bugs_64.c
instead of arch/x86/kernel/cpu/bugs.c.
arch/x86/include/asm/vmx.h
arch/x86/kernel/cpu/bugs_64.c
arch/x86/kvm/vmx.c