freedreno/perfcntrs/fdperf: fix u64 print on 32-bit builds
authorJonathan Marek <jonathan@marek.ca>
Wed, 27 Nov 2019 15:44:57 +0000 (10:44 -0500)
committerJonathan Marek <jonathan@marek.ca>
Wed, 27 Nov 2019 17:11:57 +0000 (12:11 -0500)
Signed-off-by: Jonathan Marek <jonathan@marek.ca>
Reviewed-by: Rob Clark <robdclark@chromium.org>
src/freedreno/perfcntrs/fdperf.c

index 7e562367df67d3cac228767f75e5c0301d552c43..45d2a18ebe2b3b4f5e93a2683adea80983e7926f 100644 (file)
@@ -39,6 +39,7 @@
 #include <unistd.h>
 #include <curses.h>
 #include <libconfig.h>
+#include <inttypes.h>
 
 #include "drm/freedreno_drmif.h"
 #include "drm/freedreno_ringbuffer.h"
@@ -369,7 +370,7 @@ find_device(void)
 
        free(b);
 
-       printf("i/o region at %08lx (size: %x)\n", dev.base, dev.size);
+       printf("i/o region at %08"PRIu64" (size: %x)\n", dev.base, dev.size);
 
        /* try MAX_FREQ first as that will work regardless of old dt
         * dt bindings vs upstream bindings: