Paul Menzel has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/51843 )
Change subject: soc/amd: smbus: Use correct type for uintptr_t ......................................................................
soc/amd: smbus: Use correct type for uintptr_t
Fix the format warning below by using `PRIxPTR`, which is defined as unsigned long.
src/soc/amd/common/block/smbus/smbus.c:33:56: error: format specifies type 'size_t' (aka 'unsigned int') but the argument has type 'uintptr_t' (aka 'unsigned long') [-Werror,-Wformat] printk(BIOS_ERR, "Invalid SMBus or ASF base %#zx\n", mmio); ~~~~ ^~~~ %#lx src/include/console/console.h:60:61: note: expanded from macro 'printk' #define printk(LEVEL, fmt, args...) do_printk(LEVEL, fmt, ##args) ~~~ ^~~~ 1 error generated.
Change-Id: I727c490d3097dcf36cdbcd4db2852cd49d11785f Signed-off-by: Paul Menzel pmenzel@molgen.mpg.de --- M src/soc/amd/common/block/smbus/smbus.c 1 file changed, 1 insertion(+), 1 deletion(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/43/51843/1
diff --git a/src/soc/amd/common/block/smbus/smbus.c b/src/soc/amd/common/block/smbus/smbus.c index 9fd18c5..5b3048c 100644 --- a/src/soc/amd/common/block/smbus/smbus.c +++ b/src/soc/amd/common/block/smbus/smbus.c @@ -30,7 +30,7 @@ { if ((mmio != (uintptr_t)acpimmio_smbus) && (mmio != (uintptr_t)acpimmio_asf)) { - printk(BIOS_ERR, "Invalid SMBus or ASF base %#zx\n", mmio); + printk(BIOS_ERR, "Invalid SMBus or ASF base %#" PRIxPTR "\n", mmio); return -1; }