render / rpms / edk2

Forked from rpms/edk2 2 months ago
Clone

Blame SOURCES/edk2-OvmfPkg-drop-TPM_CONFIG_ENABLE.patch

7439a5
From 505473655db4b91e4a0ac732069968f9eddabc51 Mon Sep 17 00:00:00 2001
7439a5
From: Gerd Hoffmann <kraxel@redhat.com>
7439a5
Date: Wed, 15 Dec 2021 12:39:18 +0100
7439a5
Subject: [PATCH 3/6] OvmfPkg: drop TPM_CONFIG_ENABLE
7439a5
7439a5
RH-Author: Gerd Hoffmann <kraxel@redhat.com>
7439a5
RH-MergeRequest: 9: backport tpm build updates, disable tpm 1.2 support
7439a5
RH-Commit: [3/6] be335526f74358d4af21fbd35cc7008b227ebb23 (kraxel/centos-edk2)
7439a5
RH-Bugzilla: 1935497
7439a5
RH-Acked-by: Oliver Steffen <None>
7439a5
7439a5
Drop TPM_CONFIG_ENABLE config option.  Including TPM support in the
7439a5
build without also including the TPM configuration menu is not useful.
7439a5
7439a5
Suggested-by: Stefan Berger <stefanb@linux.ibm.com>
7439a5
Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
7439a5
Tested-by: Stefan Berger <stefanb@linux.ibm.com>
7439a5
(cherry picked from commit 5711ff4d0b56ff4c58dc7a780e706bc58aed2253)
7439a5
---
7439a5
 OvmfPkg/OvmfTpmComponentsDxe.dsc.inc                  | 2 --
7439a5
 OvmfPkg/OvmfTpmDefines.dsc.inc                        | 1 -
7439a5
 OvmfPkg/OvmfTpmDxe.fdf.inc                            | 2 --
7439a5
 OvmfPkg/OvmfTpmPcdsHii.dsc.inc                        | 2 +-
7439a5
 OvmfPkg/PlatformCI/.azurepipelines/Ubuntu-GCC5.yml    | 6 +++---
7439a5
 OvmfPkg/PlatformCI/.azurepipelines/Windows-VS2019.yml | 6 +++---
7439a5
 OvmfPkg/PlatformCI/ReadMe.md                          | 2 +-
7439a5
 7 files changed, 8 insertions(+), 13 deletions(-)
7439a5
7439a5
diff --git a/OvmfPkg/OvmfTpmComponentsDxe.dsc.inc b/OvmfPkg/OvmfTpmComponentsDxe.dsc.inc
7439a5
index d5c2586118..e025d85a58 100644
7439a5
--- a/OvmfPkg/OvmfTpmComponentsDxe.dsc.inc
7439a5
+++ b/OvmfPkg/OvmfTpmComponentsDxe.dsc.inc
7439a5
@@ -14,9 +14,7 @@
7439a5
       NULL|SecurityPkg/Library/HashInstanceLibSha512/HashInstanceLibSha512.inf
7439a5
       NULL|SecurityPkg/Library/HashInstanceLibSm3/HashInstanceLibSm3.inf
7439a5
   }
7439a5
-!if $(TPM_CONFIG_ENABLE) == TRUE
7439a5
   SecurityPkg/Tcg/Tcg2Config/Tcg2ConfigDxe.inf
7439a5
-!endif
7439a5
   SecurityPkg/Tcg/TcgDxe/TcgDxe.inf {
7439a5
     <LibraryClasses>
7439a5
       Tpm12DeviceLib|SecurityPkg/Library/Tpm12DeviceLibDTpm/Tpm12DeviceLibDTpm.inf
7439a5
diff --git a/OvmfPkg/OvmfTpmDefines.dsc.inc b/OvmfPkg/OvmfTpmDefines.dsc.inc
7439a5
index 51da7508b3..5df4a331fb 100644
7439a5
--- a/OvmfPkg/OvmfTpmDefines.dsc.inc
7439a5
+++ b/OvmfPkg/OvmfTpmDefines.dsc.inc
7439a5
@@ -3,4 +3,3 @@
7439a5
 ##
7439a5
 
7439a5
   DEFINE TPM_ENABLE              = FALSE
7439a5
-  DEFINE TPM_CONFIG_ENABLE       = FALSE
7439a5
diff --git a/OvmfPkg/OvmfTpmDxe.fdf.inc b/OvmfPkg/OvmfTpmDxe.fdf.inc
7439a5
index 9dcdaaf01c..32eef24638 100644
7439a5
--- a/OvmfPkg/OvmfTpmDxe.fdf.inc
7439a5
+++ b/OvmfPkg/OvmfTpmDxe.fdf.inc
7439a5
@@ -6,7 +6,5 @@
7439a5
 INF  SecurityPkg/Tcg/TcgDxe/TcgDxe.inf
7439a5
 INF  SecurityPkg/Tcg/Tcg2Dxe/Tcg2Dxe.inf
7439a5
 INF  SecurityPkg/Tcg/Tcg2PlatformDxe/Tcg2PlatformDxe.inf
7439a5
-!if $(TPM_CONFIG_ENABLE) == TRUE
7439a5
 INF  SecurityPkg/Tcg/Tcg2Config/Tcg2ConfigDxe.inf
7439a5
 !endif
7439a5
-!endif
7439a5
diff --git a/OvmfPkg/OvmfTpmPcdsHii.dsc.inc b/OvmfPkg/OvmfTpmPcdsHii.dsc.inc
7439a5
index 164bc9c7fc..2e02a5b4cb 100644
7439a5
--- a/OvmfPkg/OvmfTpmPcdsHii.dsc.inc
7439a5
+++ b/OvmfPkg/OvmfTpmPcdsHii.dsc.inc
7439a5
@@ -2,7 +2,7 @@
7439a5
 #    SPDX-License-Identifier: BSD-2-Clause-Patent
7439a5
 ##
7439a5
 
7439a5
-!if $(TPM_ENABLE) == TRUE && $(TPM_CONFIG_ENABLE) == TRUE
7439a5
+!if $(TPM_ENABLE) == TRUE
7439a5
   gEfiSecurityPkgTokenSpaceGuid.PcdTcgPhysicalPresenceInterfaceVer|L"TCG2_VERSION"|gTcg2ConfigFormSetGuid|0x0|"1.3"|NV,BS
7439a5
   gEfiSecurityPkgTokenSpaceGuid.PcdTpm2AcpiTableRev|L"TCG2_VERSION"|gTcg2ConfigFormSetGuid|0x8|3|NV,BS
7439a5
 !endif
7439a5
diff --git a/OvmfPkg/PlatformCI/.azurepipelines/Ubuntu-GCC5.yml b/OvmfPkg/PlatformCI/.azurepipelines/Ubuntu-GCC5.yml
7439a5
index 7117b86b81..1774423580 100644
7439a5
--- a/OvmfPkg/PlatformCI/.azurepipelines/Ubuntu-GCC5.yml
7439a5
+++ b/OvmfPkg/PlatformCI/.azurepipelines/Ubuntu-GCC5.yml
7439a5
@@ -95,21 +95,21 @@ jobs:
7439a5
           OVMF_IA32X64_FULL_DEBUG:
7439a5
             Build.File: "$(package)/PlatformCI/PlatformBuild.py"
7439a5
             Build.Arch: "IA32,X64"
7439a5
-            Build.Flags: "BLD_*_SECURE_BOOT_ENABLE=1 BLD_*_SMM_REQUIRE=1 BLD_*_TPM_ENABLE=1 BLD_*_TPM_CONFIG_ENABLE=1 BLD_*_NETWORK_TLS_ENABLE=1 BLD_*_NETWORK_IP6_ENABLE=1 BLD_*_NETWORK_HTTP_BOOT_ENABLE=1"
7439a5
+            Build.Flags: "BLD_*_SECURE_BOOT_ENABLE=1 BLD_*_SMM_REQUIRE=1 BLD_*_TPM_ENABLE=1 BLD_*_NETWORK_TLS_ENABLE=1 BLD_*_NETWORK_IP6_ENABLE=1 BLD_*_NETWORK_HTTP_BOOT_ENABLE=1"
7439a5
             Build.Target: "DEBUG"
7439a5
             Run.Flags: $(run_flags)
7439a5
             Run: $(should_run)
7439a5
           OVMF_IA32X64_FULL_RELEASE:
7439a5
             Build.File: "$(package)/PlatformCI/PlatformBuild.py"
7439a5
             Build.Arch: "IA32,X64"
7439a5
-            Build.Flags: "BLD_*_SECURE_BOOT_ENABLE=1 BLD_*_SMM_REQUIRE=1 BLD_*_TPM_ENABLE=1 BLD_*_TPM_CONFIG_ENABLE=1 BLD_*_NETWORK_TLS_ENABLE=1 BLD_*_NETWORK_IP6_ENABLE=1 BLD_*_NETWORK_HTTP_BOOT_ENABLE=1"
7439a5
+            Build.Flags: "BLD_*_SECURE_BOOT_ENABLE=1 BLD_*_SMM_REQUIRE=1 BLD_*_TPM_ENABLE=1 BLD_*_NETWORK_TLS_ENABLE=1 BLD_*_NETWORK_IP6_ENABLE=1 BLD_*_NETWORK_HTTP_BOOT_ENABLE=1"
7439a5
             Build.Target: "RELEASE"
7439a5
             Run.Flags: $(run_flags)
7439a5
             Run: $(should_run)
7439a5
           OVMF_IA32X64_FULL_NOOPT:
7439a5
             Build.File: "$(package)/PlatformCI/PlatformBuild.py"
7439a5
             Build.Arch: "IA32,X64"
7439a5
-            Build.Flags: "BLD_*_SECURE_BOOT_ENABLE=1 BLD_*_SMM_REQUIRE=1 BLD_*_TPM_ENABLE=1 BLD_*_TPM_CONFIG_ENABLE=1 BLD_*_NETWORK_TLS_ENABLE=1 BLD_*_NETWORK_IP6_ENABLE=1 BLD_*_NETWORK_HTTP_BOOT_ENABLE=1"
7439a5
+            Build.Flags: "BLD_*_SECURE_BOOT_ENABLE=1 BLD_*_SMM_REQUIRE=1 BLD_*_TPM_ENABLE=1 BLD_*_NETWORK_TLS_ENABLE=1 BLD_*_NETWORK_IP6_ENABLE=1 BLD_*_NETWORK_HTTP_BOOT_ENABLE=1"
7439a5
             Build.Target: "NOOPT"
7439a5
             Run.Flags: $(run_flags)
7439a5
             Run: $(should_run)
7439a5
diff --git a/OvmfPkg/PlatformCI/.azurepipelines/Windows-VS2019.yml b/OvmfPkg/PlatformCI/.azurepipelines/Windows-VS2019.yml
7439a5
index 2e07a3d889..09f9851312 100644
7439a5
--- a/OvmfPkg/PlatformCI/.azurepipelines/Windows-VS2019.yml
7439a5
+++ b/OvmfPkg/PlatformCI/.azurepipelines/Windows-VS2019.yml
7439a5
@@ -94,14 +94,14 @@ jobs:
7439a5
           OVMF_IA32X64_FULL_DEBUG:
7439a5
             Build.File: "$(package)/PlatformCI/PlatformBuild.py"
7439a5
             Build.Arch: "IA32,X64"
7439a5
-            Build.Flags: "BLD_*_SECURE_BOOT_ENABLE=1 BLD_*_SMM_REQUIRE=1 BLD_*_TPM_ENABLE=1 BLD_*_TPM_CONFIG_ENABLE=1 BLD_*_NETWORK_TLS_ENABLE=1 BLD_*_NETWORK_IP6_ENABLE=1 BLD_*_NETWORK_HTTP_BOOT_ENABLE=1"
7439a5
+            Build.Flags: "BLD_*_SECURE_BOOT_ENABLE=1 BLD_*_SMM_REQUIRE=1 BLD_*_TPM_ENABLE=1 BLD_*_NETWORK_TLS_ENABLE=1 BLD_*_NETWORK_IP6_ENABLE=1 BLD_*_NETWORK_HTTP_BOOT_ENABLE=1"
7439a5
             Build.Target: "DEBUG"
7439a5
             Run.Flags: $(run_flags)
7439a5
             Run: $(should_run)
7439a5
           OVMF_IA32X64_FULL_RELEASE:
7439a5
             Build.File: "$(package)/PlatformCI/PlatformBuild.py"
7439a5
             Build.Arch: "IA32,X64"
7439a5
-            Build.Flags: "BLD_*_SECURE_BOOT_ENABLE=1 BLD_*_SMM_REQUIRE=1 BLD_*_TPM_ENABLE=1 BLD_*_TPM_CONFIG_ENABLE=1 BLD_*_NETWORK_TLS_ENABLE=1 BLD_*_NETWORK_IP6_ENABLE=1 BLD_*_NETWORK_HTTP_BOOT_ENABLE=1"
7439a5
+            Build.Flags: "BLD_*_SECURE_BOOT_ENABLE=1 BLD_*_SMM_REQUIRE=1 BLD_*_TPM_ENABLE=1 BLD_*_NETWORK_TLS_ENABLE=1 BLD_*_NETWORK_IP6_ENABLE=1 BLD_*_NETWORK_HTTP_BOOT_ENABLE=1"
7439a5
             Build.Target: "RELEASE"
7439a5
             Run.Flags: $(run_flags)
7439a5
             Run: $(should_run)
7439a5
@@ -112,7 +112,7 @@ jobs:
7439a5
     #       OVMF_IA32X64_FULL_NOOPT:
7439a5
     #         Build.File: "$(package)/PlatformCI/PlatformBuild.py"
7439a5
     #         Build.Arch: "IA32,X64"
7439a5
-    #         Build.Flags: "BLD_*_SECURE_BOOT_ENABLE=1 BLD_*_SMM_REQUIRE=1 BLD_*_TPM_ENABLE=1 BLD_*_TPM_CONFIG_ENABLE=1 BLD_*_NETWORK_TLS_ENABLE=1 BLD_*_NETWORK_IP6_ENABLE=1 BLD_*_NETWORK_HTTP_BOOT_ENABLE=1"
7439a5
+    #         Build.Flags: "BLD_*_SECURE_BOOT_ENABLE=1 BLD_*_SMM_REQUIRE=1 BLD_*_TPM_ENABLE=1 BLD_*_NETWORK_TLS_ENABLE=1 BLD_*_NETWORK_IP6_ENABLE=1 BLD_*_NETWORK_HTTP_BOOT_ENABLE=1"
7439a5
     #         Build.Target: "NOOPT"
7439a5
     #         Run.Flags: $(run_flags)
7439a5
     #         Run: $(should_run)
7439a5
diff --git a/OvmfPkg/PlatformCI/ReadMe.md b/OvmfPkg/PlatformCI/ReadMe.md
7439a5
index 2ce9007dbe..44aa7c4a9d 100644
7439a5
--- a/OvmfPkg/PlatformCI/ReadMe.md
7439a5
+++ b/OvmfPkg/PlatformCI/ReadMe.md
7439a5
@@ -14,7 +14,7 @@ supported and are described below.
7439a5
 | IA32                    | IA32               | OvmfPkgIa32.dsc     | None            |
7439a5
 | X64                     | X64                | OvmfPkgIa64.dsc     | None            |
7439a5
 | IA32 X64                | PEI-IA32 DXE-X64   | OvmfPkgIa32X64.dsc  | None            |
7439a5
-| IA32 X64 Full           | PEI-IA32 DXE-X64   | OvmfPkgIa32X64.dsc  | SECURE_BOOT_ENABLE=1 SMM_REQUIRE=1 TPM_ENABLE=1 TPM_CONFIG_ENABLE=1 NETWORK_TLS_ENABLE=1 NETWORK_IP6_ENABLE=1 NETWORK_HTTP_BOOT_ENABLE=1 |
7439a5
+| IA32 X64 Full           | PEI-IA32 DXE-X64   | OvmfPkgIa32X64.dsc  | SECURE_BOOT_ENABLE=1 SMM_REQUIRE=1 TPM_ENABLE=1 NETWORK_TLS_ENABLE=1 NETWORK_IP6_ENABLE=1 NETWORK_HTTP_BOOT_ENABLE=1 |
7439a5
 
7439a5
 ## EDK2 Developer environment
7439a5
 
7439a5
-- 
7439a5
2.27.0
7439a5