From: Ian Campbell Date: Fri, 24 Jul 2015 10:41:17 +0000 (+0100) Subject: tools: libxl: Use correct printf format for uint64_t X-Git-Tag: archive/raspbian/4.8.0-1+rpi1~1^2~2688 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=78222eb476e24833880a94e8cbd193e797abbe18;p=xen.git tools: libxl: Use correct printf format for uint64_t Since 25652f232cbe "tools/libxl: detect and avoid conflicts with RDM" the build is broken for x86_32 and arm32 with: libxl_dm.c: In function ‘libxl__domain_device_construct_rdm’: libxl_dm.c:349:13: error: format ‘%lx’ expects argument of type ‘long unsigned int’, but argument 8 has type ‘uint64_t’ [-Werror=format=] LOG(ERROR, "RDM conflict at 0x%lx.\n", d_config->rdms[i].start); ^ libxl_dm.c:352:13: error: format ‘%lx’ expects argument of type ‘long unsigned int’, but argument 8 has type ‘uint64_t’ [-Werror=format=] LOG(WARN, "Ignoring RDM conflict at 0x%lx.\n", Use PRIx64 for these. Signed-off-by: Ian Campbell Acked-by: Ian Jackson Acked-by: Wei Liu Cc: Tiejun Chen --- diff --git a/tools/libxl/libxl_dm.c b/tools/libxl/libxl_dm.c index 8d103c3676..8ac007a679 100644 --- a/tools/libxl/libxl_dm.c +++ b/tools/libxl/libxl_dm.c @@ -346,10 +346,11 @@ int libxl__domain_device_construct_rdm(libxl__gc *gc, continue; if (d_config->rdms[i].policy == LIBXL_RDM_RESERVE_POLICY_STRICT) { - LOG(ERROR, "RDM conflict at 0x%lx.\n", d_config->rdms[i].start); + LOG(ERROR, "RDM conflict at 0x%"PRIx64".\n", + d_config->rdms[i].start); goto out; } else { - LOG(WARN, "Ignoring RDM conflict at 0x%lx.\n", + LOG(WARN, "Ignoring RDM conflict at 0x%"PRIx64".\n", d_config->rdms[i].start); /*