Received: by 2002:a05:6a10:5bc5:0:0:0:0 with SMTP id os5csp3847039pxb; Wed, 13 Oct 2021 14:22:04 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx9L4aLNxBtTbkxBkfoLL8QnG9C9LTwDNgc//6How5PwXFv7hQp72VGTR0Htr9oyzDJIbjZ X-Received: by 2002:a05:6402:14cc:: with SMTP id f12mr2757279edx.242.1634160124477; Wed, 13 Oct 2021 14:22:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1634160124; cv=none; d=google.com; s=arc-20160816; b=uToqd88OycJP+EnoI96apqNcNn1VAVLxoy88jPk1pLEtOPfa8L7dYFqcLhzR0/hS+C uQZ9qQXQKN3mbGI1nGKOiTlPeaZ8MsE43GKXzLC8ezWcCrFEOSqudGRJn6Du9qCW61Kg jstshJRewSA79omxaXfXhCt4j+BiALXy6fCp51TuDtY6p/6W5WnzhqCK624G3o+CExp0 PaZjD1fa+gMLzk6cDED1qeBZWqxRjm3pfEEt24D2S15YFwmG4rnGcnzYC/iATbLrEeZL 5IbVAFQhigDPOVRJR+3HdnA2ysEvagwtAP6A7sL78Ko/goAv33kiX+vBqa2OmJ8fMQnA S+Dw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=RGN5XybAu/ZhV4g4WKdQdjzcI3C7PMTK/Om4cnVrUpo=; b=mre2Jb19IBJJCdZGv+W4UvN/DeqtNDc8O/3V76vt+1wwCyy2x68QNcqJHNgvXFV/F6 26/ixuCuwq+e6u0EZ7+f4AGU2YqdkvyCy/6nfbjjnUM2nHMQoyPM6YOx//mer+1m4xWB YC0ZcqeALSBZkC2nilxVPPPjov+gX9DGLVisfFC7yFa6zV5VkVT3yuvhA1bWBATzb8qg 0PsFsYfmsSocL7OkcgAaCq/tspzikyjkdXkLH47xP4s/IiSA04joNiXEb5HZVCfoZUU0 NBaCG8TrLETBGmNzh2ItcRnDx+RoPz6PbW8QhWe1DXwEIVkX9IJCwkz9VIK6kKE+tdhA 2TVg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20210112 header.b=URyt4OiW; spf=pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-crypto-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id 26si916762ejl.744.2021.10.13.14.21.10; Wed, 13 Oct 2021 14:22:04 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20210112 header.b=URyt4OiW; spf=pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-crypto-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230161AbhJMVWT (ORCPT + 99 others); Wed, 13 Oct 2021 17:22:19 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60908 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230150AbhJMVWS (ORCPT ); Wed, 13 Oct 2021 17:22:18 -0400 Received: from mail-pj1-x1035.google.com (mail-pj1-x1035.google.com [IPv6:2607:f8b0:4864:20::1035]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 203F3C061749 for ; Wed, 13 Oct 2021 14:20:15 -0700 (PDT) Received: by mail-pj1-x1035.google.com with SMTP id q10-20020a17090a1b0a00b001a076a59640so4344360pjq.0 for ; Wed, 13 Oct 2021 14:20:15 -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=RGN5XybAu/ZhV4g4WKdQdjzcI3C7PMTK/Om4cnVrUpo=; b=URyt4OiWOZC9rK5oCCWsfUHOqUulNfj8PNGEdBZtuq6KCLHghJJH1K2XFPqHe+8A7y 56MHd6S8jFcLp7x91lXskW43i/kaf10KdqkU+LjqEdBmY1cKnBADOUyg4E/e4bVlRSQp sXUn2UHFAJtGCxOdV+33RGRos4gvcpAsM+/EJTmf+5mshqUfa6AWpZCOYewLATdcJgXI TxHeqzIogq3Ec9tg0+7AUlZcDaZe7URCgnMuLvWHocz/izBx/kV3wTyYKYYLhxcPOZto 2M98Jb9p2C4x5nYV+q1yvkyuEtlMcPzrwMzIvIq0Trd1MB/16Mx/Re0M5DPMChi+vAnM rtUw== 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=RGN5XybAu/ZhV4g4WKdQdjzcI3C7PMTK/Om4cnVrUpo=; b=36Zchl479IpfyuKr6S09u/4zb2E8g+R2gv8Gz35mxzA9t/xh1rkXxJhc/00Ref3RXS 8NqSh3ZMwpyZ8kws6nbp5fS7iStx4lStlS/6GlaSCIt0XGzFyNgthX1NXYjyCxntP5wi y0/KYVHCvjl7hZBYprF4uWEgFdismF79IWEASZ5o5aIyF+9eqbcNrRRTmBvkel86z7Uk 5t6OPQWyKCZrqJigSovgqB5Roaq/sGbuqlUyiP/gMhkcNzdNf348MIbV6ZmwozjoZe1V bo4C5yC6lB/7nyQSd83bxBfzf0pYmcJGIygJZaRH2OwXcJZOmvbBqCQJlzpXf8yxO8eb Ij2A== X-Gm-Message-State: AOAM532wIZxdHHiudQNghbT7MxvSOyDfUxR205IVbKRFghtK2zXsJZkI MysfC4rju4j3bUVFSCxz2pxt4Q== X-Received: by 2002:a17:90b:30d6:: with SMTP id hi22mr16321219pjb.4.1634160014413; Wed, 13 Oct 2021 14:20:14 -0700 (PDT) Received: from google.com (157.214.185.35.bc.googleusercontent.com. [35.185.214.157]) by smtp.gmail.com with ESMTPSA id u12sm414951pgi.21.2021.10.13.14.20.13 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 13 Oct 2021 14:20:13 -0700 (PDT) Date: Wed, 13 Oct 2021 21:20:10 +0000 From: Sean Christopherson To: Brijesh Singh Cc: x86@kernel.org, linux-kernel@vger.kernel.org, kvm@vger.kernel.org, linux-coco@lists.linux.dev, linux-mm@kvack.org, linux-crypto@vger.kernel.org, Thomas Gleixner , Ingo Molnar , Joerg Roedel , Tom Lendacky , "H. Peter Anvin" , Ard Biesheuvel , Paolo Bonzini , Vitaly Kuznetsov , Wanpeng Li , Jim Mattson , Andy Lutomirski , Dave Hansen , Sergio Lopez , Peter Gonda , Peter Zijlstra , Srinivas Pandruvada , David Rientjes , Dov Murik , Tobin Feldman-Fitzthum , Borislav Petkov , Michael Roth , Vlastimil Babka , "Kirill A . Shutemov" , Andi Kleen , tony.luck@intel.com, marcorr@google.com, sathyanarayanan.kuppuswamy@linux.intel.com Subject: Re: [PATCH Part2 v5 34/45] KVM: SVM: Do not use long-lived GHCB map while setting scratch area Message-ID: References: <20210820155918.7518-1-brijesh.singh@amd.com> <20210820155918.7518-35-brijesh.singh@amd.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20210820155918.7518-35-brijesh.singh@amd.com> Precedence: bulk List-ID: X-Mailing-List: linux-crypto@vger.kernel.org On Fri, Aug 20, 2021, Brijesh Singh wrote: > The setup_vmgexit_scratch() function may rely on a long-lived GHCB > mapping if the GHCB shared buffer area was used for the scratch area. > In preparation for eliminating the long-lived GHCB mapping, always > allocate a buffer for the scratch area so it can be accessed without > the GHCB mapping. Would it make sense to post this patch and the next (Remove the long-lived GHCB host map) in a separate mini-series? It's needed for SNP, but AFAICT there's nothing that depends on SNP. Getting this merged ahead of time would reduce the size of the SNP series by a smidge.