]> git.proxmox.com Git - mirror_edk2.git/commitdiff
OvmfPkg/AmdSev/SecretDxe: make secret location naming generic
authorJames Bottomley <jejb@linux.ibm.com>
Wed, 16 Dec 2020 01:41:46 +0000 (17:41 -0800)
committermergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
Fri, 18 Dec 2020 10:45:52 +0000 (10:45 +0000)
It is anticipated that this part of the code will work for both Intel
TDX and AMD SEV, so remove the SEV specific naming and change to
ConfidentialComputing as a more architecture neutral prefix. Apart
from the symbol rename, there are no code changes.

Signed-off-by: James Bottomley <James.Bottomley@HansenPartnership.com>
Message-Id: <20201216014146.2229-3-jejb@linux.ibm.com>
Reviewed-by: Jiewen Yao <Jiewen.yao@intel.com>
Reviewed-by: Laszlo Ersek <lersek@redhat.com>
OvmfPkg/AmdSev/SecretDxe/SecretDxe.c
OvmfPkg/AmdSev/SecretDxe/SecretDxe.inf
OvmfPkg/Include/Guid/ConfidentialComputingSecret.h [new file with mode: 0644]
OvmfPkg/Include/Guid/SevLaunchSecret.h [deleted file]
OvmfPkg/OvmfPkg.dec

index 5385a6aea275065998877a8f96b2bfdc56f211bc..308022b5b25ef9018ff76c72bb3cbdca26b94761 100644 (file)
@@ -6,9 +6,9 @@
 **/\r
 #include <PiDxe.h>\r
 #include <Library/UefiBootServicesTableLib.h>\r
-#include <Guid/SevLaunchSecret.h>\r
+#include <Guid/ConfidentialComputingSecret.h>\r
 \r
-STATIC SEV_LAUNCH_SECRET_LOCATION mSecretDxeTable = {\r
+STATIC CONFIDENTIAL_COMPUTING_SECRET_LOCATION mSecretDxeTable = {\r
   FixedPcdGet32 (PcdSevLaunchSecretBase),\r
   FixedPcdGet32 (PcdSevLaunchSecretSize),\r
 };\r
@@ -21,7 +21,7 @@ InitializeSecretDxe(
   )\r
 {\r
   return gBS->InstallConfigurationTable (\r
-                &gSevLaunchSecretGuid,\r
+                &gConfidentialComputingSecretGuid,\r
                 &mSecretDxeTable\r
                 );\r
 }\r
index 62ab00a3d38221cdfdd00afa7870bdfdf3ce5dd5..40bda7ff846c6fa799494a73f8573dd19a2066c7 100644 (file)
@@ -27,7 +27,7 @@
   UefiDriverEntryPoint\r
 \r
 [Guids]\r
-  gSevLaunchSecretGuid\r
+  gConfidentialComputingSecretGuid\r
 \r
 [FixedPcd]\r
   gUefiOvmfPkgTokenSpaceGuid.PcdSevLaunchSecretBase\r
diff --git a/OvmfPkg/Include/Guid/ConfidentialComputingSecret.h b/OvmfPkg/Include/Guid/ConfidentialComputingSecret.h
new file mode 100644 (file)
index 0000000..7026fc5
--- /dev/null
@@ -0,0 +1,28 @@
+ /** @file\r
+   UEFI Configuration Table for exposing the SEV Launch Secret location to UEFI\r
+   applications (boot loaders).\r
+\r
+   Copyright (C) 2020 James Bottomley, IBM Corporation.\r
+   SPDX-License-Identifier: BSD-2-Clause-Patent\r
+ **/\r
+\r
+#ifndef CONFIDENTIAL_COMPUTING_SECRET_H_\r
+#define CONFIDENTIAL_COMPUTING_SECRET_H_\r
+\r
+#include <Uefi/UefiBaseType.h>\r
+\r
+#define CONFIDENTIAL_COMPUTING_SECRET_GUID              \\r
+  { 0xadf956ad,                                         \\r
+    0xe98c,                                             \\r
+    0x484c,                                             \\r
+    { 0xae, 0x11, 0xb5, 0x1c, 0x7d, 0x33, 0x64, 0x47 }, \\r
+  }\r
+\r
+typedef struct {\r
+  UINT64 Base;\r
+  UINT64 Size;\r
+} CONFIDENTIAL_COMPUTING_SECRET_LOCATION;\r
+\r
+extern EFI_GUID gConfidentialComputingSecretGuid;\r
+\r
+#endif // SEV_LAUNCH_SECRET_H_\r
diff --git a/OvmfPkg/Include/Guid/SevLaunchSecret.h b/OvmfPkg/Include/Guid/SevLaunchSecret.h
deleted file mode 100644 (file)
index dfd8964..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
- /** @file\r
-   UEFI Configuration Table for exposing the SEV Launch Secret location to UEFI\r
-   applications (boot loaders).\r
-\r
-   Copyright (C) 2020 James Bottomley, IBM Corporation.\r
-   SPDX-License-Identifier: BSD-2-Clause-Patent\r
- **/\r
-\r
-#ifndef SEV_LAUNCH_SECRET_H_\r
-#define SEV_LAUNCH_SECRET_H_\r
-\r
-#include <Uefi/UefiBaseType.h>\r
-\r
-#define SEV_LAUNCH_SECRET_GUID                          \\r
-  { 0xadf956ad,                                         \\r
-    0xe98c,                                             \\r
-    0x484c,                                             \\r
-    { 0xae, 0x11, 0xb5, 0x1c, 0x7d, 0x33, 0x64, 0x47 }, \\r
-  }\r
-\r
-typedef struct {\r
-  UINT64 Base;\r
-  UINT64 Size;\r
-} SEV_LAUNCH_SECRET_LOCATION;\r
-\r
-extern EFI_GUID gSevLaunchSecretGuid;\r
-\r
-#endif // SEV_LAUNCH_SECRET_H_\r
index 8a294116efaabc58cfc20d32e5dc48624c20e7af..50d7b27d941c1662c5db2f9e285f249cd7ecb2b3 100644 (file)
   gLinuxEfiInitrdMediaGuid              = {0x5568e427, 0x68fc, 0x4f3d, {0xac, 0x74, 0xca, 0x55, 0x52, 0x31, 0xcc, 0x68}}\r
   gQemuKernelLoaderFsMediaGuid          = {0x1428f772, 0xb64a, 0x441e, {0xb8, 0xc3, 0x9e, 0xbd, 0xd7, 0xf8, 0x93, 0xc7}}\r
   gGrubFileGuid                         = {0xb5ae312c, 0xbc8a, 0x43b1, {0x9c, 0x62, 0xeb, 0xb8, 0x26, 0xdd, 0x5d, 0x07}}\r
-  gSevLaunchSecretGuid                  = {0xadf956ad, 0xe98c, 0x484c, {0xae, 0x11, 0xb5, 0x1c, 0x7d, 0x33, 0x64, 0x47}}\r
+  gConfidentialComputingSecretGuid      = {0xadf956ad, 0xe98c, 0x484c, {0xae, 0x11, 0xb5, 0x1c, 0x7d, 0x33, 0x64, 0x47}}\r
 \r
 [Ppis]\r
   # PPI whose presence in the PPI database signals that the TPM base address\r