diff options
author | Rebecca Cran <rebecca@bsdio.com> | 2023-04-06 13:52:17 -0600 |
---|---|---|
committer | mergify[bot] <37929162+mergify[bot]@users.noreply.github.com> | 2023-04-10 14:19:57 +0000 |
commit | 9e7b042ecba5f78f9fb72d6bb50f8dbc5a32ecac (patch) | |
tree | 5335f2fe1972c90852d7716ca28cd0e1180ac930 /PrmPkg/PrmLoaderDxe | |
parent | 1295e37d4bb4c07f41cfa6ce298344aaf1563c72 (diff) | |
download | edk2-9e7b042ecba5f78f9fb72d6bb50f8dbc5a32ecac.tar.gz |
PrmPkg: Update code to be more C11 compliant by using __func__
__FUNCTION__ is a pre-standard extension that gcc and Visual C++ among
others support, while __func__ was standardized in C99.
Since it's more standard, replace __FUNCTION__ with __func__ throughout
PrmPkg.
Signed-off-by: Rebecca Cran <rebecca@bsdio.com>
Reviewed-by: Michael D Kinney <michael.d.kinney@intel.com>
Reviewed-by: Ard Biesheuvel <ardb@kernel.org>
Diffstat (limited to 'PrmPkg/PrmLoaderDxe')
-rw-r--r-- | PrmPkg/PrmLoaderDxe/PrmLoaderDxe.c | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/PrmPkg/PrmLoaderDxe/PrmLoaderDxe.c b/PrmPkg/PrmLoaderDxe/PrmLoaderDxe.c index 5a223d783d..477c24c8b8 100644 --- a/PrmPkg/PrmLoaderDxe/PrmLoaderDxe.c +++ b/PrmPkg/PrmLoaderDxe/PrmLoaderDxe.c @@ -73,7 +73,7 @@ ProcessPrmModules ( UINT64 HandlerPhysicalAddress;
- DEBUG ((DEBUG_INFO, "%a %a - Entry.\n", _DBGMSGID_, __FUNCTION__));
+ DEBUG ((DEBUG_INFO, "%a %a - Entry.\n", _DBGMSGID_, __func__));
if (PrmAcpiDescriptionTable == NULL) {
return EFI_INVALID_PARAMETER;
@@ -89,19 +89,19 @@ ProcessPrmModules ( DEBUG_ERROR,
" %a %a: The Platform GUID in the DSC file must be set to a unique non-zero value.\n",
_DBGMSGID_,
- __FUNCTION__
+ __func__
));
ASSERT (!CompareGuid (&gEdkiiDscPlatformGuid, &gZeroGuid));
}
- DEBUG ((DEBUG_INFO, " %a %a: %d total PRM modules to process.\n", _DBGMSGID_, __FUNCTION__, mPrmModuleCount));
- DEBUG ((DEBUG_INFO, " %a %a: %d total PRM handlers to process.\n", _DBGMSGID_, __FUNCTION__, mPrmHandlerCount));
+ DEBUG ((DEBUG_INFO, " %a %a: %d total PRM modules to process.\n", _DBGMSGID_, __func__, mPrmModuleCount));
+ DEBUG ((DEBUG_INFO, " %a %a: %d total PRM handlers to process.\n", _DBGMSGID_, __func__, mPrmHandlerCount));
PrmAcpiDescriptionTableBufferSize = (UINT32)(OFFSET_OF (PRM_ACPI_DESCRIPTION_TABLE, PrmModuleInfoStructure) +
(OFFSET_OF (PRM_MODULE_INFORMATION_STRUCT, HandlerInfoStructure) * mPrmModuleCount) +
(sizeof (PRM_HANDLER_INFORMATION_STRUCT) * mPrmHandlerCount)
);
- DEBUG ((DEBUG_INFO, " %a %a: Total PRM ACPI table size: 0x%x.\n", _DBGMSGID_, __FUNCTION__, PrmAcpiDescriptionTableBufferSize));
+ DEBUG ((DEBUG_INFO, " %a %a: Total PRM ACPI table size: 0x%x.\n", _DBGMSGID_, __func__, PrmAcpiDescriptionTableBufferSize));
PrmAcpiTable = AllocateZeroPool ((UINTN)PrmAcpiDescriptionTableBufferSize);
if (PrmAcpiTable == NULL) {
@@ -139,7 +139,7 @@ ProcessPrmModules ( DEBUG_INFO,
" %a %a: PRM Module - %a with %d handlers.\n",
_DBGMSGID_,
- __FUNCTION__,
+ __func__,
(CHAR8 *)((UINTN)CurrentImageAddress + CurrentImageExportDirectory->Name),
CurrentExportDescriptorStruct->Header.NumberPrmHandlers
));
@@ -212,7 +212,7 @@ ProcessPrmModules ( DEBUG_INFO,
" %a %a: Found %a handler physical address at 0x%016x.\n",
_DBGMSGID_,
- __FUNCTION__,
+ __func__,
CurrentExportDescriptorHandlerName,
CurrentHandlerInfoStruct->PhysicalAddress
));
@@ -279,7 +279,7 @@ PublishPrmAcpiTable ( &TableKey
);
if (!EFI_ERROR (Status)) {
- DEBUG ((DEBUG_INFO, "%a %a: The PRMT ACPI table was installed successfully.\n", _DBGMSGID_, __FUNCTION__));
+ DEBUG ((DEBUG_INFO, "%a %a: The PRMT ACPI table was installed successfully.\n", _DBGMSGID_, __func__));
}
}
@@ -316,7 +316,7 @@ PrmLoaderEndOfDxeNotification ( EFI_STATUS Status;
PRM_ACPI_DESCRIPTION_TABLE *PrmAcpiDescriptionTable;
- DEBUG ((DEBUG_INFO, "%a %a - Entry.\n", _DBGMSGID_, __FUNCTION__));
+ DEBUG ((DEBUG_INFO, "%a %a - Entry.\n", _DBGMSGID_, __func__));
Status = DiscoverPrmModules (&mPrmModuleCount, &mPrmHandlerCount);
ASSERT_EFI_ERROR (Status);
@@ -354,7 +354,7 @@ PrmLoaderEntryPoint ( EFI_STATUS Status;
EFI_EVENT EndOfDxeEvent;
- DEBUG ((DEBUG_INFO, "%a %a - Entry.\n", _DBGMSGID_, __FUNCTION__));
+ DEBUG ((DEBUG_INFO, "%a %a - Entry.\n", _DBGMSGID_, __func__));
//
// Discover and process installed PRM modules at the End of DXE
@@ -369,7 +369,7 @@ PrmLoaderEntryPoint ( &EndOfDxeEvent
);
if (EFI_ERROR (Status)) {
- DEBUG ((DEBUG_ERROR, "%a %a: EndOfDxe callback registration failed! %r.\n", _DBGMSGID_, __FUNCTION__, Status));
+ DEBUG ((DEBUG_ERROR, "%a %a: EndOfDxe callback registration failed! %r.\n", _DBGMSGID_, __func__, Status));
ASSERT_EFI_ERROR (Status);
}
|