MdePkg: 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 MdePkg. Visual Studio versions before VS 2015 don't support __func__ and so will fail to compile. A workaround is to define __func__ as __FUNCTION__ : #define __func__ __FUNCTION__ Signed-off-by: Rebecca Cran <rebecca@quicinc.com> Reviewed-by: Michael D Kinney <michael.d.kinney@intel.com> Reviewed-by: Sunil V L <sunilvl@ventanamicro.com>
This commit is contained in:
committed by
mergify[bot]
parent
d6107c593b
commit
b17a3a133b
@@ -100,7 +100,7 @@ WriteBackInvalidateDataCache (
|
||||
VOID
|
||||
)
|
||||
{
|
||||
DEBUG ((DEBUG_ERROR, "%a: Not currently implemented on LoongArch.\n", __FUNCTION__));
|
||||
DEBUG ((DEBUG_ERROR, "%a: Not currently implemented on LoongArch.\n", __func__));
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -136,7 +136,7 @@ WriteBackInvalidateDataCacheRange (
|
||||
IN UINTN Length
|
||||
)
|
||||
{
|
||||
DEBUG ((DEBUG_ERROR, "%a: Not currently implemented on LoongArch.\n", __FUNCTION__));
|
||||
DEBUG ((DEBUG_ERROR, "%a: Not currently implemented on LoongArch.\n", __func__));
|
||||
return Address;
|
||||
}
|
||||
|
||||
@@ -191,7 +191,7 @@ WriteBackDataCacheRange (
|
||||
IN UINTN Length
|
||||
)
|
||||
{
|
||||
DEBUG ((DEBUG_ERROR, "%a: Not currently implemented on LoongArch.\n", __FUNCTION__));
|
||||
DEBUG ((DEBUG_ERROR, "%a: Not currently implemented on LoongArch.\n", __func__));
|
||||
return Address;
|
||||
}
|
||||
|
||||
|
@@ -101,7 +101,7 @@ WriteBackInvalidateDataCache (
|
||||
VOID
|
||||
)
|
||||
{
|
||||
DEBUG ((DEBUG_ERROR, "%a:RISC-V unsupported function.\n", __FUNCTION__));
|
||||
DEBUG ((DEBUG_ERROR, "%a:RISC-V unsupported function.\n", __func__));
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -137,7 +137,7 @@ WriteBackInvalidateDataCacheRange (
|
||||
IN UINTN Length
|
||||
)
|
||||
{
|
||||
DEBUG ((DEBUG_ERROR, "%a:RISC-V unsupported function.\n", __FUNCTION__));
|
||||
DEBUG ((DEBUG_ERROR, "%a:RISC-V unsupported function.\n", __func__));
|
||||
return Address;
|
||||
}
|
||||
|
||||
@@ -157,7 +157,7 @@ WriteBackDataCache (
|
||||
VOID
|
||||
)
|
||||
{
|
||||
DEBUG ((DEBUG_ERROR, "%a:RISC-V unsupported function.\n", __FUNCTION__));
|
||||
DEBUG ((DEBUG_ERROR, "%a:RISC-V unsupported function.\n", __func__));
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -192,7 +192,7 @@ WriteBackDataCacheRange (
|
||||
IN UINTN Length
|
||||
)
|
||||
{
|
||||
DEBUG ((DEBUG_ERROR, "%a:RISC-V unsupported function.\n", __FUNCTION__));
|
||||
DEBUG ((DEBUG_ERROR, "%a:RISC-V unsupported function.\n", __func__));
|
||||
return Address;
|
||||
}
|
||||
|
||||
@@ -250,6 +250,6 @@ InvalidateDataCacheRange (
|
||||
IN UINTN Length
|
||||
)
|
||||
{
|
||||
DEBUG ((DEBUG_ERROR, "%a:RISC-V unsupported function.\n", __FUNCTION__));
|
||||
DEBUG ((DEBUG_ERROR, "%a:RISC-V unsupported function.\n", __func__));
|
||||
return Address;
|
||||
}
|
||||
|
Reference in New Issue
Block a user