diff options
author | Geoff Levand <geoff@infradead.org> | 2018-01-06 00:47:39 +0000 |
---|---|---|
committer | Samuel Mendoza-Jonas <sam@mendozajonas.com> | 2018-01-10 13:34:54 +1100 |
commit | 41caf09e98b14e34830f524405efc1bdd4087365 (patch) | |
tree | 51c4ff3af3a20d41277b5b2318d141713cfbaa46 /utils | |
parent | c462aa6f8e4658ed23df16bc9e1822e384744e53 (diff) | |
download | talos-petitboot-41caf09e98b14e34830f524405efc1bdd4087365.tar.gz talos-petitboot-41caf09e98b14e34830f524405efc1bdd4087365.zip |
printf: Fix format type warnings
Fixes build warnings like these when building 32 bit programs:
warning: format ‘%lu’ expects argument of type ‘long unsigned int’, but argument has type ‘uint64_t’
Signed-off-by: Geoff Levand <geoff@infradead.org>
Signed-off-by: Samuel Mendoza-Jonas <sam@mendozajonas.com>
Diffstat (limited to 'utils')
-rw-r--r-- | utils/hooks/30-dtb-updates.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/utils/hooks/30-dtb-updates.c b/utils/hooks/30-dtb-updates.c index e161d87..f7de976 100644 --- a/utils/hooks/30-dtb-updates.c +++ b/utils/hooks/30-dtb-updates.c @@ -257,7 +257,7 @@ static int do_translate(void *fdt, int node, current_pci_flags = na > 2 ? of_read_number(addr, 1) : 0; child_pci_flags = cna > 2 ? of_read_number(ranges, 1) : 0; if (current_pci_flags != 0 && current_pci_flags != child_pci_flags) { - fprintf(stderr, "Unexpected change in flags: %lx, %lx\n", + fprintf(stderr, "Unexpected change in flags: %" PRIu64 ", %" PRIu64 "\n", current_pci_flags, child_pci_flags); return -1; } @@ -324,7 +324,7 @@ static int do_translate(void *fdt, int node, fprintf(stderr, "New address:\n\t"); for (i = 0; i < *addr_cells; i++) - fprintf(stderr, " %lx ", of_read_number(&addr[i], 1)); + fprintf(stderr, " %" PRIu64 " ", of_read_number(&addr[i], 1)); fprintf(stderr, "\n"); return 0; @@ -382,7 +382,7 @@ static int create_translated_addresses(struct offb_ctx *ctx, fprintf(stderr, "Final address:\n\t"); for (i = 0; i < addr_cells; i++) - fprintf(stderr, " %lx ", of_read_number(&addr[i], 1)); + fprintf(stderr, " %" PRIu64 " ", of_read_number(&addr[i], 1)); fprintf(stderr, "\n"); if (addr_cells + size_cells > reg_cells) { |