Received: by 2002:a05:6358:f14:b0:e5:3b68:ec04 with SMTP id b20csp26230rwj; Thu, 22 Dec 2022 04:33:02 -0800 (PST) X-Google-Smtp-Source: AMrXdXtCNB1OBwasAdatJ8ClqvHPh5nx/AecdnO7XB4jh+gvIeboClDWdiMnD/uIxfpLXgmYU7YN X-Received: by 2002:a05:6402:e83:b0:463:c4f5:ad1f with SMTP id h3-20020a0564020e8300b00463c4f5ad1fmr5160886eda.11.1671712382546; Thu, 22 Dec 2022 04:33:02 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1671712382; cv=none; d=google.com; s=arc-20160816; b=TE2n0akb9LbmyqnhqaTvSe8LXkifX9h9g8edClwWsITpf+S3MdXz7nLacNoS0H4VhB KGVlKxJAQwN9wUoQl1GEfuNYimshmqAm0YiR2+VKPe9PlmQk7CPUvP0hduOArTdyJ7hd l8FVUdkzQmgmwFyBvBIhS1fMMQwhTcsnxGpvytvmC32DTvGnibW66jOkk/nGjDOaygXd ahWOZD9DZ8NReq6nd6Jhp5sgR14E5AU7l/X4YpDk5qntz2uRLFiHpVL361NKB9PHKar3 bsiaXC6e4FjSisB+I+F9W0hno3FUW0Ynkjpw8X+CcOmJmfUqYGs85MhREbU4LWBAwnxk kdfQ== 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=77VLJhO0dwLBle+8mUKiXvGfN/pazGch3mXeBUAPVPY=; b=WZcVN4Naboitq8BMgbkVQZ/AfD0p8HHni3t+XW2M+nzsz/cSMhUV3LOwBXZqe5Shoi Jvp7S7G8dh9WmPUQTTteTH4kdO3c1YrgE7wxfs+3Z6zPRYm7TOn6k9tr4S9Ky6rMhe9l 2OpIBJ5btnfgpK9lCowFbOoBDn2s90M3OIe2HPC8fI91NYHD4RDlBYVnOj+7OlVz+pzV TVu76Li+wccNXelXR9X/yP9rL3e/LdEU/63VCKbfM4oCm/DRX0aWtisPBbWiX5Rm2qhx dsMrxJp3EvQbtM7JT/JjU8tRKoj+jYvUbMker3dFfraEHF/N+u6/IONBb7R+E8HUG4r6 VNaA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@alien8.de header.s=dkim header.b=lOSb1jh+; spf=pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-crypto-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=alien8.de Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id qk37-20020a1709077fa500b0078e1e77f443si348537ejc.418.2022.12.22.04.32.36; Thu, 22 Dec 2022 04:33:02 -0800 (PST) Received-SPF: pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@alien8.de header.s=dkim header.b=lOSb1jh+; spf=pass (google.com: domain of linux-crypto-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-crypto-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=alien8.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234764AbiLVM0f (ORCPT + 99 others); Thu, 22 Dec 2022 07:26:35 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:53136 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234727AbiLVM0e (ORCPT ); Thu, 22 Dec 2022 07:26:34 -0500 Received: from mail.skyhub.de (mail.skyhub.de [5.9.137.197]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 655E3E0B8; Thu, 22 Dec 2022 04:26:33 -0800 (PST) Received: from zn.tnic (p5de8e9fe.dip0.t-ipconnect.de [93.232.233.254]) (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 EF42D1EC0715; Thu, 22 Dec 2022 13:26:31 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=alien8.de; s=dkim; t=1671711992; 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=77VLJhO0dwLBle+8mUKiXvGfN/pazGch3mXeBUAPVPY=; b=lOSb1jh+bt4haey43HIMtwFGaW08ydiHmgjk3xxfbBWGiMNXQk23xbiaUrYp90mvplWzPC 2cHavs6VQEbZKGtynRweI+uHTVpXwFpzR2Lgv9R4Cva7Z+lS7RngC04mX3HhMe13k7ZmiS JrnB9euVlgqs+68jIwsnpPYeoeI8Eik= Date: Thu, 22 Dec 2022 13:26:25 +0100 From: Borislav Petkov To: Michael Roth Cc: kvm@vger.kernel.org, linux-coco@lists.linux.dev, linux-mm@kvack.org, linux-crypto@vger.kernel.org, x86@kernel.org, linux-kernel@vger.kernel.org, tglx@linutronix.de, mingo@redhat.com, jroedel@suse.de, thomas.lendacky@amd.com, hpa@zytor.com, ardb@kernel.org, pbonzini@redhat.com, seanjc@google.com, vkuznets@redhat.com, wanpengli@tencent.com, jmattson@google.com, luto@kernel.org, dave.hansen@linux.intel.com, slp@redhat.com, pgonda@google.com, peterz@infradead.org, srinivas.pandruvada@linux.intel.com, rientjes@google.com, dovmurik@linux.ibm.com, tobin@ibm.com, vbabka@suse.cz, kirill@shutemov.name, ak@linux.intel.com, tony.luck@intel.com, marcorr@google.com, sathyanarayanan.kuppuswamy@linux.intel.com, alpergun@google.com, dgilbert@redhat.com, jarkko@kernel.org, ashish.kalra@amd.com, harald@profian.com Subject: Re: [PATCH RFC v7 02/64] KVM: x86: Add KVM_CAP_UNMAPPED_PRIVATE_MEMORY Message-ID: References: <20221214194056.161492-1-michael.roth@amd.com> <20221214194056.161492-3-michael.roth@amd.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20221214194056.161492-3-michael.roth@amd.com> X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-crypto@vger.kernel.org On Wed, Dec 14, 2022 at 01:39:54PM -0600, Michael Roth wrote: > This mainly indicates to KVM that it should expect all private guest > memory to be backed by private memslots. Ideally this would work > similarly for others archs, give or take a few additional flags, but > for now it's a simple boolean indicator for x86. ... > diff --git a/include/uapi/linux/kvm.h b/include/uapi/linux/kvm.h > index c7e9d375a902..cc9424ccf9b2 100644 > --- a/include/uapi/linux/kvm.h > +++ b/include/uapi/linux/kvm.h > @@ -1219,6 +1219,7 @@ struct kvm_ppc_resize_hpt { > #define KVM_CAP_DIRTY_LOG_RING_ACQ_REL 223 > #define KVM_CAP_S390_PROTECTED_ASYNC_DISABLE 224 > #define KVM_CAP_MEMORY_ATTRIBUTES 225 > +#define KVM_CAP_UNMAPPED_PRIVATE_MEM 240 Isn't this new cap supposed to be documented somewhere in Documentation/virt/kvm/api.rst ? -- Regards/Gruss, Boris. https://people.kernel.org/tglx/notes-about-netiquette