From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by mx.groups.io with SMTP id smtpd.web08.9048.1642752304224016379 for ; Fri, 21 Jan 2022 00:05:05 -0800 Authentication-Results: mx.groups.io; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=H0yZoscq; spf=pass (domain: redhat.com, ip: 170.10.129.124, mailfrom: kraxel@redhat.com) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1642752303; 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: in-reply-to:in-reply-to:references:references; bh=Jmk5IRysf0AquSLZkXt2M97PD3d0AXiB7JXRpYhR36M=; b=H0yZoscqPbjjj5dIQAneFbKmLOKDcCc8I9wG3IjduJUjfarDvDB9SkzlNWmSunelkxjc9B Sdc2Cm02+MRqrkTGG6b/kmdtHN/7zguK1KNbaYvFjCQQlzIjlooG7oW//klsc5FbjcN2PP +Bs4WXx+hnWNWZHWOf/Kcr/iFnVCzFk= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-197-HA2D5XfYP4Gi9LuWZdBUVg-1; Fri, 21 Jan 2022 03:04:57 -0500 X-MC-Unique: HA2D5XfYP4Gi9LuWZdBUVg-1 Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id C2122814243; Fri, 21 Jan 2022 08:04:55 +0000 (UTC) Received: from sirius.home.kraxel.org (unknown [10.39.193.47]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 87A4D79452; Fri, 21 Jan 2022 08:04:55 +0000 (UTC) Received: by sirius.home.kraxel.org (Postfix, from userid 1000) id 09170180009C; Fri, 21 Jan 2022 09:04:54 +0100 (CET) Date: Fri, 21 Jan 2022 09:04:54 +0100 From: "Gerd Hoffmann" To: Brijesh Singh Cc: devel@edk2.groups.io, James Bottomley , Min Xu , Jiewen Yao , Tom Lendacky , Jordan Justen , Ard Biesheuvel , Erdem Aktas , Michael Roth Subject: Re: [PATCH 0/2] SEV BaseMemEncryptLib cleanup Message-ID: <20220121080454.zjzezdtqqgfqmg2c@sirius.home.kraxel.org> References: <20220119230332.44888-1-brijesh.singh@amd.com> MIME-Version: 1.0 In-Reply-To: <20220119230332.44888-1-brijesh.singh@amd.com> X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=kraxel@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=us-ascii Content-Disposition: inline On Wed, Jan 19, 2022 at 05:03:30PM -0600, Brijesh Singh wrote: > This is the first of cleanup for SEV MemEncryptLib. The library uses > the CPUID followed by the MSR read to determine whether SEV is enabled. > > Now that we have a workarea concept, the logic can be simplified to > store the msr status in workarea and use that to build PCDs and then > later simply use the PCDs instead of going through the CPUID and RDMSR. > > The complete branch is available at > https://github.com/codomania/edk2/tree/sev-workarea-cleanup > > Brijesh Singh (2): > OvmfPkg/ResetVector: cache the SEV status MSR value in workarea > OvmfPkg/BaseMemEncryptLib: use the SEV_STATUS MSR value from workarea Looks good to me. Acked-by: Gerd Hoffmann take care, Gerd