aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--checks.c2
-rw-r--r--dtc.h1
2 files changed, 2 insertions, 1 deletions
diff --git a/checks.c b/checks.c
index 4b72b53..afabf64 100644
--- a/checks.c
+++ b/checks.c
@@ -873,7 +873,7 @@ static void check_simple_bus_reg(struct check *c, struct dt_info *dti, struct no
while (size--)
reg = (reg << 32) | fdt32_to_cpu(*(cells++));
- snprintf(unit_addr, sizeof(unit_addr), "%zx", reg);
+ snprintf(unit_addr, sizeof(unit_addr), "%"PRIx64, reg);
if (!streq(unitname, unit_addr))
FAIL(c, dti, "Node %s simple-bus unit address format error, expected \"%s\"",
node->fullpath, unit_addr);
diff --git a/dtc.h b/dtc.h
index fc24e17..409db76 100644
--- a/dtc.h
+++ b/dtc.h
@@ -31,6 +31,7 @@
#include <ctype.h>
#include <errno.h>
#include <unistd.h>
+#include <inttypes.h>
#include <libfdt_env.h>
#include <fdt.h>