Message ID | 20230220183847.59159-56-michael.roth@amd.com (mailing list archive) |
---|---|
State | New |
Headers | show
Return-Path: <owner-linux-mm@kvack.org> X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id A9BD2C636D6 for <linux-mm@archiver.kernel.org>; Mon, 20 Feb 2023 19:01:10 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 466DE6B0092; Mon, 20 Feb 2023 14:01:10 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 4166F6B0093; Mon, 20 Feb 2023 14:01:10 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 290656B0095; Mon, 20 Feb 2023 14:01:10 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0015.hostedemail.com [216.40.44.15]) by kanga.kvack.org (Postfix) with ESMTP id 18E396B0092 for <linux-mm@kvack.org>; Mon, 20 Feb 2023 14:01:10 -0500 (EST) Received: from smtpin18.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay08.hostedemail.com (Postfix) with ESMTP id D3D4814080B for <linux-mm@kvack.org>; Mon, 20 Feb 2023 19:01:09 +0000 (UTC) X-FDA: 80488587858.18.E452177 Received: from NAM12-MW2-obe.outbound.protection.outlook.com (mail-mw2nam12on2076.outbound.protection.outlook.com [40.107.244.76]) by imf25.hostedemail.com (Postfix) with ESMTP id 5B4C8A0026 for <linux-mm@kvack.org>; Mon, 20 Feb 2023 19:01:05 +0000 (UTC) Authentication-Results: imf25.hostedemail.com; dkim=pass header.d=amd.com header.s=selector1 header.b=DtUz3FYM; arc=pass ("microsoft.com:s=arcselector9901:i=1"); spf=pass (imf25.hostedemail.com: domain of Michael.Roth@amd.com designates 40.107.244.76 as permitted sender) smtp.mailfrom=Michael.Roth@amd.com; dmarc=pass (policy=quarantine) header.from=amd.com ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1676919665; h=from:from:sender: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:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=bhdLB+9fGVwgfwLdW0pGauuauXN7czdXY6hjutnQW1g=; b=N0jI68EkT0/8pK8+P3YiB+rX4S/WmnXr5yjxipNQ2kgNWQvr8YeNNqZ2o6fLV3LjI1R2Io /JV2r5Xy97/fxCP1B+RKgKUIfMG8oaG9nBVmddP++6M4IszOlETII4nCd06RHRz9VPy+Wj lBVoDO+PQwVrlEA0nsP05X0VbT6hcjo= ARC-Authentication-Results: i=2; imf25.hostedemail.com; dkim=pass header.d=amd.com header.s=selector1 header.b=DtUz3FYM; arc=pass ("microsoft.com:s=arcselector9901:i=1"); spf=pass (imf25.hostedemail.com: domain of Michael.Roth@amd.com designates 40.107.244.76 as permitted sender) smtp.mailfrom=Michael.Roth@amd.com; dmarc=pass (policy=quarantine) header.from=amd.com ARC-Seal: i=2; s=arc-20220608; d=hostedemail.com; t=1676919665; a=rsa-sha256; cv=pass; b=IJlD3WEQGZmD7QKEJMv4euaECEBx5w1jOTiO+V+7FMvglA90Gtf8mT6kafTO757uXcBskw CElUSRLUwRlnZ0fWvFzcEu3+p2lKKE2yy0oxxTOJaQlyvfZTMyhtm/jdM+DWIHqFWFP2G5 dGTR0hJu/ZwV9T54Inyi4TPbdIKdFmE= ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=DLDu94Nqnh9/vD1yUqt8QADAm08mbhkWREprrsfNLwl9tzkufTtVpAKG0/VVtxi0Eqw49eyQViT8tVrvYcHIyiP+DYTTd32g/nMcSUu6zp0x7G+0hj0WwhZG++MjMcicRDFOegv6veIdLgNS9nq6q7S0GJGru+UOofZIjetqHRtIbQZ3OsZmqpyZORRVejRuKFrjCJKqc5gcpJCd9cP5qsewj8JmXzptQetb5/XkEmtBIK+6LFBYnmOLLLxU3yJ9tJMH7H813NS6aEVGzTqmb9NP5GIC71GmSuQBkLRQsvVnvt7AXplMpmKfUOrdLfXSvX+RgWgVsoL066wnACvdXg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=bhdLB+9fGVwgfwLdW0pGauuauXN7czdXY6hjutnQW1g=; b=Zr+Bi4jFXsFxOQ4Hz5nZRBzJx3f7wEIR/b59kp27uG2n7MZPwo0e5XNeVxw5JMyyGSp2QeBc/F7NFbZKYojJ3cigJQgk4y+PBXRP0uccqbLjbfFHnW95oMb3J75HKKqbSB9zS+S/sdQK9pVsZvTgYM0bEjXiB0w8LMB1T/1YZcTbJRYgGuMHMl1smvaXPAYr3pJ+bpP9S8Tv0sUR0MzT1B3ixvBLeAvuxZT21KRJQt6csA+iuVTseZ1sUDiF3S7lZ/69RQYK7VILnZpTNJyoQCV1rlaYmQ2BLwkiuF1yB1tBLlAoFsIerIyYi9FsFXnJFzUbRONJIbkJGnG0jGL5mw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass (sender ip is 165.204.84.17) smtp.rcpttodomain=vger.kernel.org smtp.mailfrom=amd.com; dmarc=pass (p=quarantine sp=quarantine pct=100) action=none header.from=amd.com; dkim=none (message not signed); arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=bhdLB+9fGVwgfwLdW0pGauuauXN7czdXY6hjutnQW1g=; b=DtUz3FYMKqlsy4VdJNvf6rrjZ5X0RkEy5lOJSTU2T3awTQh3xKom3q/bh2slCozG0aet3xBiCz2ZJ4+zkBMXfo7CxH2CvzzbHXbFWV/m+HBbbTOwWzQS+UkF/cIekSBWSFROPKSylAxjXYWGHvtG3KQ49VvRBIum+9UFdp4uW+Q= Received: from MW4P222CA0023.NAMP222.PROD.OUTLOOK.COM (2603:10b6:303:114::28) by SN7PR12MB7810.namprd12.prod.outlook.com (2603:10b6:806:34c::17) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6111.20; Mon, 20 Feb 2023 19:01:02 +0000 Received: from CO1NAM11FT018.eop-nam11.prod.protection.outlook.com (2603:10b6:303:114:cafe::64) by MW4P222CA0023.outlook.office365.com (2603:10b6:303:114::28) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.6111.19 via Frontend Transport; Mon, 20 Feb 2023 19:01:02 +0000 X-MS-Exchange-Authentication-Results: spf=pass (sender IP is 165.204.84.17) smtp.mailfrom=amd.com; dkim=none (message not signed) header.d=none;dmarc=pass action=none header.from=amd.com; Received-SPF: Pass (protection.outlook.com: domain of amd.com designates 165.204.84.17 as permitted sender) receiver=protection.outlook.com; client-ip=165.204.84.17; helo=SATLEXMB04.amd.com; pr=C Received: from SATLEXMB04.amd.com (165.204.84.17) by CO1NAM11FT018.mail.protection.outlook.com (10.13.175.16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.20.6111.21 via Frontend Transport; Mon, 20 Feb 2023 19:01:02 +0000 Received: from localhost (10.180.168.240) by SATLEXMB04.amd.com (10.181.40.145) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.34; Mon, 20 Feb 2023 13:01:01 -0600 From: Michael Roth <michael.roth@amd.com> To: <kvm@vger.kernel.org> CC: <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>, <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>, <bp@alien8.de>, <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>, <nikunj.dadhania@amd.com>, Dionna Glaze <dionnaglaze@google.com>, "Thomas Lendacky" <Thomas.Lendacky@amd.com> Subject: [PATCH RFC v8 55/56] x86/sev: Document KVM_SEV_SNP_{G,S}ET_CERTS Date: Mon, 20 Feb 2023 12:38:46 -0600 Message-ID: <20230220183847.59159-56-michael.roth@amd.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20230220183847.59159-1-michael.roth@amd.com> References: <20230220183847.59159-1-michael.roth@amd.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-Originating-IP: [10.180.168.240] X-ClientProxiedBy: SATLEXMB03.amd.com (10.181.40.144) To SATLEXMB04.amd.com (10.181.40.145) X-EOPAttributedMessage: 0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: CO1NAM11FT018:EE_|SN7PR12MB7810:EE_ X-MS-Office365-Filtering-Correlation-Id: f41b3fd6-8231-470a-4532-08db1374cfb3 X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: e65c5ls0TTnpXU4cZJQW4nNcRpTjRarYf1eErEGrO6OXnOWPpla+eNKBdyqaSpWOEyCDvWA/4W9lhsYdoF7yvLyEwIeo/PR9dTxUFXEK14QMWGj+MVV8obywmfNFFKd9Z81/EP4GC7HWy0ZUF5YC1gN4pst9KV3h4RzGR5FX41gbwISznl6G2zrzaVqllQuKWuI389zL1Q8R9/HKPOmeuTQvurAO8mw4KJCWZEpylcY6AVeqCYpHuFy8Cax9b8VUO5zMiujQ8k78cZGi6oKyNW3wgDev/5NHv0xPL/APoYRRyqmczau6DOGW3y7dQW/gcyTZSWDDYaL+Jnm72OH7jnSHw0klAkFCU+I+ozTGslmwSvalE8O51aJpIzu9/SI4VWcQNhwmc8rRdmwhb9yLPb5QjBY3S61h2qkyV8xXY68agEXdbKIpz3WC6250dw6HzY9Agqwo5e6n4QIfMgN1D45dEa1pNNXGZgWsfUixOGnfza7LU8FMUt9ynJzVejswFNZd8I9RryxTrrTBhaYhDpa3LxGyZ2LcTH8giMugPKAlyPaXXbVhyLwawpLPbMJxXnFkmWgFK4cGKJ++3YYGNyhPwzyyiBsSfYZGk+lcsjq2JGnl7VWH2TdPWGWdo/2OSsq5SEETJXplsYDltAAJ4QBZAtJnHE3BRBNGIsWbhub+u9EXpKs+g66eM3mScwBMKRvh3aXatC2X4TIKdE4G8D67Px5dNj3dAi4x8lJSHqE= X-Forefront-Antispam-Report: CIP:165.204.84.17;CTRY:US;LANG:en;SCL:1;SRV:;IPV:CAL;SFV:NSPM;H:SATLEXMB04.amd.com;PTR:InfoDomainNonexistent;CAT:NONE;SFS:(13230025)(4636009)(396003)(346002)(376002)(136003)(39860400002)(451199018)(36840700001)(46966006)(40470700004)(2906002)(26005)(186003)(16526019)(41300700001)(356005)(82740400003)(44832011)(6666004)(1076003)(81166007)(2616005)(7416002)(5660300002)(36860700001)(7406005)(8936002)(478600001)(316002)(40460700003)(86362001)(70206006)(70586007)(6916009)(8676002)(4326008)(336012)(82310400005)(47076005)(40480700001)(426003)(36756003)(83380400001)(54906003)(36900700001);DIR:OUT;SFP:1101; X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 20 Feb 2023 19:01:02.3104 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: f41b3fd6-8231-470a-4532-08db1374cfb3 X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=3dd8961f-e488-4e60-8e11-a82d994e183d;Ip=[165.204.84.17];Helo=[SATLEXMB04.amd.com] X-MS-Exchange-CrossTenant-AuthSource: CO1NAM11FT018.eop-nam11.prod.protection.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Anonymous X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: SN7PR12MB7810 X-Rspamd-Server: rspam05 X-Rspamd-Queue-Id: 5B4C8A0026 X-Stat-Signature: c5tm67p9sk89tye9p9adiunk3t8yp1we X-Rspam-User: X-HE-Tag: 1676919665-831232 X-HE-Meta: U2FsdGVkX1+Jf0vFlHTH1H02/U+mcx/w+UdALph0T22xc38404Vp9OjkiWJ9XxCNnSs6FPATrsE+QruLKOYnLwOajMrnB0tpORy9CCs6q8V29PJCXJFpwza7IQCM8d6zXYZz140FWOg7DY5RB/ADzLJWMdjYau7kbDopC+D+AVDswAHp0YesPTE3Us4svV0/rQatQg9iZtI8tVLZEU+uWBG/WMnKMfyr+BLduSCyyweh8YRJdwprXAcLP/j7+7vU6x6qPTP30JfRLiCARfUQiZJ5RiljSkM8QHjF27YOkD673UFiAMJ3pp6xPzYDcJkPvlHHHpF9QdJXJmfutvVIDkD5TZsFGUlwGJHLYwpSq9/Ac04U79RoDtO8RkG3j8bEgs6h20hSljZaPluNhG2O/R2IFOaz0pdYJtF9pCor3bcD8nYObcmSA4itGXwhK8i4YIX7tjL01TxRLZMgI2985trtRjznAWqw5Wc8uP+uP4dO6BQZTncobKXCpkZA7d7A7bBPzqujsz0Ao/Whr/3QwGPGQu5mz0nZ+yg3TqsXIQVjE5Ebatl6fDDUe2qpN4yVtgfXqwB18MXDxvN+4qKwGrkc/6pF2ev9hxV7UM74ETNYthES+oCLKaOgRdosH5TLNUpeAe4gaq/ulqROdWVAm8gNiGV3HFj/YtWIQNMsxK3DFYGsh9+qb1AtVJOthCUyc6Pey8+I8ritdkmsDX+ek/acwR+S+Ndtw8AkIknQuyQd1BKIH/1s/pqXBCEdTEcX11tFfc+92S+K6fcCFH55TxLuzvoBDhrUuTXg30rL3NWHfEmf9g6jnUFNE1OdZfAe6iaiSmkX2QocATXGKUj4aSF8liNTQxXvRVMoISVRZzHuqjKzwNXAKf1PZqPX4WhO5XFqgGhT+WtdboxqRzJW6U8raK2kRJG/F/R410HFT1gxDj40nNtZtwNHKT2tQOGeRZzZB0Qxw+zrEPtSYBd 2gidzLuS hQd5n2r9lsWIWRz8eruJaEUMVF3T9TFuufs73sDvXbw+dG7BX3+MNO6FZ1128iyeRc1WERXZYnUmzIt7km/qz7KguyIXhMMxaxNKFkTdoVXu+2eq71kaxGeSTjU56eBpifNv4R+KhVTEA/+RRkJsCDOAaYgnO2HRfRV5F2aWOQqS74YHSYwqUjq3A5RzSDv0mFlXMAaV7nVVmHSTQiC3yPFKyC0wPw8s9XHDFB6pj4BzbtZTCaK1zbUthb/zwlXSP/Sa9zPxji7rhLqT9/qb+Zfxd2a688WupmYwSxdOEstm2AyNFhZKQRR1sJiHzPiGqAxCuQRitMJNpmKquBWKojgsYQZK7+95ZUcVnnfLji6VadNLUZ3BRMgSKOfVpVU/D8ZOLRZ9PpeC4OXioZ/sbj+3D/fMYZQDTM7P1 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: <linux-mm.kvack.org> |
Series |
Add AMD Secure Nested Paging (SEV-SNP) Hypervisor Support
|
expand
|
diff --git a/Documentation/virt/kvm/x86/amd-memory-encryption.rst b/Documentation/virt/kvm/x86/amd-memory-encryption.rst index dafb0c9984f1..153003ff2c51 100644 --- a/Documentation/virt/kvm/x86/amd-memory-encryption.rst +++ b/Documentation/virt/kvm/x86/amd-memory-encryption.rst @@ -537,6 +537,50 @@ Returns: 0 on success, -negative on error See SEV-SNP specification for further details on launch finish input parameters. +22. KVM_SEV_SNP_GET_CERTS +------------------------- + +After the SNP guest launch flow has started, the KVM_SEV_SNP_GET_CERTS command +can be issued to request the data that has been installed with the +KVM_SEV_SNP_SET_CERTS command. + +Parameters (in/out): struct kvm_sev_snp_get_certs + +Returns: 0 on success, -negative on error + +:: + + struct kvm_sev_snp_get_certs { + __u64 certs_uaddr; + __u64 certs_len + }; + +If no certs have been installed, then the return value is -ENOENT. +If the buffer specified in the struct is too small, the certs_len field will be +overwritten with the required bytes to receive all the certificate bytes and the +return value will be -EINVAL. + +23. KVM_SEV_SNP_SET_CERTS +------------------------- + +After the SNP guest launch flow has started, the KVM_SEV_SNP_SET_CERTS command +can be issued to override the /dev/sev certs data that is returned when a +guest issues an extended guest request. This is useful for instance-specific +extensions to the host certificates. + +Parameters (in/out): struct kvm_sev_snp_set_certs + +Returns: 0 on success, -negative on error + +:: + + struct kvm_sev_snp_set_certs { + __u64 certs_uaddr; + __u64 certs_len + }; + +The certs_len field may not exceed SEV_FW_BLOB_MAX_SIZE. + References ==========