Received: by 2002:a05:7412:8d11:b0:fa:4934:9f with SMTP id bj17csp468086rdb; Mon, 15 Jan 2024 03:20:36 -0800 (PST) X-Google-Smtp-Source: AGHT+IGzomdl4O8u8YCLBxOhMyOo1O8cVo0Z8MQDfLLXsg4oZ48pkVt9U/ag02D/Ou3/fhTycB/6 X-Received: by 2002:a05:6402:1ca9:b0:559:2d2b:a9e7 with SMTP id cz9-20020a0564021ca900b005592d2ba9e7mr920387edb.1.1705317636336; Mon, 15 Jan 2024 03:20:36 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1705317636; cv=none; d=google.com; s=arc-20160816; b=mG3pTT0OAlmWbt6VXNHsYaQa3ufNiORh/1UOogsdi+ERg/oNv0q2f/sJDyEAjikcMD conAAljFh/58LCbLolSCHKkDioGEe9HLG6uDy0wNJdQTI9knQT3cjvzH+COy9up//dFA OhlaSt3P6B0q9TeiEYsJKMI15bhoHuoEgNcDX/D+zgqhwCpaML2hjGxjmuN5t2AmQUJQ K2i2iaGvo367s4nQyTvuHF+XBge0Q0rzi3ctPWtnkNuf14ML/llTLXX1BkAeoxauHd73 wPhtrrqmO5495azGrTXLAK56Ul1qywuP4nNZIhpSvOW29fySbmHOhGkLqXU9RAI2/Igf DWdA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:message-id:subject:cc :to:from:date:dkim-signature; bh=nCwtoIhn1fv1DIHX6b7LJt+v8CCENhFJbxBqG4Uf3iw=; fh=KTcNV0Yr6C7fvqj8A6SttyxkmtEdhf6GUDxxozosWx4=; b=d2eqhl4WL2Pyy47HRnGqFeNR5zbOzOICSqzeSWTM93+2iqoEWaPYrHquoneE3Pm3qj 5DUP/Z1Wt4Tl+DtTF7PPiapXmNr/wz1KBqwKZYO+tdr+aAUyz63bfOOyOG+EDRFV8aOq OWSpEFKyDSeHRWDq9+i1ES+ckeabqHxXVLaD8j2qgeL7wCzCd0sDED+D7+lui0Tivp4g +CpTUBiYaeWsTQXTANMZiGc5MW66yhUZjqqRkVcCPxJqHSsixQwK3nWM5dSmBRis+/9M kI1ZTKFED/1b29EeclTdpwxlk9jzcT/+2sxpHdU0juwGLpMEeNEAVv83dpA3YYO9ROPX dHlA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@alien8.de header.s=alien8 header.b=c9ibmYOW; spf=pass (google.com: domain of linux-crypto+bounces-1430-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-crypto+bounces-1430-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=alien8.de Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [2604:1380:4601:e00::3]) by mx.google.com with ESMTPS id t11-20020a50d70b000000b00558e8d1a7d1si2369361edi.534.2024.01.15.03.20.36 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 15 Jan 2024 03:20:36 -0800 (PST) Received-SPF: pass (google.com: domain of linux-crypto+bounces-1430-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) client-ip=2604:1380:4601:e00::3; Authentication-Results: mx.google.com; dkim=pass header.i=@alien8.de header.s=alien8 header.b=c9ibmYOW; spf=pass (google.com: domain of linux-crypto+bounces-1430-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-crypto+bounces-1430-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=alien8.de Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id 1B5881F222AF for ; Mon, 15 Jan 2024 11:20:36 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 1FFFF2C689; Mon, 15 Jan 2024 11:20:29 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (4096-bit key) header.d=alien8.de header.i=@alien8.de header.b="c9ibmYOW" X-Original-To: linux-crypto@vger.kernel.org Received: from mail.alien8.de (mail.alien8.de [65.109.113.108]) (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 AAB8D2208A; Mon, 15 Jan 2024 11:20:26 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=alien8.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=alien8.de Received: from localhost (localhost.localdomain [127.0.0.1]) by mail.alien8.de (SuperMail on ZX Spectrum 128k) with ESMTP id C7BEE40E016C; Mon, 15 Jan 2024 11:20:23 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at mail.alien8.de Authentication-Results: mail.alien8.de (amavisd-new); dkim=pass (4096-bit key) header.d=alien8.de Received: from mail.alien8.de ([127.0.0.1]) by localhost (mail.alien8.de [127.0.0.1]) (amavisd-new, port 10026) with ESMTP id 1FAqnwMpb_Zd; Mon, 15 Jan 2024 11:20:21 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=alien8.de; s=alien8; t=1705317621; bh=nCwtoIhn1fv1DIHX6b7LJt+v8CCENhFJbxBqG4Uf3iw=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=c9ibmYOWC60KK4KJuKNxRjp9cTDl/t4NGMCh/hIKwI8C8n85ZPub0L2koL6V6bEcL DnLO99QtKwXchL36UkyaqZXBS5DH7fP3jHL9Q/Ctm4+fh8YQ/Zi44hPI/hQd/pdAI4 hF/dZoekSuQo4hLubKrITPpOBld2No3hKm8/53/0LY+40mMrigZM8I3pfNjZm2DoIk UROnl9HdofZnPLJ6LMgGqBqaDafsnEMfGqPyc1AfVYJRxj4jSf2YNhaeWiCk9E/3A2 a3kH6iByD969PW9vbwfK+YiMd0D9SY1TtpWky0g3RTJAF0hq+BELR+pCArKET/9zsi qWGNTjOJNmElWJ+LYDgjQXdiTHPiLtkxN0MZLSX8sXLtARN3Gs1imoyDUCgjd7VCZC J9vT3kwHNvW4Kf8TVcvfdGoJS6jNtP7zMsdEveUfXAGsMoXMdd0HGdiWKiEuoKaYNA EPtLG2zJlKmm50rZEOmCQzZpToDW7Nw49E+B7wCUUoN+R/Zp/A/UYJ71G3L+X51uGD 46T9n5gOcZdmqK0u48Y8hXTy3YOBjU897Pw0gioBU1PMLttNUhCbrT7GUSTA/Bnr02 Mj7zI4H0tzj0gA4NTS5FNbwPFc3ylTElAZVRO6fzZXitlK8u8u1qXnQK/5HSONYAJJ l7i/ggtKLhd5cb4XvcaoXjgQ= Received: from zn.tnic (pd9530f8c.dip0.t-ipconnect.de [217.83.15.140]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature ECDSA (P-256) server-digest SHA256) (No client certificate requested) by mail.alien8.de (SuperMail on ZX Spectrum 128k) with ESMTPSA id 1B87140E00C5; Mon, 15 Jan 2024 11:19:44 +0000 (UTC) Date: Mon, 15 Jan 2024 12:19:37 +0100 From: Borislav Petkov To: Michael Roth Cc: x86@kernel.org, kvm@vger.kernel.org, linux-coco@lists.linux.dev, linux-mm@kvack.org, linux-crypto@vger.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, tobin@ibm.com, vbabka@suse.cz, kirill@shutemov.name, ak@linux.intel.com, tony.luck@intel.com, sathyanarayanan.kuppuswamy@linux.intel.com, alpergun@google.com, jarkko@kernel.org, ashish.kalra@amd.com, nikunj.dadhania@amd.com, pankaj.gupta@amd.com, "liam.merwick@oracle.com Brijesh Singh" , Jarkko Sakkinen Subject: Re: [PATCH v1 13/26] crypto: ccp: Add support to initialize the AMD-SP for SEV-SNP Message-ID: <20240115111930.GGZaUUwpmmZqxVcBEu@fat_crate.local> References: <20231230161954.569267-1-michael.roth@amd.com> <20231230161954.569267-14-michael.roth@amd.com> Precedence: bulk X-Mailing-List: linux-crypto@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20231230161954.569267-14-michael.roth@amd.com> On Sat, Dec 30, 2023 at 10:19:41AM -0600, Michael Roth wrote: > + /* > + * The following sequence must be issued before launching the > + * first SNP guest to ensure all dirty cache lines are flushed, > + * including from updates to the RMP table itself via RMPUPDATE > + * instructions: > + * > + * - WBINDV on all running CPUs > + * - SEV_CMD_SNP_INIT[_EX] firmware command > + * - WBINDV on all running CPUs > + * - SEV_CMD_SNP_DF_FLUSH firmware command > + */ Typos: --- diff --git a/drivers/crypto/ccp/sev-dev.c b/drivers/crypto/ccp/sev-dev.c index 85634d4f8cfe..ce0c56006900 100644 --- a/drivers/crypto/ccp/sev-dev.c +++ b/drivers/crypto/ccp/sev-dev.c @@ -604,9 +604,9 @@ static int __sev_snp_init_locked(int *error) * including from updates to the RMP table itself via RMPUPDATE * instructions: * - * - WBINDV on all running CPUs + * - WBINVD on all running CPUs * - SEV_CMD_SNP_INIT[_EX] firmware command - * - WBINDV on all running CPUs + * - WBINVD on all running CPUs * - SEV_CMD_SNP_DF_FLUSH firmware command */ wbinvd_on_all_cpus(); -- Regards/Gruss, Boris. https://people.kernel.org/tglx/notes-about-netiquette