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 Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 05BC5C43334 for ; Thu, 7 Jul 2022 19:30:33 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236035AbiGGTab (ORCPT ); Thu, 7 Jul 2022 15:30:31 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:47208 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S236193AbiGGTa1 (ORCPT ); Thu, 7 Jul 2022 15:30:27 -0400 Received: from mail-pf1-x42a.google.com (mail-pf1-x42a.google.com [IPv6:2607:f8b0:4864:20::42a]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3168C25E82 for ; Thu, 7 Jul 2022 12:30:26 -0700 (PDT) Received: by mail-pf1-x42a.google.com with SMTP id w185so17666433pfb.4 for ; Thu, 07 Jul 2022 12:30:26 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20210112; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=7X+8JGW1uNiGyJFuWhjxVYDvmw+5zjyFaO0LL98jJNs=; b=f3jXwLVz2z3coCJPhg3sCWYTft0tpmBGhJfNSzx9uubtpEK5/zCnpoceqqn+2baexp UOG/qaD/IdGjB5RFbgMAsXUmDxM5p50x32BaxHkCasLSuA6G90ibOyNyL20B4lP7y2mn VtJNn2LWPhW+SHv+sp0CQVNP6PVZatmtJ8urY/tzTCb3Tj7KJt+zUPY/G64BKNgDG6ef 1T0QitOGrMhzoC4XOhuaJhrH6cA0qAi/BOcr2hvXzngEWFzYbPqaojK6z9G3ZA+5pF68 OOmPZ3YSKwU4uEPAC0ePkXef1HBj5UMyDcy07XWQB3+LPDRqQS2WompLZYaIu6H7T456 wNZg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=7X+8JGW1uNiGyJFuWhjxVYDvmw+5zjyFaO0LL98jJNs=; b=7N8Ms7n2dsBRhiQ6y9Tq43c4BwDucibp2gco/Yd6X6JUW+9CU7xYNZ1W+2tpXivySD V3ydKNVQBATJbTysnwYk+nmZDB42WwyPDhpGPIoWGhyC69hvixB357H2yV4XZ9RVsONc Brwc63vlcaJQweAujwP+yefvgE3RpCdSvANyoptzFmhHfgklHPco8+tHjdUE6/gOAXAE g0VJv71G2YrSKJQFUPTqXxCOP0fnsjXX1TDN+fQGlv2e1dJGlny3TfYnL6GdbRAqjAei x48PZx2z/u32YbNvV7AltMMbyToMoeg4ZIfMQ8c0JVo1yE09QHlwORRZX0uj9YzZAva2 ndLw== X-Gm-Message-State: AJIora/KGg59tm+RRQ7tgSOSSf8oOLHTytxxmAbqCnNbkAfWQL8Ap/Zv w8ruiEfTwNJMErslhNqbetqv2g== X-Google-Smtp-Source: AGRyM1ugIK1dp8lBkhHZvJzvmmKPHEtOABiIXVxNedJp6c66Y2uykzFwihBhwKUnh8y/mnoaPSqUUQ== X-Received: by 2002:a17:903:20f:b0:16b:d01c:d689 with SMTP id r15-20020a170903020f00b0016bd01cd689mr32034998plh.92.1657222225556; Thu, 07 Jul 2022 12:30:25 -0700 (PDT) Received: from google.com (123.65.230.35.bc.googleusercontent.com. [35.230.65.123]) by smtp.gmail.com with ESMTPSA id x124-20020a626382000000b00525231e15ccsm27409785pfb.113.2022.07.07.12.30.24 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 07 Jul 2022 12:30:25 -0700 (PDT) Date: Thu, 7 Jul 2022 19:30:21 +0000 From: Sean Christopherson To: Vitaly Kuznetsov Cc: Jim Mattson , kvm@vger.kernel.org, Paolo Bonzini , Anirudh Rayabharam , Wanpeng Li , Maxim Levitsky , linux-hyperv@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v2 22/28] KVM: VMX: Clear controls obsoleted by EPT at runtime, not setup Message-ID: References: <20220629150625.238286-1-vkuznets@redhat.com> <20220629150625.238286-23-vkuznets@redhat.com> <87wncpotqv.fsf@redhat.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <87wncpotqv.fsf@redhat.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Jul 07, 2022, Vitaly Kuznetsov wrote: > Jim Mattson writes: > > > On Wed, Jun 29, 2022 at 8:07 AM Vitaly Kuznetsov wrote: > >> > >> From: Sean Christopherson > >> > >> Clear the CR3 and INVLPG interception controls at runtime based on > >> whether or not EPT is being _used_, as opposed to clearing the bits at > >> setup if EPT is _supported_ in hardware, and then restoring them when EPT > >> is not used. Not mucking with the base config will allow using the base > >> config as the starting point for emulating the VMX capability MSRs. > >> > >> Signed-off-by: Sean Christopherson > >> Signed-off-by: Vitaly Kuznetsov > > Nit: These controls aren't "obsoleted" by EPT; they're just no longer > > required. Isn't that the definition of "obsolete"? They're "no longer in use" when KVM enables EPT. > I'm going to update the subject line to "KVM: VMX: Clear controls > unneded with EPT at runtime, not setup" retaining your authorship in v3 That's fine, though s/unneded/unneeded.