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 03E8CC54FB9 for ; Tue, 21 Nov 2023 10:04:34 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234202AbjKUKEf (ORCPT ); Tue, 21 Nov 2023 05:04:35 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59294 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232462AbjKUKEd (ORCPT ); Tue, 21 Nov 2023 05:04:33 -0500 Received: from mgamail.intel.com (mgamail.intel.com [134.134.136.126]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 23EEFF5; Tue, 21 Nov 2023 02:04:30 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1700561070; x=1732097070; h=date:from:to:cc:subject:message-id:references: mime-version:in-reply-to; bh=8gnQy3DoUBVgZgIiqzEiYYxsRhdFMGruPTOBwuYMfzo=; b=I4u0HnMQTlw4HC94zXwdobiAT4g/1y/y4fEkq3B8NEJ1MKxz8AgVGGcA WUowDY4GQsZsFdOrGI7bXRyHM7Io3yIWP0BVdBh1BHuRtDp3azu4cSW1n YZrx/lkyEqX0gTlat7TS6T6asJUBynJ5CF50BHur0F4sZ99ax/dABXOYU qTYrdOWpTKaJZ7jCtI925UfqSlaFjRd6lJ0+Kb1w7TCyv2Am9l//V9aIM u3i1AzYYOL6Ueef7j63DT2Kw4ne+yguSAG0q2Lc1CtfTq9WQQbtp0aoRx 9zZ4fXkOzPEBl/7PVMWBkTJecUXsaIiAoXzSf3WfBma0hbkHKnH+nH2gN A==; X-IronPort-AV: E=McAfee;i="6600,9927,10900"; a="376842924" X-IronPort-AV: E=Sophos;i="6.04,215,1695711600"; d="scan'208";a="376842924" Received: from fmsmga007.fm.intel.com ([10.253.24.52]) by orsmga106.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 21 Nov 2023 02:04:19 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10900"; a="770212819" X-IronPort-AV: E=Sophos;i="6.04,215,1695711600"; d="scan'208";a="770212819" Received: from ls.sc.intel.com (HELO localhost) ([172.25.112.31]) by fmsmga007-auth.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 21 Nov 2023 02:04:18 -0800 Date: Tue, 21 Nov 2023 02:04:18 -0800 From: Isaku Yamahata To: Binbin Wu Cc: isaku.yamahata@intel.com, kvm@vger.kernel.org, linux-kernel@vger.kernel.org, isaku.yamahata@gmail.com, Paolo Bonzini , erdemaktas@google.com, Sean Christopherson , Sagi Shahar , David Matlack , Kai Huang , Zhi Wang , chen.bo@intel.com, hang.yuan@intel.com, tina.zhang@intel.com, Xiaoyao Li , isaku.yamahata@linux.intel.com Subject: Re: [PATCH v6 08/16] KVM: TDX: Pin pages via get_page() right before ADD/AUG'ed to TDs Message-ID: <20231121100418.GF1109547@ls.amr.corp.intel.com> References: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Nov 20, 2023 at 07:05:39PM +0800, Binbin Wu wrote: > > > On 11/7/2023 11:00 PM, isaku.yamahata@intel.com wrote: > > From: Xiaoyao Li > > > > When kvm_faultin_pfn(), it doesn't have the info regarding which page level > > will the gfn be mapped at. Hence it doesn't know to pin a 4K page or a > > 2M page. > > > > Move the guest private pages pinning logic right before > > TDH_MEM_PAGE_ADD/AUG() since at that time it knows the page level info. > This patch looks strange, the code has nothing to do with the shortlog. > It seems that the change of this patch has already been covered by 06/16. > > Something went wrong when formatting the patch? Oh, right. This patch doesn't make sense any more. I''ll drop this patch. -- Isaku Yamahata