Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/dev/nvmm/x86 Improve the CPUID emulation:
details: https://anonhg.NetBSD.org/src/rev/59123bf96a84
branches: trunk
changeset: 937019:59123bf96a84
user: maxv <maxv%NetBSD.org@localhost>
date: Wed Aug 05 15:38:28 2020 +0000
description:
Improve the CPUID emulation:
- Hide SGX*, PKU, WAITPKG, and SKINIT, because they are not supported.
- Hide HLE and RTM, part of TSX. Because TSX is just too buggy and we
cannot guarantee that it remains enabled in the guest (if for example
the host disables TSX while the guest is running). Nobody wants this
crap anyway, so bye-bye.
- Advertise FSREP_MOV, because no reason to hide it.
diffstat:
sys/dev/nvmm/x86/nvmm_x86.c | 22 +++++++++++-----------
1 files changed, 11 insertions(+), 11 deletions(-)
diffs (76 lines):
diff -r 3bc3de448965 -r 59123bf96a84 sys/dev/nvmm/x86/nvmm_x86.c
--- a/sys/dev/nvmm/x86/nvmm_x86.c Wed Aug 05 15:22:25 2020 +0000
+++ b/sys/dev/nvmm/x86/nvmm_x86.c Wed Aug 05 15:38:28 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: nvmm_x86.c,v 1.10 2020/08/05 15:16:50 maxv Exp $ */
+/* $NetBSD: nvmm_x86.c,v 1.11 2020/08/05 15:38:28 maxv Exp $ */
/*
* Copyright (c) 2018-2020 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: nvmm_x86.c,v 1.10 2020/08/05 15:16:50 maxv Exp $");
+__KERNEL_RCSID(0, "$NetBSD: nvmm_x86.c,v 1.11 2020/08/05 15:38:28 maxv Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -304,16 +304,16 @@
.ebx =
CPUID_SEF_FSGSBASE |
/* CPUID_SEF_TSC_ADJUST excluded */
- CPUID_SEF_SGX |
+ /* CPUID_SEF_SGX excluded */
CPUID_SEF_BMI1 |
- CPUID_SEF_HLE |
+ /* CPUID_SEF_HLE excluded */
/* CPUID_SEF_AVX2 excluded */
CPUID_SEF_FDPEXONLY |
CPUID_SEF_SMEP |
CPUID_SEF_BMI2 |
CPUID_SEF_ERMS |
/* CPUID_SEF_INVPCID excluded, but re-included in VMX */
- CPUID_SEF_RTM |
+ /* CPUID_SEF_RTM excluded */
/* CPUID_SEF_QM excluded */
CPUID_SEF_FPUCSDS |
/* CPUID_SEF_MPX excluded */
@@ -337,9 +337,9 @@
CPUID_SEF_PREFETCHWT1 |
/* CPUID_SEF_AVX512_VBMI excluded */
CPUID_SEF_UMIP |
- CPUID_SEF_PKU |
+ /* CPUID_SEF_PKU excluded */
CPUID_SEF_OSPKE |
- CPUID_SEF_WAITPKG |
+ /* CPUID_SEF_WAITPKG excluded */
/* CPUID_SEF_AVX512_VBMI2 excluded */
/* CPUID_SEF_CET_SS excluded */
CPUID_SEF_GFNI |
@@ -352,13 +352,13 @@
/* CPUID_SEF_RDPID excluded */
CPUID_SEF_CLDEMOTE |
CPUID_SEF_MOVDIRI |
- CPUID_SEF_MOVDIR64B |
- CPUID_SEF_SGXLC,
+ CPUID_SEF_MOVDIR64B,
+ /* CPUID_SEF_SGXLC excluded */
/* CPUID_SEF_PKS excluded */
.edx =
/* CPUID_SEF_AVX512_4VNNIW excluded */
/* CPUID_SEF_AVX512_4FMAPS excluded */
- /* CPUID_SEF_FSREP_MOV excluded */
+ CPUID_SEF_FSREP_MOV |
/* CPUID_SEF_AVX512_VP2INTERSECT excluded */
/* CPUID_SEF_SRBDS_CTRL excluded */
CPUID_SEF_MD_CLEAR |
@@ -391,7 +391,7 @@
/* CPUID_OSVW excluded */
CPUID_IBS |
CPUID_XOP |
- CPUID_SKINIT |
+ /* CPUID_SKINIT excluded */
CPUID_WDT |
CPUID_LWP |
CPUID_FMA4 |
Home |
Main Index |
Thread Index |
Old Index