Also do RSB refilling when context switching, after vmexits, and
authorguenther <guenther@openbsd.org>
Tue, 24 Jul 2018 02:42:25 +0000 (02:42 +0000)
committerguenther <guenther@openbsd.org>
Tue, 24 Jul 2018 02:42:25 +0000 (02:42 +0000)
commita1fa35384a2451a9a5f75e63d1e99a2902f0cfbd
treedb6830c3527d41321bebb7608f87f969f9001cf3
parentc8cb7e6068f247a1ce3fb16dc32aab592208b818
Also do RSB refilling when context switching, after vmexits, and
when vmlaunch or vmresume fails.

Follow the lead of clang and the intel recommendation and do an lfence
after the pause in the speculation-stop path for retpoline, RSB refill,
and meltover ASM bits.

ok kettenis@ deraadt@
sys/arch/amd64/amd64/locore.S
sys/arch/amd64/amd64/vector.S
sys/arch/amd64/amd64/vmm_support.S
sys/arch/amd64/include/asm.h
sys/arch/amd64/include/cpufunc.h