From 54016e273e2edeb186490a403b7be5d443e6bd3b Mon Sep 17 00:00:00 2001 From: Yu-Ping Wu Date: Wed, 30 Jul 2025 03:32:20 +0800 Subject: [PATCH] util/cbmem/sysfs_drv: Fix incompatible pointer type for 'size' Fix the following error for armv7a-cros-linux-gnueabihf-clang. sysfs_drv.c:247:49: error: incompatible pointer types passing 'uint64_t *' (aka 'unsigned long long *') to parameter of type 'size_t *' (aka 'unsigned int *') [-Werror,-Wincompatible-pointer-types] 247 | if (!cbmem_sysfs_probe_cbmem_entry(id, &addr, &size)) | ^~~~~ sysfs_drv.c:99:84: note: passing argument to parameter 'size_out' here 99 | ...id, uint64_t *addr_out, size_t *size_out) | ^ 1 error generated. BUG=b:434971585 TEST=none BRANCH=none Change-Id: I5e2be25d57c5e69501564b6e8b6d880ec046bc3b Signed-off-by: Yu-Ping Wu Reviewed-on: https://review.coreboot.org/c/coreboot/+/88605 Reviewed-by: Paul Menzel Tested-by: build bot (Jenkins) --- util/cbmem/sysfs_drv.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/util/cbmem/sysfs_drv.c b/util/cbmem/sysfs_drv.c index 2820bbd4ee..cb4a4ab540 100644 --- a/util/cbmem/sysfs_drv.c +++ b/util/cbmem/sysfs_drv.c @@ -239,7 +239,7 @@ void cbmem_sysfs_foreach_cbmem_entry(cbmem_iterator_callback cb, void *data, boo continue; uint64_t addr = 0; - uint64_t size = 0; + size_t size = 0; uint8_t *buf; /* If entry was not found or previously matched directory