summaryrefslogtreecommitdiff
path: root/disk/part_efi.c
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2014-11-11 12:47:07 -0700
committerSimon Glass <sjg@chromium.org>2014-11-26 20:25:39 -0700
commite48f3741c357246c78aa367bbd56fe2684f7bf8d (patch)
tree0b06728376e9e72d7375194809088ca0a0359c6b /disk/part_efi.c
parent85bafb6da4dddfffa78479aa49a72ae48578a4ce (diff)
downloadu-boot-imx-e48f3741c357246c78aa367bbd56fe2684f7bf8d.zip
u-boot-imx-e48f3741c357246c78aa367bbd56fe2684f7bf8d.tar.gz
u-boot-imx-e48f3741c357246c78aa367bbd56fe2684f7bf8d.tar.bz2
sandbox: Fix warnings due to 64-bit printf() strings
Now that we have inttypes.h, use it in a few more places to avoid compiler warnings on sandbox when building on 64-bit machines. Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'disk/part_efi.c')
-rw-r--r--disk/part_efi.c21
1 files changed, 11 insertions, 10 deletions
diff --git a/disk/part_efi.c b/disk/part_efi.c
index 612f092..efed58f 100644
--- a/disk/part_efi.c
+++ b/disk/part_efi.c
@@ -14,6 +14,7 @@
#include <common.h>
#include <command.h>
#include <ide.h>
+#include <inttypes.h>
#include <malloc.h>
#include <part_efi.h>
#include <linux/ctype.h>
@@ -553,28 +554,28 @@ static int is_gpt_valid(block_dev_desc_t *dev_desc, u64 lba,
/* Check that the my_lba entry points to the LBA that contains the GPT */
if (le64_to_cpu(pgpt_head->my_lba) != lba) {
- printf("GPT: my_lba incorrect: %llX != %llX\n",
- le64_to_cpu(pgpt_head->my_lba),
- lba);
+ printf("GPT: my_lba incorrect: %llX != %" PRIX64 "\n",
+ le64_to_cpu(pgpt_head->my_lba),
+ lba);
return 0;
}
/* Check the first_usable_lba and last_usable_lba are within the disk. */
lastlba = (u64)dev_desc->lba;
if (le64_to_cpu(pgpt_head->first_usable_lba) > lastlba) {
- printf("GPT: first_usable_lba incorrect: %llX > %llX\n",
- le64_to_cpu(pgpt_head->first_usable_lba), lastlba);
+ printf("GPT: first_usable_lba incorrect: %llX > %" PRIX64 "\n",
+ le64_to_cpu(pgpt_head->first_usable_lba), lastlba);
return 0;
}
if (le64_to_cpu(pgpt_head->last_usable_lba) > lastlba) {
- printf("GPT: last_usable_lba incorrect: %llX > %llX\n",
- le64_to_cpu(pgpt_head->last_usable_lba), lastlba);
+ printf("GPT: last_usable_lba incorrect: %llX > %" PRIX64 "\n",
+ le64_to_cpu(pgpt_head->last_usable_lba), lastlba);
return 0;
}
- debug("GPT: first_usable_lba: %llX last_usable_lba %llX last lba %llX\n",
- le64_to_cpu(pgpt_head->first_usable_lba),
- le64_to_cpu(pgpt_head->last_usable_lba), lastlba);
+ debug("GPT: first_usable_lba: %llX last_usable_lba %llX last lba %"
+ PRIX64 "\n", le64_to_cpu(pgpt_head->first_usable_lba),
+ le64_to_cpu(pgpt_head->last_usable_lba), lastlba);
/* Read and allocate Partition Table Entries */
*pgpt_pte = alloc_read_gpt_entries(dev_desc, pgpt_head);