Module Name:    src
Committed By:   martin
Date:           Tue May 14 17:12:20 UTC 2019

Modified Files:
        src/sys/arch/amd64/amd64 [netbsd-8]: amd64_trap.S locore.S
        src/sys/arch/amd64/include [netbsd-8]: frameasm.h
        src/sys/arch/x86/include [netbsd-8]: specialreg.h
        src/sys/arch/x86/x86 [netbsd-8]: spectre.c

Log Message:
Pull up following revision(s) (requested by maxv in ticket #1269):

        sys/arch/amd64/amd64/locore.S: revision 1.181 (adapted)
        sys/arch/amd64/amd64/amd64_trap.S: revision 1.47 (adapted)
        sys/arch/x86/include/specialreg.h: revision 1.144 (adapted)
        sys/arch/amd64/include/frameasm.h: revision 1.43 (adapted)
        sys/arch/x86/x86/spectre.c: revision 1.27 (adapted)

Mitigation for INTEL-SA-00233: Microarchitectural Data Sampling (MDS).
It requires a microcode update, now available on the Intel website. The
microcode modifies the behavior of the VERW instruction, and makes it flush
internal CPU buffers. We hotpatch the return-to-userland path to add VERW.

Two sysctls are added:

        machdep.mds.mitigated = {0/1} user-settable
        machdep.mds.method = {string} constructed by the kernel

The kernel will automatically enable the mitigation if the updated
microcode is present. If the new microcode is not present, the user can
load it via cpuctl, and set machdep.mds.mitigated=1.


To generate a diff of this commit:
cvs rdiff -u -r1.5.6.3 -r1.5.6.4 src/sys/arch/amd64/amd64/amd64_trap.S
cvs rdiff -u -r1.123.6.8 -r1.123.6.9 src/sys/arch/amd64/amd64/locore.S
cvs rdiff -u -r1.20.32.3 -r1.20.32.4 src/sys/arch/amd64/include/frameasm.h
cvs rdiff -u -r1.98.2.11 -r1.98.2.12 src/sys/arch/x86/include/specialreg.h
cvs rdiff -u -r1.19.2.2 -r1.19.2.3 src/sys/arch/x86/x86/spectre.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Reply via email to