aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--com32/gpllib/acpi/xsdt.c2
-rw-r--r--com32/hdt/hdt-cli-memory.c4
-rw-r--r--com32/hdt/hdt-dump-memory.c12
-rw-r--r--com32/hdt/hdt-menu-memory.c4
-rw-r--r--com32/lib/syslinux/disk.c16
-rw-r--r--com32/modules/meminfo.c4
6 files changed, 21 insertions, 21 deletions
diff --git a/com32/gpllib/acpi/xsdt.c b/com32/gpllib/acpi/xsdt.c
index 208abc67..976c8965 100644
--- a/com32/gpllib/acpi/xsdt.c
+++ b/com32/gpllib/acpi/xsdt.c
@@ -63,7 +63,7 @@ int parse_xsdt(s_acpi * acpi)
/* Let's grab the pointed table header */
char address[16] = { 0 };
- sprintf(address, "%llx", *p);
+ sprintf(address, "%" PRIx64 "x", *p);
uint64_t *pointed_address = (uint64_t *)strtoul(address, NULL, 16);
x->entry[x->entry_count] = pointed_address;
diff --git a/com32/hdt/hdt-cli-memory.c b/com32/hdt/hdt-cli-memory.c
index c05b7cd6..a614292c 100644
--- a/com32/hdt/hdt-cli-memory.c
+++ b/com32/hdt/hdt-cli-memory.c
@@ -47,7 +47,7 @@ static void show_memory_e820(int argc __unused, char **argv __unused,
more_printf("BIOS-provided physical RAM e820 map:\n");
for (int i = 0; i < count; i++) {
get_type(map[i].type, type, 14);
- more_printf("%016llx - %016llx %016llx (%s)\n",
+ more_printf("%016" PRIx64 "x - %016" PRIx64 "x %016" PRIx64 "x (%s)\n",
map[i].addr, map[i].size, map[i].addr + map[i].size,
remove_spaces(type));
}
@@ -60,7 +60,7 @@ static void show_memory_e820(int argc __unused, char **argv __unused,
more_printf("Sanitized e820 map:\n");
for (int i = 0; i < nr; i++) {
get_type(nm[i].type, type, 14);
- more_printf("%016llx - %016llx %016llx (%s)\n",
+ more_printf("%016" PRIx64 "x - %016" PRIx64 "x %016" PRIx64 "x (%s)\n",
nm[i].addr, nm[i].size, nm[i].addr + nm[i].size,
remove_spaces(type));
}
diff --git a/com32/hdt/hdt-dump-memory.c b/com32/hdt/hdt-dump-memory.c
index 5095d3c2..224ea248 100644
--- a/com32/hdt/hdt-dump-memory.c
+++ b/com32/hdt/hdt-dump-memory.c
@@ -91,9 +91,9 @@ void dump_e820(struct s_hardware *hardware, ZZJSON_CONFIG *config, ZZJSON **item
char begin[24]={0};
char size[24]={0};
char end[24]={0};
- snprintf(begin,sizeof(begin),"0x%016llx",map[i].addr);
- snprintf(size,sizeof(size),"0x%016llx",map[i].size);
- snprintf(end,sizeof(end),"0x%016llx",map[i].addr+map[i].size);
+ snprintf(begin,sizeof(begin),"0x%016" PRIx64 "x",map[i].addr);
+ snprintf(size,sizeof(size),"0x%016" PRIx64 "x",map[i].size);
+ snprintf(end,sizeof(end),"0x%016" PRIx64 "x",map[i].addr+map[i].size);
CREATE_NEW_OBJECT;
add_s("memory.segment.start",begin);
add_s("memory.segment.size ",size);
@@ -108,9 +108,9 @@ void dump_e820(struct s_hardware *hardware, ZZJSON_CONFIG *config, ZZJSON **item
char begin[24]={0};
char size[24]={0};
char end[24]={0};
- snprintf(begin,sizeof(begin),"0x%016llx",nm[i].addr);
- snprintf(size,sizeof(size),"0x%016llx",nm[i].size);
- snprintf(end,sizeof(end),"0x%016llx",nm[i].addr+nm[i].size);
+ snprintf(begin,sizeof(begin),"0x%016" PRIx64 "x",nm[i].addr);
+ snprintf(size,sizeof(size),"0x%016" PRIx64 "x",nm[i].size);
+ snprintf(end,sizeof(end),"0x%016" PRIx64 "x",nm[i].addr+nm[i].size);
CREATE_NEW_OBJECT;
add_s("sanitized_memory.segment.start",begin);
add_s("sanitized_memory.segment.size ",size);
diff --git a/com32/hdt/hdt-menu-memory.c b/com32/hdt/hdt-menu-memory.c
index 60d741de..ae6fc676 100644
--- a/com32/hdt/hdt-menu-memory.c
+++ b/com32/hdt/hdt-menu-memory.c
@@ -57,10 +57,10 @@ static void compute_e820(struct s_my_menu *menu)
for (int j = 0; j < count; j++) {
get_type(map[j].type, type, 14);
snprintf(buffer, sizeof buffer,
- "%016llx - %016llx (%s)",
+ "%016" PRIx64 "x - %016" PRIx64 "x (%s)",
map[j].addr, map[j].size, remove_spaces(type));
snprintf(statbuffer, sizeof statbuffer,
- "%016llx - %016llx (%s)",
+ "%016" PRIx64 "x - %016" PRIx64 "x (%s)",
map[j].addr, map[j].size, remove_spaces(type));
add_item(buffer, statbuffer, OPT_INACTIVE, NULL, 0);
menu->items_count++;
diff --git a/com32/lib/syslinux/disk.c b/com32/lib/syslinux/disk.c
index 5a99bb42..afbfc846 100644
--- a/com32/lib/syslinux/disk.c
+++ b/com32/lib/syslinux/disk.c
@@ -528,9 +528,9 @@ void disk_gpt_part_dump(const struct disk_gpt_part_entry *const gpt_part)
char guid_text[37];
dprintf("----------------------------------\n"
- "GPT part. LBA first __ : 0x%.16llx\n"
- "GPT part. LBA last ___ : 0x%.16llx\n"
- "GPT part. attribs ____ : 0x%.16llx\n"
+ "GPT part. LBA first __ : 0x%.16" PRIx64 "x\n"
+ "GPT part. LBA last ___ : 0x%.16" PRIx64 "x\n"
+ "GPT part. attribs ____ : 0x%.16" PRIx64 "x\n"
"GPT part. name _______ : '",
gpt_part->lba_first, gpt_part->lba_last, gpt_part->attribs);
for (i = 0; i < sizeof(gpt_part->name); i++) {
@@ -559,11 +559,11 @@ void disk_gpt_header_dump(const struct disk_gpt_header *const gpt)
"GPT header size ______ : 0x%.8x\n"
"GPT header checksum __ : 0x%.8x\n"
"GPT reserved _________ : '%4.4s'\n"
- "GPT LBA current ______ : 0x%.16llx\n"
- "GPT LBA alternative __ : 0x%.16llx\n"
- "GPT LBA first usable _ : 0x%.16llx\n"
- "GPT LBA last usable __ : 0x%.16llx\n"
- "GPT LBA part. table __ : 0x%.16llx\n"
+ "GPT LBA current ______ : 0x%.16" PRIx64 "x\n"
+ "GPT LBA alternative __ : 0x%.16" PRIx64 "x\n"
+ "GPT LBA first usable _ : 0x%.16" PRIx64 "x\n"
+ "GPT LBA last usable __ : 0x%.16" PRIx64 "x\n"
+ "GPT LBA part. table __ : 0x%.16" PRIx64 "x\n"
"GPT partition count __ : 0x%.8x\n"
"GPT partition size ___ : 0x%.8x\n"
"GPT part. table chksum : 0x%.8x\n",
diff --git a/com32/modules/meminfo.c b/com32/modules/meminfo.c
index fc04792f..c8f953bf 100644
--- a/com32/modules/meminfo.c
+++ b/com32/modules/meminfo.c
@@ -71,12 +71,12 @@ static void dump_e820(void)
if (oreg.ecx.l >= 24) {
/* ebx base length end type */
- printf("%8x %016llx %016llx %016llx %d [%x]",
+ printf("%8x %016" PRIx64 "x %016" PRIx64 "x %016" PRIx64 "x %d [%x]",
ireg.ebx.l, ed.base, ed.len, ed.base + ed.len, ed.type,
ed.extattr);
} else {
/* ebx base length end */
- printf("%8x %016llx %016llx %016llx %d [-]",
+ printf("%8x %016" PRIx64 "x %016" PRIx64 "x %016" PRIx64 "x %d [-]",
ireg.ebx.l, ed.base, ed.len, ed.base + ed.len, ed.type);
ed.extattr = 1;
}