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

[Xen-devel] [PATCH v3] Xen missing prompt log when exec-sp=off


  • To: "xen-devel@xxxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxxx>
  • From: Jin Nan Wang <jnwang@xxxxxxxx>
  • Date: Mon, 16 Dec 2019 11:42:40 +0000
  • Accept-language: zh-CN, en-US
  • Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=suse.com; dmarc=pass action=none header.from=suse.com; dkim=pass header.d=suse.com; arc=none
  • Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=XX2bNsAYyznEwbPdAAawQCv7bhHOmouQlK7BAJW0j/4=; b=azaXlvy4zK+3/ZFMjha+1R7CRkxmDRLOChfZ00zjzNsqFMJ842xFBXw9HxDz/cvR0sz5VJKOblVc61cPhKUIbZHzIdiIqIEGG5oRMN2kq4xcvErvyMWMAxFUozbwc5UWOHQLqJDg8tZPC6RfRvht7NPTqkH4MifM/32CR58uXD+EV+aV5Afp+AnMWAzLsAHGceJp1CmQ6kcX+faUIuYwRvCCQRyO13d07cCGE0u/gKcgdfr9ERmfqmGTOyFmzPEJh8bqQCeogPmh3Y2F2Dis0LXePYFPuRdOxkwJ4GbyAk7Tw/Vs7AW+14/jUbBuNCkRWPh5XWpMsDgDUA2s9Od6WQ==
  • Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=VCPBP9lyKDqfP2X8SxE9Dj4vwAAynfgHYCDYVBhWeFAilPbQpVYrs6srbNpzP36THhKg4fetCIjFlY8TZhAG9vCWM9PreNJZOy+K1ziOmOdSgT4eGQjwOrd2wHwsfrgyeFrQC4y6ASU0T+0cYsUWB0FFMMCxT2uFJeq+VbYRue1Y7U6BdyKnpkEZZAVEQu7WRZYygTaZc13iQjTldQMubkA9ITrD7gdboN+9iD81VKlWrQ1dboWYZ7raZvbxrs3JYn0bcpzR/LmeV9qIxrRp2hZJtsqkziXzT6cXwpEL3xEI6CgRpj04OP9GiPBMK0JRqRg6a+4PO4OgjwvCtp7UBQ==
  • Authentication-results: spf=none (sender IP is ) smtp.mailfrom=jnwang@xxxxxxxx;
  • Cc: Kevin Tian <kevin.tian@xxxxxxxxx>, Jun Nakajima <jun.nakajima@xxxxxxxxx>, Wei Liu <wl@xxxxxxx>, Andrew Cooper <andrew.cooper3@xxxxxxxxxx>, Jin Nan Wang <jnwang@xxxxxxxx>, Jan Beulich <JBeulich@xxxxxxxx>, Roger Pau Monné <roger.pau@xxxxxxxxxx>
  • Delivery-date: Mon, 16 Dec 2019 11:57:22 +0000
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
  • Thread-index: AQHVtAXsLvnVyOfn/Emg1UZSn6nYtQ==
  • Thread-topic: [PATCH v3] Xen missing prompt log when exec-sp=off

Fix a issue when user disable ETP exec-sp, xen missed a prompt
log in dmesg.

Signed-off-by: James Wang <jnwang@xxxxxxxx>
---
 xen/arch/x86/hvm/vmx/vmx.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/xen/arch/x86/hvm/vmx/vmx.c b/xen/arch/x86/hvm/vmx/vmx.c
index 7970ba93e1..9dcb100210 100644
--- a/xen/arch/x86/hvm/vmx/vmx.c
+++ b/xen/arch/x86/hvm/vmx/vmx.c
@@ -2495,14 +2495,14 @@ const struct hvm_function_table * __init start_vmx(void)
     {
         bool cpu_has_bug_pschange_mc = has_if_pschange_mc();
 
+        /* Default to non-executable superpages on vulnerable hardware. */
         if ( opt_ept_exec_sp == -1 )
-        {
-            /* Default to non-executable superpages on vulnerable hardware. */
             opt_ept_exec_sp = !cpu_has_bug_pschange_mc;
 
-            if ( cpu_has_bug_pschange_mc )
-                printk("VMX: Disabling executable EPT superpages due to 
CVE-2018-12207\n");
-        }
+        if ( opt_ept_exec_sp )
+            printk("VMX: Enable executable EPT superpages\n");
+        else 
+            printk("VMX: Disabling executable EPT superpages due to 
CVE-2018-12207\n");
 
         vmx_function_table.hap_supported = 1;
         vmx_function_table.altp2m_supported = 1;
-- 
2.24.0


_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxxx
https://lists.xenproject.org/mailman/listinfo/xen-devel

 


Rackspace

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