]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
Fix IBRS for machines with IBRS_ALL capability.
authorkib <kib@FreeBSD.org>
Tue, 25 Feb 2020 17:26:10 +0000 (17:26 +0000)
committerkib <kib@FreeBSD.org>
Tue, 25 Feb 2020 17:26:10 +0000 (17:26 +0000)
commit650ab02d61a410c7dbccd3990b8f614e3f79e054
tree26f7a9f38d82aebf0e899a137935a063eeafe88f
parent3967f48046418f47880fb2ba3ae9d5d17c11cb15
Fix IBRS for machines with IBRS_ALL capability.

When turning IBRS mitigation using sysctl, as opposed to loader tunable,
send IPI to tweak MSR on all cores.  Right now code only performed MSR write
onr the CPU where sysctl was run.

Properly report hw.ibrs_active for IBRS_ALL.  Split hw_ibrs_ibpb_active out
from ibrs_active, to keep the current semantic of guiding kernel entry and
exit handlers.

Reported and tested by: mav
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
sys/amd64/amd64/initcpu.c
sys/amd64/amd64/support.S
sys/dev/cpuctl/cpuctl.c
sys/i386/i386/support.s
sys/x86/acpica/acpi_wakeup.c
sys/x86/include/x86_var.h
sys/x86/x86/cpu_machdep.c