]> git.baikalelectronics.ru Git - kernel.git/commit
x86/speculation: Use cached host SPEC_CTRL value for guest entry/exit
authorJosh Poimboeuf <jpoimboe@kernel.org>
Tue, 14 Jun 2022 21:16:08 +0000 (23:16 +0200)
committerBorislav Petkov <bp@suse.de>
Mon, 27 Jun 2022 08:34:00 +0000 (10:34 +0200)
commitef05b11e2fef018c86af834d3af846434d26a244
tree64068e6d11e33c1e9024acdbb450e0efca38eb51
parent61e5ee68a8d396858485f15667701e4b78bcf7e0
x86/speculation: Use cached host SPEC_CTRL value for guest entry/exit

There's no need to recalculate the host value for every entry/exit.
Just use the cached value in spec_ctrl_current().

Signed-off-by: Josh Poimboeuf <jpoimboe@kernel.org>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Signed-off-by: Borislav Petkov <bp@suse.de>
arch/x86/kernel/cpu/bugs.c