From de5dba8c47ffe4e16fae17539270d55e1a8604d1 Mon Sep 17 00:00:00 2001 From: Adrian Reber Date: Fri, 7 Feb 2025 09:24:19 +0100 Subject: [PATCH] vdso: handle s390x correctly MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit On s390x there is currently a build failure: criu/pie/util-vdso.c: In function ‘elf_symbol_lookup’: criu/pie/util-vdso.c:313:31: error: initialization of ‘uint32_t *’ {aka ‘unsigned int *’} from incompatible pointer type ‘Hash_t *’ {aka ‘long unsigned int *’} [-Wincompatible-pointer-types] 313 | uint32_t *h = bucket + nbucket + (j - sym_off); | ^~~~~~ Replacing uint32_t with Hash_t which is defined behind a architecture specific ifdef solves this error. Signed-off-by: Adrian Reber --- criu/pie/util-vdso.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/criu/pie/util-vdso.c b/criu/pie/util-vdso.c index 9819335d81..d16fd85f43 100644 --- a/criu/pie/util-vdso.c +++ b/criu/pie/util-vdso.c @@ -310,8 +310,8 @@ static unsigned long elf_symbol_lookup(uintptr_t mem, size_t size, addr = mem + dyn_symtab->d_un.d_ptr - load->p_vaddr; if (use_gnu_hash) { - uint32_t *h = bucket + nbucket + (j - sym_off); - uint32_t hash_val; + Hash_t *h = bucket + nbucket + (j - sym_off); + Hash_t hash_val; symbol_hash |= 1; do {