From 9a51354bba35c1b1f8888e4e1954db8f6a91131b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marvin=20Ha=CC=88user?= <8659494+mhaeuser@users.noreply.github.com> Date: Fri, 17 Mar 2023 22:45:33 +0100 Subject: [PATCH] BaseTools/GenFvInternalLib: Remove unused BaseOfCode parameter --- BaseTools/Source/C/GenFv/GenFvInternalLib.c | 11 ----------- BaseTools/Source/C/GenFv/GenFvInternalLib.h | 1 - 2 files changed, 12 deletions(-) diff --git a/BaseTools/Source/C/GenFv/GenFvInternalLib.c b/BaseTools/Source/C/GenFv/GenFvInternalLib.c index f90b36469c..53c601082b 100644 --- a/BaseTools/Source/C/GenFv/GenFvInternalLib.c +++ b/BaseTools/Source/C/GenFv/GenFvInternalLib.c @@ -1526,7 +1526,6 @@ Returns: EFI_STATUS Status; EFI_FILE_SECTION_POINTER Pe32Section; UINT32 EntryPoint; - UINT32 BaseOfCode; UINT16 MachineType; EFI_PHYSICAL_ADDRESS PeiCorePhysicalAddress; EFI_PHYSICAL_ADDRESS SecCorePhysicalAddress; @@ -1602,7 +1601,6 @@ Returns: Status = GetPe32Info ( (VOID *) ((UINTN) Pe32Section.Pe32Section + SecHeaderSize), &EntryPoint, - &BaseOfCode, &MachineType ); @@ -1655,7 +1653,6 @@ Returns: Status = GetPe32Info ( (VOID *) ((UINTN) Pe32Section.Pe32Section + SecHeaderSize), &EntryPoint, - &BaseOfCode, &MachineType ); @@ -1897,7 +1894,6 @@ Returns: { EFI_STATUS Status; UINT32 EntryPoint; - UINT32 BaseOfCode; if (CoreMachineType == NULL) { return EFI_INVALID_PARAMETER; @@ -1906,7 +1902,6 @@ Returns: Status = GetPe32Info( (VOID *)((UINTN)Pe32Section.Pe32Section + GetSectionHeaderLength(Pe32Section.CommonHeader)), &EntryPoint, - &BaseOfCode, CoreMachineType ); if (EFI_ERROR(Status)) { @@ -1947,7 +1942,6 @@ Returns: { EFI_STATUS Status; UINT32 EntryPoint; - UINT32 BaseOfCode; UINT16 MachineType; EFI_PHYSICAL_ADDRESS EntryPhysicalAddress; @@ -1958,7 +1952,6 @@ Returns: Status = GetPe32Info( (VOID *)((UINTN)Pe32Section.Pe32Section + GetSectionHeaderLength(Pe32Section.CommonHeader)), &EntryPoint, - &BaseOfCode, &MachineType ); if (EFI_ERROR(Status)) { @@ -2407,7 +2400,6 @@ EFI_STATUS GetPe32Info ( IN UINT8 *Pe32, OUT UINT32 *EntryPoint, - OUT UINT32 *BaseOfCode, OUT UINT16 *MachineType ) /*++ @@ -2422,7 +2414,6 @@ Arguments: Pe32 Beginning of the PE32. EntryPoint Offset from the beginning of the PE32 to the image entry point. - BaseOfCode Base address of code. MachineType Magic number for the machine type. Returns: @@ -2454,7 +2445,6 @@ Returns: // By TeImage Header to get output // *EntryPoint = TeHeader->AddressOfEntryPoint + sizeof (EFI_TE_IMAGE_HEADER) - TeHeader->StrippedSize; - *BaseOfCode = TeHeader->BaseOfCode + sizeof (EFI_TE_IMAGE_HEADER) - TeHeader->StrippedSize; *MachineType = TeHeader->Machine; } else { @@ -2487,7 +2477,6 @@ Returns: // Get output // *EntryPoint = ImgHdr->Pe32.OptionalHeader.AddressOfEntryPoint; - *BaseOfCode = ImgHdr->Pe32.OptionalHeader.BaseOfCode; *MachineType = ImgHdr->Pe32.FileHeader.Machine; } diff --git a/BaseTools/Source/C/GenFv/GenFvInternalLib.h b/BaseTools/Source/C/GenFv/GenFvInternalLib.h index 7bace6ad36..dc6b2aca91 100644 --- a/BaseTools/Source/C/GenFv/GenFvInternalLib.h +++ b/BaseTools/Source/C/GenFv/GenFvInternalLib.h @@ -307,7 +307,6 @@ EFI_STATUS GetPe32Info ( IN UINT8 *Pe32, OUT UINT32 *EntryPoint, - OUT UINT32 *BaseOfCode, OUT UINT16 *MachineType );