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

[PATCH 6/8] x86/pv: allow reading FEATURE_CONTROL MSR


  • To: <xen-devel@xxxxxxxxxxxxxxxxxxxx>
  • From: Roger Pau Monne <roger.pau@xxxxxxxxxx>
  • Date: Mon, 17 Aug 2020 17:57:55 +0200
  • Authentication-results: esa3.hc3370-68.iphmx.com; dkim=none (message not signed) header.i=none
  • Cc: Roger Pau Monne <roger.pau@xxxxxxxxxx>, Jan Beulich <jbeulich@xxxxxxxx>, Andrew Cooper <andrew.cooper3@xxxxxxxxxx>, Wei Liu <wl@xxxxxxx>
  • Delivery-date: Mon, 17 Aug 2020 15:59:11 +0000
  • Ironport-sdr: psHUZNUJszeD/YOQ4RAWn8l6IncFDipvG6HgL9CoWlpKyjX9kvhPX8S0vD9KDw9vmZaFLQQvwo FGYbJBdCxEznULhhTYbxYkgIgxQD2jBkxgFDbn0cX3GcMygeeRd4I8HyzDR5iAUpHOSMvOWYn8 WVx9Xd4bKXOjUsTUQhOuxNdioay/fbjCk9caK9YlyopaIBiP/cLwrHDLGekvb/vflGLEJ5NFEX cQJwoqgZ9Vyil3SivC35Mvk37SgVuDHtC3/TNYLykpo0W0EwOq3WMgOTDY0vcypH5JWKEni+5g R/c=
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>

Linux PV guests will attempt to read the FEATURE_CONTROL MSR, report
no features enabled or available, and that the MSR is already locked.

Signed-off-by: Roger Pau Monné <roger.pau@xxxxxxxxxx>
---
 xen/arch/x86/pv/emul-priv-op.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/xen/arch/x86/pv/emul-priv-op.c b/xen/arch/x86/pv/emul-priv-op.c
index 554a95ae8d..76c878b677 100644
--- a/xen/arch/x86/pv/emul-priv-op.c
+++ b/xen/arch/x86/pv/emul-priv-op.c
@@ -879,6 +879,10 @@ static int read_msr(unsigned int reg, uint64_t *val,
             *val |= APIC_BASE_BSP;
         return X86EMUL_OKAY;
 
+    case MSR_IA32_FEATURE_CONTROL:
+        *val = IA32_FEATURE_CONTROL_LOCK;
+        return X86EMUL_OKAY;
+
     case MSR_FS_BASE:
         if ( is_pv_32bit_domain(currd) )
             break;
-- 
2.28.0




 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.