From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail.skyhub.de (mail.skyhub.de [5.9.137.197]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 93F3A68 for ; Fri, 12 Nov 2021 21:37:53 +0000 (UTC) Received: from zn.tnic (p4fed33a9.dip0.t-ipconnect.de [79.237.51.169]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.skyhub.de (SuperMail on ZX Spectrum 128k) with ESMTPSA id B53951EC0554; Fri, 12 Nov 2021 22:37:51 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=alien8.de; s=dkim; t=1636753071; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:in-reply-to:in-reply-to: references:references; bh=A0iII0qVuog0Us7YryaxXrUyUW2CBNn6Ykbyj7Igh68=; b=YZuttsgWwb+WKurJdCNhc5NmHv25S0MaUbJTuzppmjXZ5dM8Uni2tWbVFdStd/xywoMfx+ +/9Pfb/VS/49AlbSRQyGMxHJ72nLMZG28+TdmLG3H76n816eT7L+S5RoOkum81AS5YwwQm wdE1jX0Drz1biV+Y775fQOs2z+IaMhg= Date: Fri, 12 Nov 2021 22:35:35 +0100 From: Borislav Petkov To: Andy Lutomirski Cc: Marc Orr , Sean Christopherson , Dave Hansen , Peter Gonda , Brijesh Singh , 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 , Dave Hansen , Sergio Lopez , Peter Zijlstra , Srinivas Pandruvada , David Rientjes , Dov Murik , Tobin Feldman-Fitzthum , Michael Roth , Vlastimil Babka , "Kirill A . Shutemov" , Andi Kleen , tony.luck@intel.com, sathyanarayanan.kuppuswamy@linux.intel.com Subject: Re: [PATCH Part2 v5 00/45] Add AMD Secure Nested Paging (SEV-SNP) Hypervisor Support Message-ID: References: <20210820155918.7518-1-brijesh.singh@amd.com> <061ccd49-3b9f-d603-bafd-61a067c3f6fa@intel.com> Precedence: bulk X-Mailing-List: linux-coco@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: On Fri, Nov 12, 2021 at 01:23:25PM -0800, Andy Lutomirski wrote: > SEV-SNP, TDX, and any reasonable software solution all require that the host > know which pages are private and which pages are shared. Sure, the old > SEV-ES Linux host implementation was very simple, but it's nasty and > fundamentally can't support migration. Right, so at least SNP guests need to track which pages have been already PVALIDATEd by them so that they don't validate them again. So if we track that somewhere in struct page or wherever, that same bit can be used to state, page is private or shared. -- Regards/Gruss, Boris. https://people.kernel.org/tglx/notes-about-netiquette