From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-0.7 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id A025BC2D0B1 for ; Fri, 7 Feb 2020 07:10:56 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 737E621741 for ; Fri, 7 Feb 2020 07:10:56 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726951AbgBGHKx convert rfc822-to-8bit (ORCPT ); Fri, 7 Feb 2020 02:10:53 -0500 Received: from szxga08-in.huawei.com ([45.249.212.255]:33966 "EHLO huawei.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726573AbgBGHKx (ORCPT ); Fri, 7 Feb 2020 02:10:53 -0500 Received: from DGGEMM404-HUB.china.huawei.com (unknown [172.30.72.57]) by Forcepoint Email with ESMTP id 811A1642D0DD1D05F4D5; Fri, 7 Feb 2020 15:10:49 +0800 (CST) Received: from dggeme764-chm.china.huawei.com (10.3.19.110) by DGGEMM404-HUB.china.huawei.com (10.3.20.212) with Microsoft SMTP Server (TLS) id 14.3.439.0; Fri, 7 Feb 2020 15:10:48 +0800 Received: from dggeme763-chm.china.huawei.com (10.3.19.109) by dggeme764-chm.china.huawei.com (10.3.19.110) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_CBC_SHA256_P256) id 15.1.1713.5; Fri, 7 Feb 2020 15:10:48 +0800 Received: from dggeme763-chm.china.huawei.com ([10.6.66.36]) by dggeme763-chm.china.huawei.com ([10.6.66.36]) with mapi id 15.01.1713.004; Fri, 7 Feb 2020 15:10:48 +0800 From: linmiaohe To: Vitaly Kuznetsov CC: "pbonzini@redhat.com" , "rkrcmar@redhat.com" , "sean.j.christopherson@intel.com" , "wanpengli@tencent.com" , "jmattson@google.com" , "joro@8bytes.org" , "tglx@linutronix.de" , "mingo@redhat.com" , "bp@alien8.de" , "hpa@zytor.com" , "kvm@vger.kernel.org" , "linux-kernel@vger.kernel.org" , "x86@kernel.org" Subject: Re: [Question] some questions about vmx Thread-Topic: [Question] some questions about vmx Thread-Index: AdXdhFgBwMZqZE9VSkyT5yW9VeTIJw== Date: Fri, 7 Feb 2020 07:10:48 +0000 Message-ID: <736f8beabe2046fdab0631f28f9d2b1f@huawei.com> Accept-Language: en-US Content-Language: zh-CN X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.173.221.158] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 8BIT MIME-Version: 1.0 X-CFilter-Loop: Reflected Sender: kvm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: kvm@vger.kernel.org Hi: Vitaly Kuznetsov writes: >linmiaohe writes: > >> About nWMX. >> When nested_vmx_handle_enlightened_vmptrld() return 0, it do not >> inject any exception or set rflags to Indicate VMLAUNCH instruction >> failed and skip this instruction. This would cause nested_vmx_run() > >Yes, it seems it can. > >nested_vmx_handle_enlightened_vmptrld() has two possible places where it can fail: > >kvm_vcpu_map() -- meaning that the guest passed some invalid GPA. >revision id check -- meaning that the supplied eVMCS is unsupported/garbage. > >I think the right behavior would be to nested_vmx_failInvalid() in both these cases. We can also check what genuing Hyper-V does. > Many thanks for your reply. I think this would be a problem too. And would you like to fix this potential problem? I have no idea how to fix this correctly... Thanks again.