[libvirt PATCH 3/4] cpu_map: Add missing x86 features in 0x80000008 CPUID leaf

Jiri Denemark jdenemar at redhat.com
Wed Jun 17 14:18:53 UTC 2020


Signed-off-by: Jiri Denemark <jdenemar at redhat.com>
---
 src/cpu_map/x86_features.xml                                | 6 ++++++
 tests/cputestdata/x86_64-cpuid-Cooperlake-enabled.xml       | 2 +-
 tests/cputestdata/x86_64-cpuid-Cooperlake-json.xml          | 1 +
 .../cputestdata/x86_64-cpuid-EPYC-7601-32-Core-disabled.xml | 2 +-
 tests/cputestdata/x86_64-cpuid-EPYC-7601-32-Core-guest.xml  | 1 +
 tests/cputestdata/x86_64-cpuid-EPYC-7601-32-Core-host.xml   | 1 +
 .../x86_64-cpuid-EPYC-7601-32-Core-ibpb-disabled.xml        | 2 +-
 .../x86_64-cpuid-EPYC-7601-32-Core-ibpb-guest.xml           | 1 +
 .../x86_64-cpuid-EPYC-7601-32-Core-ibpb-host.xml            | 1 +
 .../x86_64-cpuid-Hygon-C86-7185-32-core-disabled.xml        | 2 +-
 .../x86_64-cpuid-Hygon-C86-7185-32-core-guest.xml           | 1 +
 .../x86_64-cpuid-Hygon-C86-7185-32-core-host.xml            | 1 +
 .../x86_64-cpuid-Ryzen-7-1800X-Eight-Core-disabled.xml      | 2 +-
 .../x86_64-cpuid-Ryzen-7-1800X-Eight-Core-guest.xml         | 1 +
 .../x86_64-cpuid-Ryzen-7-1800X-Eight-Core-host.xml          | 1 +
 .../x86_64-cpuid-Ryzen-9-3900X-12-Core-disabled.xml         | 1 +
 .../x86_64-cpuid-Ryzen-9-3900X-12-Core-enabled.xml          | 2 +-
 .../x86_64-cpuid-Ryzen-9-3900X-12-Core-guest.xml            | 2 ++
 .../cputestdata/x86_64-cpuid-Ryzen-9-3900X-12-Core-host.xml | 2 ++
 .../cputestdata/x86_64-cpuid-Ryzen-9-3900X-12-Core-json.xml | 1 +
 tests/domaincapsdata/qemu_5.1.0-q35.x86_64.xml              | 2 ++
 tests/domaincapsdata/qemu_5.1.0.x86_64.xml                  | 2 ++
 22 files changed, 31 insertions(+), 6 deletions(-)

diff --git a/src/cpu_map/x86_features.xml b/src/cpu_map/x86_features.xml
index 81d1ad5c69..cb250555f6 100644
--- a/src/cpu_map/x86_features.xml
+++ b/src/cpu_map/x86_features.xml
@@ -493,12 +493,18 @@
   <feature name='clzero'>
     <cpuid eax_in='0x80000008' ebx='0x00000001'/>
   </feature>
+  <feature name='xsaveerptr'>
+    <cpuid eax_in='0x80000008' ebx='0x00000004'/>
+  </feature>
   <feature name='wbnoinvd'>
     <cpuid eax_in='0x80000008' ebx='0x00000200'/>
   </feature>
   <feature name='ibpb'>
     <cpuid eax_in='0x80000008' ebx='0x00001000'/>
   </feature>
+  <feature name='amd-stibp'>
+    <cpuid eax_in='0x80000008' ebx='0x00008000'/>
+  </feature>
   <feature name='amd-ssbd'>
     <cpuid eax_in='0x80000008' ebx='0x01000000'/>
   </feature>
diff --git a/tests/cputestdata/x86_64-cpuid-Cooperlake-enabled.xml b/tests/cputestdata/x86_64-cpuid-Cooperlake-enabled.xml
index 2d7f83c80f..1d91c3efa8 100644
--- a/tests/cputestdata/x86_64-cpuid-Cooperlake-enabled.xml
+++ b/tests/cputestdata/x86_64-cpuid-Cooperlake-enabled.xml
@@ -6,6 +6,6 @@
   <cpuid eax_in='0x00000007' ecx_in='0x01' eax='0x00000020' ebx='0x00000000' ecx='0x00000000' edx='0x00000000'/>
   <cpuid eax_in='0x0000000d' ecx_in='0x01' eax='0x0000000f' ebx='0x00000000' ecx='0x00000000' edx='0x00000000'/>
   <cpuid eax_in='0x80000001' ecx_in='0x00' eax='0x00000000' ebx='0x00000000' ecx='0x00000121' edx='0x2c100800'/>
-  <cpuid eax_in='0x80000008' ecx_in='0x00' eax='0x00000000' ebx='0x01001000' ecx='0x00000000' edx='0x00000000'/>
+  <cpuid eax_in='0x80000008' ecx_in='0x00' eax='0x00000000' ebx='0x01009000' ecx='0x00000000' edx='0x00000000'/>
   <msr index='0x10a' edx='0x00000000' eax='0x000001eb'/>
 </cpudata>
diff --git a/tests/cputestdata/x86_64-cpuid-Cooperlake-json.xml b/tests/cputestdata/x86_64-cpuid-Cooperlake-json.xml
index fb319d547c..c89e0e5350 100644
--- a/tests/cputestdata/x86_64-cpuid-Cooperlake-json.xml
+++ b/tests/cputestdata/x86_64-cpuid-Cooperlake-json.xml
@@ -10,6 +10,7 @@
   <feature policy='require' name='md-clear'/>
   <feature policy='require' name='xsaves'/>
   <feature policy='require' name='ibpb'/>
+  <feature policy='require' name='amd-stibp'/>
   <feature policy='require' name='amd-ssbd'/>
   <feature policy='require' name='tsx-ctrl'/>
 </cpu>
diff --git a/tests/cputestdata/x86_64-cpuid-EPYC-7601-32-Core-disabled.xml b/tests/cputestdata/x86_64-cpuid-EPYC-7601-32-Core-disabled.xml
index d9045c88d5..c26c9c7be3 100644
--- a/tests/cputestdata/x86_64-cpuid-EPYC-7601-32-Core-disabled.xml
+++ b/tests/cputestdata/x86_64-cpuid-EPYC-7601-32-Core-disabled.xml
@@ -4,5 +4,5 @@
   <cpuid eax_in='0x0000000d' ecx_in='0x01' eax='0x00000008' ebx='0x00000000' ecx='0x00000000' edx='0x00000000'/>
   <cpuid eax_in='0x80000001' ecx_in='0x00' eax='0x00000000' ebx='0x00000000' ecx='0x01c2300c' edx='0x00000000'/>
   <cpuid eax_in='0x80000007' ecx_in='0x00' eax='0x00000000' ebx='0x00000000' ecx='0x00000000' edx='0x00000100'/>
-  <cpuid eax_in='0x80000008' ecx_in='0x00' eax='0x00000000' ebx='0x00000001' ecx='0x00000000' edx='0x00000000'/>
+  <cpuid eax_in='0x80000008' ecx_in='0x00' eax='0x00000000' ebx='0x00000005' ecx='0x00000000' edx='0x00000000'/>
 </cpudata>
diff --git a/tests/cputestdata/x86_64-cpuid-EPYC-7601-32-Core-guest.xml b/tests/cputestdata/x86_64-cpuid-EPYC-7601-32-Core-guest.xml
index b75196aac5..612e571609 100644
--- a/tests/cputestdata/x86_64-cpuid-EPYC-7601-32-Core-guest.xml
+++ b/tests/cputestdata/x86_64-cpuid-EPYC-7601-32-Core-guest.xml
@@ -14,4 +14,5 @@
   <feature policy='require' name='perfctr_nb'/>
   <feature policy='require' name='invtsc'/>
   <feature policy='require' name='clzero'/>
+  <feature policy='require' name='xsaveerptr'/>
 </cpu>
diff --git a/tests/cputestdata/x86_64-cpuid-EPYC-7601-32-Core-host.xml b/tests/cputestdata/x86_64-cpuid-EPYC-7601-32-Core-host.xml
index fd84b526db..7498d924e2 100644
--- a/tests/cputestdata/x86_64-cpuid-EPYC-7601-32-Core-host.xml
+++ b/tests/cputestdata/x86_64-cpuid-EPYC-7601-32-Core-host.xml
@@ -15,4 +15,5 @@
   <feature name='perfctr_nb'/>
   <feature name='invtsc'/>
   <feature name='clzero'/>
+  <feature name='xsaveerptr'/>
 </cpu>
diff --git a/tests/cputestdata/x86_64-cpuid-EPYC-7601-32-Core-ibpb-disabled.xml b/tests/cputestdata/x86_64-cpuid-EPYC-7601-32-Core-ibpb-disabled.xml
index 429d84d031..a7f4fa3f01 100644
--- a/tests/cputestdata/x86_64-cpuid-EPYC-7601-32-Core-ibpb-disabled.xml
+++ b/tests/cputestdata/x86_64-cpuid-EPYC-7601-32-Core-ibpb-disabled.xml
@@ -4,5 +4,5 @@
   <cpuid eax_in='0x0000000d' ecx_in='0x01' eax='0x00000008' ebx='0x00000000' ecx='0x00000000' edx='0x00000000'/>
   <cpuid eax_in='0x80000001' ecx_in='0x00' eax='0x00000000' ebx='0x00000000' ecx='0x01c2300c' edx='0x08000000'/>
   <cpuid eax_in='0x80000007' ecx_in='0x00' eax='0x00000000' ebx='0x00000000' ecx='0x00000000' edx='0x00000100'/>
-  <cpuid eax_in='0x80000008' ecx_in='0x00' eax='0x00000000' ebx='0x00000001' ecx='0x00000000' edx='0x00000000'/>
+  <cpuid eax_in='0x80000008' ecx_in='0x00' eax='0x00000000' ebx='0x00000005' ecx='0x00000000' edx='0x00000000'/>
 </cpudata>
diff --git a/tests/cputestdata/x86_64-cpuid-EPYC-7601-32-Core-ibpb-guest.xml b/tests/cputestdata/x86_64-cpuid-EPYC-7601-32-Core-ibpb-guest.xml
index 5044c8cc35..96fdea306f 100644
--- a/tests/cputestdata/x86_64-cpuid-EPYC-7601-32-Core-ibpb-guest.xml
+++ b/tests/cputestdata/x86_64-cpuid-EPYC-7601-32-Core-ibpb-guest.xml
@@ -14,5 +14,6 @@
   <feature policy='require' name='perfctr_nb'/>
   <feature policy='require' name='invtsc'/>
   <feature policy='require' name='clzero'/>
+  <feature policy='require' name='xsaveerptr'/>
   <feature policy='disable' name='rdtscp'/>
 </cpu>
diff --git a/tests/cputestdata/x86_64-cpuid-EPYC-7601-32-Core-ibpb-host.xml b/tests/cputestdata/x86_64-cpuid-EPYC-7601-32-Core-ibpb-host.xml
index d7d5ce88d9..4fff74f3aa 100644
--- a/tests/cputestdata/x86_64-cpuid-EPYC-7601-32-Core-ibpb-host.xml
+++ b/tests/cputestdata/x86_64-cpuid-EPYC-7601-32-Core-ibpb-host.xml
@@ -15,4 +15,5 @@
   <feature name='perfctr_nb'/>
   <feature name='invtsc'/>
   <feature name='clzero'/>
+  <feature name='xsaveerptr'/>
 </cpu>
diff --git a/tests/cputestdata/x86_64-cpuid-Hygon-C86-7185-32-core-disabled.xml b/tests/cputestdata/x86_64-cpuid-Hygon-C86-7185-32-core-disabled.xml
index d9045c88d5..c26c9c7be3 100644
--- a/tests/cputestdata/x86_64-cpuid-Hygon-C86-7185-32-core-disabled.xml
+++ b/tests/cputestdata/x86_64-cpuid-Hygon-C86-7185-32-core-disabled.xml
@@ -4,5 +4,5 @@
   <cpuid eax_in='0x0000000d' ecx_in='0x01' eax='0x00000008' ebx='0x00000000' ecx='0x00000000' edx='0x00000000'/>
   <cpuid eax_in='0x80000001' ecx_in='0x00' eax='0x00000000' ebx='0x00000000' ecx='0x01c2300c' edx='0x00000000'/>
   <cpuid eax_in='0x80000007' ecx_in='0x00' eax='0x00000000' ebx='0x00000000' ecx='0x00000000' edx='0x00000100'/>
-  <cpuid eax_in='0x80000008' ecx_in='0x00' eax='0x00000000' ebx='0x00000001' ecx='0x00000000' edx='0x00000000'/>
+  <cpuid eax_in='0x80000008' ecx_in='0x00' eax='0x00000000' ebx='0x00000005' ecx='0x00000000' edx='0x00000000'/>
 </cpudata>
diff --git a/tests/cputestdata/x86_64-cpuid-Hygon-C86-7185-32-core-guest.xml b/tests/cputestdata/x86_64-cpuid-Hygon-C86-7185-32-core-guest.xml
index 75c71233c6..844b8b9d4f 100644
--- a/tests/cputestdata/x86_64-cpuid-Hygon-C86-7185-32-core-guest.xml
+++ b/tests/cputestdata/x86_64-cpuid-Hygon-C86-7185-32-core-guest.xml
@@ -14,4 +14,5 @@
   <feature policy='require' name='perfctr_nb'/>
   <feature policy='require' name='invtsc'/>
   <feature policy='require' name='clzero'/>
+  <feature policy='require' name='xsaveerptr'/>
 </cpu>
diff --git a/tests/cputestdata/x86_64-cpuid-Hygon-C86-7185-32-core-host.xml b/tests/cputestdata/x86_64-cpuid-Hygon-C86-7185-32-core-host.xml
index 82f28067c4..3d1b143eba 100644
--- a/tests/cputestdata/x86_64-cpuid-Hygon-C86-7185-32-core-host.xml
+++ b/tests/cputestdata/x86_64-cpuid-Hygon-C86-7185-32-core-host.xml
@@ -15,4 +15,5 @@
   <feature name='perfctr_nb'/>
   <feature name='invtsc'/>
   <feature name='clzero'/>
+  <feature name='xsaveerptr'/>
 </cpu>
diff --git a/tests/cputestdata/x86_64-cpuid-Ryzen-7-1800X-Eight-Core-disabled.xml b/tests/cputestdata/x86_64-cpuid-Ryzen-7-1800X-Eight-Core-disabled.xml
index 7dbacf982d..0358ecf478 100644
--- a/tests/cputestdata/x86_64-cpuid-Ryzen-7-1800X-Eight-Core-disabled.xml
+++ b/tests/cputestdata/x86_64-cpuid-Ryzen-7-1800X-Eight-Core-disabled.xml
@@ -5,5 +5,5 @@
   <cpuid eax_in='0x0000000d' ecx_in='0x01' eax='0x00000008' ebx='0x00000000' ecx='0x00000000' edx='0x00000000'/>
   <cpuid eax_in='0x80000001' ecx_in='0x00' eax='0x00000000' ebx='0x00000000' ecx='0x01c23008' edx='0x00000000'/>
   <cpuid eax_in='0x80000007' ecx_in='0x00' eax='0x00000000' ebx='0x00000000' ecx='0x00000000' edx='0x00000100'/>
-  <cpuid eax_in='0x80000008' ecx_in='0x00' eax='0x00000000' ebx='0x00000001' ecx='0x00000000' edx='0x00000000'/>
+  <cpuid eax_in='0x80000008' ecx_in='0x00' eax='0x00000000' ebx='0x00000005' ecx='0x00000000' edx='0x00000000'/>
 </cpudata>
diff --git a/tests/cputestdata/x86_64-cpuid-Ryzen-7-1800X-Eight-Core-guest.xml b/tests/cputestdata/x86_64-cpuid-Ryzen-7-1800X-Eight-Core-guest.xml
index b75196aac5..612e571609 100644
--- a/tests/cputestdata/x86_64-cpuid-Ryzen-7-1800X-Eight-Core-guest.xml
+++ b/tests/cputestdata/x86_64-cpuid-Ryzen-7-1800X-Eight-Core-guest.xml
@@ -14,4 +14,5 @@
   <feature policy='require' name='perfctr_nb'/>
   <feature policy='require' name='invtsc'/>
   <feature policy='require' name='clzero'/>
+  <feature policy='require' name='xsaveerptr'/>
 </cpu>
diff --git a/tests/cputestdata/x86_64-cpuid-Ryzen-7-1800X-Eight-Core-host.xml b/tests/cputestdata/x86_64-cpuid-Ryzen-7-1800X-Eight-Core-host.xml
index fd84b526db..7498d924e2 100644
--- a/tests/cputestdata/x86_64-cpuid-Ryzen-7-1800X-Eight-Core-host.xml
+++ b/tests/cputestdata/x86_64-cpuid-Ryzen-7-1800X-Eight-Core-host.xml
@@ -15,4 +15,5 @@
   <feature name='perfctr_nb'/>
   <feature name='invtsc'/>
   <feature name='clzero'/>
+  <feature name='xsaveerptr'/>
 </cpu>
diff --git a/tests/cputestdata/x86_64-cpuid-Ryzen-9-3900X-12-Core-disabled.xml b/tests/cputestdata/x86_64-cpuid-Ryzen-9-3900X-12-Core-disabled.xml
index 7feb55f0b7..c7107c2488 100644
--- a/tests/cputestdata/x86_64-cpuid-Ryzen-9-3900X-12-Core-disabled.xml
+++ b/tests/cputestdata/x86_64-cpuid-Ryzen-9-3900X-12-Core-disabled.xml
@@ -5,4 +5,5 @@
   <cpuid eax_in='0x0000000f' ecx_in='0x01' eax='0x00000000' ebx='0x00000000' ecx='0x00000000' edx='0x00000006'/>
   <cpuid eax_in='0x80000001' ecx_in='0x00' eax='0x00000000' ebx='0x00000000' ecx='0x01423408' edx='0x00000000'/>
   <cpuid eax_in='0x80000007' ecx_in='0x00' eax='0x00000000' ebx='0x00000000' ecx='0x00000000' edx='0x00000100'/>
+  <cpuid eax_in='0x80000008' ecx_in='0x00' eax='0x00000000' ebx='0x00008000' ecx='0x00000000' edx='0x00000000'/>
 </cpudata>
diff --git a/tests/cputestdata/x86_64-cpuid-Ryzen-9-3900X-12-Core-enabled.xml b/tests/cputestdata/x86_64-cpuid-Ryzen-9-3900X-12-Core-enabled.xml
index 80bcccd009..ce0665bf59 100644
--- a/tests/cputestdata/x86_64-cpuid-Ryzen-9-3900X-12-Core-enabled.xml
+++ b/tests/cputestdata/x86_64-cpuid-Ryzen-9-3900X-12-Core-enabled.xml
@@ -5,6 +5,6 @@
   <cpuid eax_in='0x00000007' ecx_in='0x00' eax='0x00000000' ebx='0x219c01ab' ecx='0x00400004' edx='0xa8000000'/>
   <cpuid eax_in='0x0000000d' ecx_in='0x01' eax='0x0000000f' ebx='0x00000000' ecx='0x00000000' edx='0x00000000'/>
   <cpuid eax_in='0x80000001' ecx_in='0x00' eax='0x00000000' ebx='0x00000000' ecx='0x008003f7' edx='0x2e500800'/>
-  <cpuid eax_in='0x80000008' ecx_in='0x00' eax='0x00000000' ebx='0x03001201' ecx='0x00000000' edx='0x00000000'/>
+  <cpuid eax_in='0x80000008' ecx_in='0x00' eax='0x00000000' ebx='0x03001205' ecx='0x00000000' edx='0x00000000'/>
   <msr index='0x10a' edx='0x00000000' eax='0x00000069'/>
 </cpudata>
diff --git a/tests/cputestdata/x86_64-cpuid-Ryzen-9-3900X-12-Core-guest.xml b/tests/cputestdata/x86_64-cpuid-Ryzen-9-3900X-12-Core-guest.xml
index ec12363e71..7978231383 100644
--- a/tests/cputestdata/x86_64-cpuid-Ryzen-9-3900X-12-Core-guest.xml
+++ b/tests/cputestdata/x86_64-cpuid-Ryzen-9-3900X-12-Core-guest.xml
@@ -21,7 +21,9 @@
   <feature policy='require' name='perfctr_nb'/>
   <feature policy='require' name='invtsc'/>
   <feature policy='require' name='clzero'/>
+  <feature policy='require' name='xsaveerptr'/>
   <feature policy='require' name='wbnoinvd'/>
+  <feature policy='require' name='amd-stibp'/>
   <feature policy='require' name='amd-ssbd'/>
   <feature policy='require' name='rdctl-no'/>
   <feature policy='require' name='skip-l1dfl-vmentry'/>
diff --git a/tests/cputestdata/x86_64-cpuid-Ryzen-9-3900X-12-Core-host.xml b/tests/cputestdata/x86_64-cpuid-Ryzen-9-3900X-12-Core-host.xml
index dee05585aa..478d5b7ab5 100644
--- a/tests/cputestdata/x86_64-cpuid-Ryzen-9-3900X-12-Core-host.xml
+++ b/tests/cputestdata/x86_64-cpuid-Ryzen-9-3900X-12-Core-host.xml
@@ -22,7 +22,9 @@
   <feature name='perfctr_nb'/>
   <feature name='invtsc'/>
   <feature name='clzero'/>
+  <feature name='xsaveerptr'/>
   <feature name='wbnoinvd'/>
+  <feature name='amd-stibp'/>
   <feature name='amd-ssbd'/>
   <feature name='rdctl-no'/>
   <feature name='skip-l1dfl-vmentry'/>
diff --git a/tests/cputestdata/x86_64-cpuid-Ryzen-9-3900X-12-Core-json.xml b/tests/cputestdata/x86_64-cpuid-Ryzen-9-3900X-12-Core-json.xml
index 735ec8ea2d..a64e9fe1e5 100644
--- a/tests/cputestdata/x86_64-cpuid-Ryzen-9-3900X-12-Core-json.xml
+++ b/tests/cputestdata/x86_64-cpuid-Ryzen-9-3900X-12-Core-json.xml
@@ -15,6 +15,7 @@
   <feature policy='require' name='cmp_legacy'/>
   <feature policy='require' name='perfctr_core'/>
   <feature policy='require' name='clzero'/>
+  <feature policy='require' name='xsaveerptr'/>
   <feature policy='require' name='wbnoinvd'/>
   <feature policy='require' name='amd-ssbd'/>
   <feature policy='require' name='virt-ssbd'/>
diff --git a/tests/domaincapsdata/qemu_5.1.0-q35.x86_64.xml b/tests/domaincapsdata/qemu_5.1.0-q35.x86_64.xml
index 6b061b82de..43a2142a9f 100644
--- a/tests/domaincapsdata/qemu_5.1.0-q35.x86_64.xml
+++ b/tests/domaincapsdata/qemu_5.1.0-q35.x86_64.xml
@@ -53,7 +53,9 @@
       <feature policy='require' name='perfctr_core'/>
       <feature policy='require' name='invtsc'/>
       <feature policy='require' name='clzero'/>
+      <feature policy='require' name='xsaveerptr'/>
       <feature policy='require' name='wbnoinvd'/>
+      <feature policy='require' name='amd-stibp'/>
       <feature policy='require' name='amd-ssbd'/>
       <feature policy='require' name='virt-ssbd'/>
       <feature policy='require' name='rdctl-no'/>
diff --git a/tests/domaincapsdata/qemu_5.1.0.x86_64.xml b/tests/domaincapsdata/qemu_5.1.0.x86_64.xml
index def35db95f..aeede0bac6 100644
--- a/tests/domaincapsdata/qemu_5.1.0.x86_64.xml
+++ b/tests/domaincapsdata/qemu_5.1.0.x86_64.xml
@@ -52,7 +52,9 @@
       <feature policy='require' name='perfctr_core'/>
       <feature policy='require' name='invtsc'/>
       <feature policy='require' name='clzero'/>
+      <feature policy='require' name='xsaveerptr'/>
       <feature policy='require' name='wbnoinvd'/>
+      <feature policy='require' name='amd-stibp'/>
       <feature policy='require' name='amd-ssbd'/>
       <feature policy='require' name='virt-ssbd'/>
       <feature policy='require' name='rdctl-no'/>
-- 
2.27.0




More information about the libvir-list mailing list