public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
From: "Yao, Jiewen" <jiewen.yao@intel.com>
To: "jejb@linux.ibm.com" <jejb@linux.ibm.com>,
	"devel@edk2.groups.io" <devel@edk2.groups.io>,
	"dovmurik@linux.ibm.com" <dovmurik@linux.ibm.com>
Cc: Tobin Feldman-Fitzthum <tobin@linux.ibm.com>,
	Tobin Feldman-Fitzthum <tobin@ibm.com>,
	Jim Cadden <jcadden@ibm.com>,
	Hubertus Franke <frankeh@us.ibm.com>,
	Ard Biesheuvel <ardb+tianocore@kernel.org>,
	"Justen, Jordan L" <jordan.l.justen@intel.com>,
	Ashish Kalra <ashish.kalra@amd.com>,
	Brijesh Singh <brijesh.singh@amd.com>,
	Erdem Aktas <erdemaktas@google.com>,
	"Xu, Min M" <min.m.xu@intel.com>,
	Tom Lendacky <thomas.lendacky@amd.com>,
	Leif Lindholm <leif@nuviainc.com>,
	Sami Mujawar <sami.mujawar@arm.com>,
	"Yao, Jiewen" <jiewen.yao@intel.com>
Subject: Re: [edk2-devel] [PATCH v4 00/11] Measured SEV boot with kernel/initrd/cmdline
Date: Mon, 26 Jul 2021 00:55:31 +0000	[thread overview]
Message-ID: <PH0PR11MB48856078DF64BB9DC37132DD8CE89@PH0PR11MB4885.namprd11.prod.outlook.com> (raw)
In-Reply-To: <ae91d47ca6f9d4dc6d307582ab99f9c5978f3c45.camel@linux.ibm.com>

Hi James
"However, this ran into problems when it was decided AmdSev shouldn't have it's own Library."

I am not clear on the history. Would you please clarify why AmdSev should not have its own library?

It looks not reasonable to me. AmdSev is just a feature. A feature may have its own library. We have enough examples.

Also, the instance name "Grub" is very confusing. I compared PlatformBootManagerLib and PlatformBootManagerLibGrub. This is just a customized PlatformBootManagerLib. 

For example, XEN feature removing and PIIX4 difference has nothing to do with Grub...
=================
      PciWrite8 (PCI_LIB_ADDRESS (0, 1, 0, 0x60), 0x0b); // A
      PciWrite8 (PCI_LIB_ADDRESS (0, 1, 0, 0x61), 0x0b); // B
      PciWrite8 (PCI_LIB_ADDRESS (0, 1, 0, 0x62), 0x0a); // C
      PciWrite8 (PCI_LIB_ADDRESS (0, 1, 0, 0x63), 0x0a); // D
=================

It is a big misleading. Can we move the PlatformBootManagerLibGrub To AmdSev now?



> -----Original Message-----
> From: James Bottomley <jejb@linux.ibm.com>
> Sent: Monday, July 26, 2021 5:10 AM
> To: devel@edk2.groups.io; dovmurik@linux.ibm.com; Yao, Jiewen
> <jiewen.yao@intel.com>
> Cc: Tobin Feldman-Fitzthum <tobin@linux.ibm.com>; Tobin Feldman-Fitzthum
> <tobin@ibm.com>; Jim Cadden <jcadden@ibm.com>; Hubertus Franke
> <frankeh@us.ibm.com>; Ard Biesheuvel <ardb+tianocore@kernel.org>; Justen,
> Jordan L <jordan.l.justen@intel.com>; Ashish Kalra <ashish.kalra@amd.com>;
> Brijesh Singh <brijesh.singh@amd.com>; Erdem Aktas
> <erdemaktas@google.com>; Xu, Min M <min.m.xu@intel.com>; Tom Lendacky
> <thomas.lendacky@amd.com>; Leif Lindholm <leif@nuviainc.com>; Sami
> Mujawar <sami.mujawar@arm.com>
> Subject: Re: [edk2-devel] [PATCH v4 00/11] Measured SEV boot with
> kernel/initrd/cmdline
> 
> On Sun, 2021-07-25 at 10:52 +0300, Dov Murik wrote:
> > And I do have one question:
> > > May I know what is criteria to put a SEV module to OvmfPkg\AmdSev
> > > or OvmfPkg directly?
> > >
> > > My original understanding is:
> > > If a module is required by OvmfPkg{Ia32,Ia32X64,X64}.{dsc,fdf},
> > > then it should be OvmfPkg.
> > > If a module is only required by OvmfPkg\AmdSev\AmdSevX64.{dsc,fdf},
> > > Then it should be in OvmfPkg\AmdSev.
> > >
> > > Am I right?
> > >
> >
> > I actually don't know the criteria.  What you say sounds reasonable.
> > I'll also let James (who introduced the AmdSevX64 target) say what he
> > thinks.
> 
> The original reason for the AmdSev package was actually for
> attestation:  The only way to get attested boot using a standard VM
> image for SEV and SEV-ES was to pull grub inside the measurement
> envelope and have a stripped down hard failing boot path, so if the key
> didn't decode the encrypted boot volume for some reason, the whole
> thing would fail without revealing the injected secret.  This stripped
> down hard failing boot path is much easier to construct as a separate
> target.
> 
> Essentially that means that lots of SEV exists outside the AmdSev
> directory and things should only be in it if they're either modified to
> support the encrypted volume boot path or are only required by it.
> However, this ran into problems when it was decided AmdSev shouldn't
> have it's own Library, so the modified boot path now lives in
> OvmfPkg/Library/PlatformBootManagerLibGrub, so now it's unclear even to
> me what the criteria are.
> 
> James
> 


  reply	other threads:[~2021-07-26  0:55 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-07-22  8:42 [PATCH v4 00/11] Measured SEV boot with kernel/initrd/cmdline Dov Murik
2021-07-22  8:42 ` [PATCH v4 01/11] OvmfPkg/AmdSev/SecretDxe: fix header comment to generic naming Dov Murik
2021-07-22  8:42 ` [PATCH v4 02/11] OvmfPkg/AmdSev: use GenericQemuLoadImageLib in AmdSev builds Dov Murik
2021-07-22  8:42 ` [PATCH v4 03/11] OvmfPkg: PlatformBootManagerLibGrub: Allow executing kernel via fw_cfg Dov Murik
2021-07-22  8:43 ` [PATCH v4 04/11] OvmfPkg: add library class BlobVerifierLib with null implementation Dov Murik
2021-07-22  8:43 ` [PATCH v4 05/11] OvmfPkg: add BlobVerifierLibNull to DSC Dov Murik
2021-07-22  8:43 ` [PATCH v4 06/11] ArmVirtPkg: " Dov Murik
2021-07-22  8:43 ` [PATCH v4 07/11] OvmfPkg/QemuKernelLoaderFsDxe: call VerifyBlob after fetch from fw_cfg Dov Murik
2021-07-22  8:43 ` [PATCH v4 08/11] OvmfPkg/AmdSev/SecretPei: build hob for full page Dov Murik
2021-07-22  8:43 ` [PATCH v4 09/11] OvmfPkg/AmdSev: reserve MEMFD space for for firmware config hashes Dov Murik
2021-07-22  8:43 ` [PATCH v4 10/11] OvmfPkg: add BlobVerifierLibSevHashes Dov Murik
2021-07-22  8:45   ` Dov Murik
2021-07-25  2:47     ` [edk2-devel] " Yao, Jiewen
2021-07-22  8:43 ` [PATCH v4 11/11] OvmfPkg/AmdSev: Enforce hash verification of kernel blobs Dov Murik
2021-07-25  2:43 ` [edk2-devel] [PATCH v4 00/11] Measured SEV boot with kernel/initrd/cmdline Yao, Jiewen
2021-07-25  7:52   ` Dov Murik
2021-07-25  8:17     ` Yao, Jiewen
2021-07-25 10:06       ` Dov Murik
2021-07-25 21:10     ` James Bottomley
2021-07-26  0:55       ` Yao, Jiewen [this message]
2021-07-26 14:50         ` James Bottomley
2021-07-26 15:31           ` Yao, Jiewen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-list from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=PH0PR11MB48856078DF64BB9DC37132DD8CE89@PH0PR11MB4885.namprd11.prod.outlook.com \
    --to=devel@edk2.groups.io \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox