Browse Source

Platform/BeagleBoard: Drop PeCoff protocol

BeagleBoard is the only user of the so-called 'PE/COFF protocol', which
just exposes the PE/COFF loader library API via a protocol, presumably
to avoid duplicating this code in the PrePi SEC component as well as the
DXE core.

This is a rather questionable practice, and it would be better to drop
this code so we can remove it from the EDK2 main repo as well.

Signed-off-by: Ard Biesheuvel <ardb@kernel.org>
Reviewed-by: Leif Lindholm <quic_llindhol@quicinc.com>
Ard Biesheuvel 1 year ago
parent
commit
b7505f9c27

+ 2 - 4
Platform/BeagleBoard/BeagleBoardPkg/BeagleBoardPkg.dsc

@@ -167,8 +167,7 @@
   DxeCoreEntryPoint|MdePkg/Library/DxeCoreEntryPoint/DxeCoreEntryPoint.inf
   ExtractGuidedSectionLib|MdePkg/Library/DxeExtractGuidedSectionLib/DxeExtractGuidedSectionLib.inf
   DxeServicesLib|MdePkg/Library/DxeServicesLib/DxeServicesLib.inf
-#  PeCoffLib|MdePkg/Library/BasePeCoffLib/BasePeCoffLib.inf
-  PeCoffLib|Platform/BeagleBoard/BeagleBoardPkg/Library/DxeHobPeCoffLib/DxeHobPeCoffLib.inf
+  PeCoffLib|MdePkg/Library/BasePeCoffLib/BasePeCoffLib.inf
 
 [LibraryClasses.common.DXE_DRIVER]
   DxeServicesLib|MdePkg/Library/DxeServicesLib/DxeServicesLib.inf
@@ -190,8 +189,7 @@
   HobLib|MdePkg/Library/DxeHobLib/DxeHobLib.inf
   MemoryAllocationLib|MdePkg/Library/UefiMemoryAllocationLib/UefiMemoryAllocationLib.inf
   CapsuleLib|MdeModulePkg/Library/DxeCapsuleLibNull/DxeCapsuleLibNull.inf
-#  PeCoffLib|MdePkg/Library/BasePeCoffLib/BasePeCoffLib.inf
-  PeCoffLib|Platform/BeagleBoard/BeagleBoardPkg/Library/DxeHobPeCoffLib/DxeHobPeCoffLib.inf
+  PeCoffLib|MdePkg/Library/BasePeCoffLib/BasePeCoffLib.inf
   VariablePolicyLib|MdeModulePkg/Library/VariablePolicyLib/VariablePolicyLibRuntimeDxe.inf
 
 

+ 0 - 39
Platform/BeagleBoard/BeagleBoardPkg/Library/DxeHobPeCoffLib/DxeHobPeCoffLib.inf

@@ -1,39 +0,0 @@
-#/** @file
-#  PE/COFF Loader Library implementation that wraps a protocol passed up from
-#  SEC/PEI via a HOB. This is done to save space.
-#
-#  Copyright (c) 2010 - 2018, Intel Corporation. All rights reserved.<BR>
-#  Portions copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
-#  SPDX-License-Identifier: BSD-2-Clause-Patent
-#
-#
-#**/
-
-[Defines]
-  INF_VERSION                    = 0x00010005
-  BASE_NAME                      = DxeHobPeCoffLib
-  FILE_GUID                      = 671C6FD7-99FB-4EE3-B640-4B1D463BC3B5
-  MODULE_TYPE                    = DXE_DRIVER
-  VERSION_STRING                 = 1.0
-  LIBRARY_CLASS                  = PeCoffLib
-  CONSTRUCTOR                    = DxeHobPeCoffLibConstructor
-
-
-#
-#  VALID_ARCHITECTURES           = IA32 X64 EBC ARM
-#
-
-[Sources.common]
-  DxeHobPeCoff.c
-
-
-[Packages]
-  MdePkg/MdePkg.dec
-  EmbeddedPkg/EmbeddedPkg.dec
-
-[LibraryClasses]
-  DebugLib
-  HobLib
-
-[Protocols]
-  gPeCoffLoaderProtocolGuid