render / rpms / libvirt

Forked from rpms/libvirt 9 months ago
Clone
bba56f
From c34ca3d596e641381b3397958be5f584f6318777 Mon Sep 17 00:00:00 2001
bba56f
Message-Id: <c34ca3d596e641381b3397958be5f584f6318777@dist-git>
bba56f
From: Jiri Denemark <jdenemar@redhat.com>
bba56f
Date: Mon, 25 Feb 2019 16:44:11 +0100
bba56f
Subject: [PATCH] cpu_map: Add more signatures for Westmere CPU model
bba56f
MIME-Version: 1.0
bba56f
Content-Type: text/plain; charset=UTF-8
bba56f
Content-Transfer-Encoding: 8bit
bba56f
bba56f
This fixes several CPUs which were incorrectly detected as a different
bba56f
CPU model.
bba56f
bba56f
Signed-off-by: Jiri Denemark <jdenemar@redhat.com>
bba56f
Reviewed-by: Ján Tomko <jtomko@redhat.com>
bba56f
(cherry picked from commit e89f87721406f6ad6e811ff613a22dc804d69355)
bba56f
bba56f
https://bugzilla.redhat.com/show_bug.cgi?id=1558558
bba56f
https://bugzilla.redhat.com/show_bug.cgi?id=1687515
bba56f
bba56f
Conflicts:
bba56f
	src/cpu_map/x86_Westmere.xml
bba56f
            - cpu_map split not backported
bba56f
bba56f
Signed-off-by: Jiri Denemark <jdenemar@redhat.com>
bba56f
Reviewed-by: Ján Tomko <jtomko@redhat.com>
bba56f
---
bba56f
 src/cpu/cpu_map.xml                                    |  2 ++
bba56f
 tests/cputestdata/x86_64-cpuid-Core-i5-650-json.xml    |  9 +++++----
bba56f
 tests/cputestdata/x86_64-cpuid-Pentium-P6100-guest.xml | 10 ++++++----
bba56f
 tests/cputestdata/x86_64-cpuid-Xeon-E7-4820-guest.xml  |  8 ++++----
bba56f
 tests/cputestdata/x86_64-cpuid-Xeon-E7-4820-json.xml   |  8 +++++---
bba56f
 tests/cputestdata/x86_64-cpuid-Xeon-E7-4830-json.xml   |  9 +++++----
bba56f
 6 files changed, 27 insertions(+), 19 deletions(-)
bba56f
bba56f
diff --git a/src/cpu/cpu_map.xml b/src/cpu/cpu_map.xml
bba56f
index 8733834071..1435a34bb9 100644
bba56f
--- a/src/cpu/cpu_map.xml
bba56f
+++ b/src/cpu/cpu_map.xml
bba56f
@@ -937,6 +937,8 @@
bba56f
 
bba56f
     <model name='Westmere'>
bba56f
       <signature family='6' model='44'/> 
bba56f
+      <signature family='6' model='47'/> 
bba56f
+      <signature family='6' model='37'/> 
bba56f
       <vendor name='Intel'/>
bba56f
       <feature name='aes'/>
bba56f
       <feature name='apic'/>
bba56f
diff --git a/tests/cputestdata/x86_64-cpuid-Core-i5-650-json.xml b/tests/cputestdata/x86_64-cpuid-Core-i5-650-json.xml
bba56f
index f5980f53e5..cb21e48a9f 100644
bba56f
--- a/tests/cputestdata/x86_64-cpuid-Core-i5-650-json.xml
bba56f
+++ b/tests/cputestdata/x86_64-cpuid-Core-i5-650-json.xml
bba56f
@@ -1,12 +1,13 @@
bba56f
 <cpu mode='custom' match='exact'>
bba56f
-  <model fallback='forbid'>SandyBridge</model>
bba56f
+  <model fallback='forbid'>Westmere</model>
bba56f
   <vendor>Intel</vendor>
bba56f
   <feature policy='require' name='vme'/>
bba56f
   <feature policy='require' name='ss'/>
bba56f
+  <feature policy='require' name='pclmuldq'/>
bba56f
+  <feature policy='require' name='x2apic'/>
bba56f
+  <feature policy='require' name='tsc-deadline'/>
bba56f
   <feature policy='require' name='hypervisor'/>
bba56f
   <feature policy='require' name='arat'/>
bba56f
   <feature policy='require' name='tsc_adjust'/>
bba56f
-  <feature policy='disable' name='xsave'/>
bba56f
-  <feature policy='disable' name='avx'/>
bba56f
-  <feature policy='disable' name='xsaveopt'/>
bba56f
+  <feature policy='require' name='rdtscp'/>
bba56f
 </cpu>
bba56f
diff --git a/tests/cputestdata/x86_64-cpuid-Pentium-P6100-guest.xml b/tests/cputestdata/x86_64-cpuid-Pentium-P6100-guest.xml
bba56f
index db5e0ae6af..20e2fa363a 100644
bba56f
--- a/tests/cputestdata/x86_64-cpuid-Pentium-P6100-guest.xml
bba56f
+++ b/tests/cputestdata/x86_64-cpuid-Pentium-P6100-guest.xml
bba56f
@@ -1,6 +1,7 @@
bba56f
 <cpu mode='custom' match='exact'>
bba56f
-  <model fallback='forbid'>core2duo</model>
bba56f
+  <model fallback='forbid'>Westmere</model>
bba56f
   <vendor>Intel</vendor>
bba56f
+  <feature policy='require' name='vme'/>
bba56f
   <feature policy='require' name='ds'/>
bba56f
   <feature policy='require' name='acpi'/>
bba56f
   <feature policy='require' name='ss'/>
bba56f
@@ -8,16 +9,17 @@
bba56f
   <feature policy='require' name='tm'/>
bba56f
   <feature policy='require' name='pbe'/>
bba56f
   <feature policy='require' name='dtes64'/>
bba56f
+  <feature policy='require' name='monitor'/>
bba56f
   <feature policy='require' name='ds_cpl'/>
bba56f
   <feature policy='require' name='est'/>
bba56f
   <feature policy='require' name='tm2'/>
bba56f
-  <feature policy='require' name='cx16'/>
bba56f
   <feature policy='require' name='xtpr'/>
bba56f
   <feature policy='require' name='pdcm'/>
bba56f
   <feature policy='require' name='pcid'/>
bba56f
-  <feature policy='require' name='popcnt'/>
bba56f
   <feature policy='require' name='arat'/>
bba56f
   <feature policy='require' name='rdtscp'/>
bba56f
-  <feature policy='require' name='lahf_lm'/>
bba56f
   <feature policy='require' name='invtsc'/>
bba56f
+  <feature policy='disable' name='sse4.1'/>
bba56f
+  <feature policy='disable' name='sse4.2'/>
bba56f
+  <feature policy='disable' name='aes'/>
bba56f
 </cpu>
bba56f
diff --git a/tests/cputestdata/x86_64-cpuid-Xeon-E7-4820-guest.xml b/tests/cputestdata/x86_64-cpuid-Xeon-E7-4820-guest.xml
bba56f
index dbf8580a0e..659779687a 100644
bba56f
--- a/tests/cputestdata/x86_64-cpuid-Xeon-E7-4820-guest.xml
bba56f
+++ b/tests/cputestdata/x86_64-cpuid-Xeon-E7-4820-guest.xml
bba56f
@@ -1,5 +1,5 @@
bba56f
 <cpu mode='custom' match='exact'>
bba56f
-  <model fallback='forbid'>SandyBridge</model>
bba56f
+  <model fallback='forbid'>Westmere</model>
bba56f
   <vendor>Intel</vendor>
bba56f
   <feature policy='require' name='vme'/>
bba56f
   <feature policy='require' name='ds'/>
bba56f
@@ -8,6 +8,7 @@
bba56f
   <feature policy='require' name='ht'/>
bba56f
   <feature policy='require' name='tm'/>
bba56f
   <feature policy='require' name='pbe'/>
bba56f
+  <feature policy='require' name='pclmuldq'/>
bba56f
   <feature policy='require' name='dtes64'/>
bba56f
   <feature policy='require' name='monitor'/>
bba56f
   <feature policy='require' name='ds_cpl'/>
bba56f
@@ -19,10 +20,9 @@
bba56f
   <feature policy='require' name='pdcm'/>
bba56f
   <feature policy='require' name='pcid'/>
bba56f
   <feature policy='require' name='dca'/>
bba56f
+  <feature policy='require' name='x2apic'/>
bba56f
   <feature policy='require' name='arat'/>
bba56f
   <feature policy='require' name='pdpe1gb'/>
bba56f
+  <feature policy='require' name='rdtscp'/>
bba56f
   <feature policy='require' name='invtsc'/>
bba56f
-  <feature policy='disable' name='tsc-deadline'/>
bba56f
-  <feature policy='disable' name='xsave'/>
bba56f
-  <feature policy='disable' name='avx'/>
bba56f
 </cpu>
bba56f
diff --git a/tests/cputestdata/x86_64-cpuid-Xeon-E7-4820-json.xml b/tests/cputestdata/x86_64-cpuid-Xeon-E7-4820-json.xml
bba56f
index d94a330f37..e8b74c5c30 100644
bba56f
--- a/tests/cputestdata/x86_64-cpuid-Xeon-E7-4820-json.xml
bba56f
+++ b/tests/cputestdata/x86_64-cpuid-Xeon-E7-4820-json.xml
bba56f
@@ -1,12 +1,14 @@
bba56f
 <cpu mode='custom' match='exact'>
bba56f
-  <model fallback='forbid'>SandyBridge</model>
bba56f
+  <model fallback='forbid'>Westmere</model>
bba56f
   <vendor>Intel</vendor>
bba56f
   <feature policy='require' name='vme'/>
bba56f
   <feature policy='require' name='ss'/>
bba56f
+  <feature policy='require' name='pclmuldq'/>
bba56f
   <feature policy='require' name='pcid'/>
bba56f
+  <feature policy='require' name='x2apic'/>
bba56f
+  <feature policy='require' name='tsc-deadline'/>
bba56f
   <feature policy='require' name='hypervisor'/>
bba56f
   <feature policy='require' name='tsc_adjust'/>
bba56f
   <feature policy='require' name='pdpe1gb'/>
bba56f
-  <feature policy='disable' name='xsave'/>
bba56f
-  <feature policy='disable' name='avx'/>
bba56f
+  <feature policy='require' name='rdtscp'/>
bba56f
 </cpu>
bba56f
diff --git a/tests/cputestdata/x86_64-cpuid-Xeon-E7-4830-json.xml b/tests/cputestdata/x86_64-cpuid-Xeon-E7-4830-json.xml
bba56f
index aae32bd7e2..da949ad25e 100644
bba56f
--- a/tests/cputestdata/x86_64-cpuid-Xeon-E7-4830-json.xml
bba56f
+++ b/tests/cputestdata/x86_64-cpuid-Xeon-E7-4830-json.xml
bba56f
@@ -1,14 +1,15 @@
bba56f
 <cpu mode='custom' match='exact'>
bba56f
-  <model fallback='forbid'>SandyBridge</model>
bba56f
+  <model fallback='forbid'>Westmere</model>
bba56f
   <vendor>Intel</vendor>
bba56f
   <feature policy='require' name='vme'/>
bba56f
   <feature policy='require' name='ss'/>
bba56f
+  <feature policy='require' name='pclmuldq'/>
bba56f
   <feature policy='require' name='pcid'/>
bba56f
+  <feature policy='require' name='x2apic'/>
bba56f
+  <feature policy='require' name='tsc-deadline'/>
bba56f
   <feature policy='require' name='hypervisor'/>
bba56f
   <feature policy='require' name='arat'/>
bba56f
   <feature policy='require' name='tsc_adjust'/>
bba56f
   <feature policy='require' name='pdpe1gb'/>
bba56f
-  <feature policy='disable' name='xsave'/>
bba56f
-  <feature policy='disable' name='avx'/>
bba56f
-  <feature policy='disable' name='xsaveopt'/>
bba56f
+  <feature policy='require' name='rdtscp'/>
bba56f
 </cpu>
bba56f
-- 
bba56f
2.21.0
bba56f