vc/amd/agesa/f15tn: Declare `value` as constant in `GnbRegisterWriteTNDump()`
Do not discard the const qualifier in `GnbRegisterWriteTNDump()` to fix the compiler warning below. CC libagesa/vendorcode/amd/agesa/f15tn/Proc/GNB/Modules/GnbInitTN/GnbRegisterAccTN.o In file included from src/vendorcode/amd/agesa/f15tn/Proc/GNB/Modules/GnbInitTN/GnbRegisterAccTN.c:53: src/vendorcode/amd/agesa/f15tn/Proc/GNB/Modules/GnbInitTN/GnbRegisterAccTN.c: In function 'GnbRegisterWriteTN': src/vendorcode/amd/agesa/f15tn/Proc/GNB/Modules/GnbInitTN/GnbRegisterAccTN.c:836:57: error: passing argument 3 of 'GnbRegisterWriteTNDump' discards 'const' qualifier from pointer target type [-Werror=discarded-qualifiers] 836 | GnbRegisterWriteTNDump (RegisterSpaceType, Address, Value); | ^~~~~ src/vendorcode/amd/agesa/f15tn/Proc/GNB/Common/Gnb.h:68:35: note: in definition of macro 'GNB_DEBUG_CODE' 68 | #define GNB_DEBUG_CODE(Code) Code | ^~~~ src/vendorcode/amd/agesa/f15tn/Proc/GNB/Modules/GnbInitTN/GnbRegisterAccTN.c:86:33: note: expected 'VOID *' {aka 'void *'} but argument is of type 'const VOID *' {aka 'const void *'} 86 | IN VOID *Value | ~~~~~~~~~~~~~~~~~~~~~^~~~~ CC libagesa/vendorcode/amd/agesa/f15tn/Proc/GNB/Modules/GnbInitTN/PcieComplexDataTN.o CC libagesa/vendorcode/amd/agesa/f15tn/Proc/GNB/Modules/GnbInitTN/PcieConfigTN.o CC libagesa/vendorcode/amd/agesa/f15tn/Proc/GNB/Modules/GnbInitTN/PcieEarlyInitTN.o CC libagesa/vendorcode/amd/agesa/f15tn/Proc/GNB/Modules/GnbInitTN/PcieEnvInitTN.o CC libagesa/vendorcode/amd/agesa/f15tn/Proc/GNB/Modules/GnbInitTN/PcieLibTN.o src/vendorcode/amd/agesa/f15tn/Proc/GNB/Modules/GnbInitTN/GnbRegisterAccTN.c: At top level: cc1: note: unrecognized command-line option '-Wno-pragma-pack' may have been intended to silence earlier diagnostics cc1: all warnings being treated as errors Found-by: gcc (Debian 11.3.0-3) 11.3.0 Change-Id: I2039cf66030030458bd247a31adc0621b9d033e6 Signed-off-by: Paul Menzel <pmenzel@molgen.mpg.de> Reviewed-on: https://review.coreboot.org/c/coreboot/+/64989 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Arthur Heymans <arthur@aheymans.xyz>
This commit is contained in:
parent
7f339c6050
commit
970554f90d
|
@ -83,7 +83,7 @@ VOID
|
||||||
GnbRegisterWriteTNDump (
|
GnbRegisterWriteTNDump (
|
||||||
IN UINT8 RegisterSpaceType,
|
IN UINT8 RegisterSpaceType,
|
||||||
IN UINT32 Address,
|
IN UINT32 Address,
|
||||||
IN VOID *Value
|
CONST IN VOID *Value
|
||||||
);
|
);
|
||||||
AGESA_STATUS
|
AGESA_STATUS
|
||||||
GnbRegisterReadServiceTN (
|
GnbRegisterReadServiceTN (
|
||||||
|
@ -1265,7 +1265,7 @@ VOID
|
||||||
GnbRegisterWriteTNDump (
|
GnbRegisterWriteTNDump (
|
||||||
IN UINT8 RegisterSpaceType,
|
IN UINT8 RegisterSpaceType,
|
||||||
IN UINT32 Address,
|
IN UINT32 Address,
|
||||||
IN VOID *Value
|
CONST IN VOID *Value
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
IDS_HDT_CONSOLE (NB_MISC, " R WRITE Space %s Address 0x%04x, Value 0x%04x\n",
|
IDS_HDT_CONSOLE (NB_MISC, " R WRITE Space %s Address 0x%04x, Value 0x%04x\n",
|
||||||
|
|
Loading…
Reference in New Issue