qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Qemu-devel] Add SPLIT_LOCK DETECT capability to SnowRidge (SNR) cpu mod


From: Paul Lai
Subject: [Qemu-devel] Add SPLIT_LOCK DETECT capability to SnowRidge (SNR) cpu model
Date: Wed, 26 Jun 2019 09:32:32 -0700

SPLIT_LOCK DETECT is enabled in qemu patch:
  x86: define a new MSR based feature word -- FEAT_CORE_CAPABILITY
and kernel patch series that includes:
  x86/split_lock: Align x86_capability to unsigned long to avoid split locked
access

WAITPKG (UMONITOR/UMWAIT/TPAUSE) supplied in:
      x86/cpu: Add support for UMONITOR/UMWAIT/TPAUSE
are turned off by default, so not added to this cpu model.

Signed-off-by: Paul Lai <address@hidden>
Tested-by: Tao3 Xu <address@hidden>

---
Changes in v4:
        Add SPLIT_LOCK DETECT capability to SnowRidge (SNR) cpu model
---
 target/i386/cpu.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/target/i386/cpu.c b/target/i386/cpu.c
index c96f032f03..63d89276fe 100644
--- a/target/i386/cpu.c
+++ b/target/i386/cpu.c
@@ -2739,7 +2739,10 @@ static X86CPUDefinition builtin_x86_defs[] = {
             CPUID_7_0_ECX_MOVDIR64B,
         .features[FEAT_7_0_EDX] =
             CPUID_7_0_EDX_SPEC_CTRL |
-            CPUID_7_0_EDX_ARCH_CAPABILITIES | CPUID_7_0_EDX_SPEC_CTRL_SSBD,
+            CPUID_7_0_EDX_ARCH_CAPABILITIES | CPUID_7_0_EDX_SPEC_CTRL_SSBD |
+            CPUID_7_0_EDX_CORE_CAPABILITY,
+        .features[FEAT_CORE_CAPABILITY] =
+            MSR_CORE_CAP_SPLIT_LOCK_DETECT,
         /*
          * Missing: XSAVES (not supported by some Linux versions,
          * including v4.1 to v4.12).
-- 
2.17.2




reply via email to

[Prev in Thread] Current Thread [Next in Thread]