]> git.ipfire.org Git - thirdparty/qemu.git/commit
target/i386: add support for FB_CLEAR feature
authorEmanuele Giuseppe Esposito <eesposit@redhat.com>
Wed, 1 Feb 2023 13:57:59 +0000 (08:57 -0500)
committerPaolo Bonzini <pbonzini@redhat.com>
Thu, 18 May 2023 06:53:50 +0000 (08:53 +0200)
commit22e1094ca82d5518c1b69aff3e87c550776ae1eb
tree1e837e7055bc8acc78d78782cdfd516f7f79ee19
parent0e7e3bf1a552c178924867fa7c2f30ccc8a179e0
target/i386: add support for FB_CLEAR feature

As reported by the Intel's doc:
"FB_CLEAR: The processor will overwrite fill buffer values as part of
MD_CLEAR operations with the VERW instruction.
On these processors, L1D_FLUSH does not overwrite fill buffer values."

If this cpu feature is present in host, allow QEMU to choose whether to
show it to the guest too.
One disadvantage of not exposing it is that the guest will report
a non existing vulnerability in
/sys/devices/system/cpu/vulnerabilities/mmio_stale_data
because the mitigation is present only when the cpu has
        (FLUSH_L1D and MD_CLEAR) or FB_CLEAR
features enabled.

Signed-off-by: Emanuele Giuseppe Esposito <eesposit@redhat.com>
Message-Id: <20230201135759.555607-3-eesposit@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
target/i386/cpu.c
target/i386/cpu.h