opnsense-src/sys/amd64
Corvin Köhne f195c503ad vmm: add tunable to trap WBINVD
x86 is cache coherent. However, there are special cases where cache
coherency isn't ensured (e.g. when switching the caching mode). In these
cases, WBINVD can be used. WBINVD writes all cache lines back into main
memory and invalidates the whole cache.

Due to the invalidation of the whole cache, WBINVD is a very heavy
instruction and degrades the performance on all cores. So, we should
minimize the use of WBINVD as much as possible.

In a virtual environment, the WBINVD call is mostly useless. The guest
isn't able to break cache coherency because he can't switch the physical
cache mode. When using pci passthrough WBINVD might be useful.

Nevertheless, trapping and ignoring WBINVD is an unsafe operation. For
that reason, we implement it as tunable.

Reviewed by:	jhb
Sponsored by:	Beckhoff Automation GmbH & Co. KG
MFC after:	1 week
Differential Revision:	https://reviews.freebsd.org/D35253

(cherry picked from commit 3ba952e1a2)
2022-06-20 17:05:36 +02:00
..
acpica amd64 wakeup: rework trampoline page allocation 2021-09-20 03:47:21 +03:00
amd64 Retire sv_transtrap 2022-06-17 22:35:27 +03:00
cloudabi32 fork: Allow ABI to specify fork return values for child. 2022-06-17 22:33:28 +03:00
cloudabi64 fork: Allow ABI to specify fork return values for child. 2022-06-17 22:33:28 +03:00
conf linux(4): Get rid of Linuxulator kernel build options. 2022-06-17 22:30:22 +03:00
ia32 x86: Add a NT_X86_SEGBASES register set. 2022-05-13 09:45:19 -07:00
include vmm: add tunable to trap WBINVD 2022-06-20 17:05:36 +02:00
linux linux(4): Properly build argument list for the signal handler 2022-06-17 22:35:38 +03:00
linux32 linux(4): Properly restore the thread signal mask after signal delivery on i386 2022-06-17 22:35:40 +03:00
pci pci_cfgreg.c: Use io port config access for early boot time. 2019-04-09 18:07:17 +00:00
sgx Convert remaining cap_rights_init users to cap_rights_init_one 2021-01-12 13:16:10 +00:00
vmm vmm: add tunable to trap WBINVD 2022-06-20 17:05:36 +02:00
Makefile Bring the tags and links entries for amd64 up to date. 2021-10-07 16:01:46 -07:00