misc: Use %p where appropriate in prints

This commit is contained in:
mintsuki 2021-12-10 03:18:19 +01:00
parent 48828f316b
commit d0e0248f9c
2 changed files with 6 additions and 6 deletions

View File

@ -26,7 +26,7 @@ void *acpi_get_rsdp(void) {
}
if (!memcmp((char *)i, "RSD PTR ", 8)
&& !acpi_checksum((void *)i, 20)) {
printv("acpi: Found RSDP at %x\n", i);
printv("acpi: Found RSDP at %p\n", i);
return (void *)i;
}
}
@ -58,7 +58,7 @@ void acpi_get_smbios(void **smbios32, void **smbios64) {
if (!memcmp(ptr->anchor_str, "_SM_", 4) &&
!acpi_checksum((void *)ptr, ptr->length)) {
printv("acpi: Found SMBIOS 32-bit entry point at %x\n", i);
printv("acpi: Found SMBIOS 32-bit entry point at %p\n", i);
*smbios32 = (void *)ptr;
break;
}
@ -69,7 +69,7 @@ void acpi_get_smbios(void **smbios32, void **smbios64) {
if (!memcmp(ptr->anchor_str, "_SM3_", 5) &&
!acpi_checksum((void *)ptr, ptr->length)) {
printv("acpi: Found SMBIOS 64-bit entry point at %x\n", i);
printv("acpi: Found SMBIOS 64-bit entry point at %p\n", i);
*smbios64 = (void *)ptr;
break;
}
@ -101,7 +101,7 @@ void *acpi_get_rsdp(void) {
(is_rsdp && acpi_checksum(cur_table->VendorTable, 20) != 0)) // RSDP is 20 bytes wide
continue;
printv("acpi: Found %s at %X\n", is_xsdp ? "XSDP" : "RSDP", cur_table->VendorTable);
printv("acpi: Found %s at %p\n", is_xsdp ? "XSDP" : "RSDP", cur_table->VendorTable);
// We want to return the XSDP if it exists rather then returning
// the RSDP. We need to add a check for that since the table entries

View File

@ -66,9 +66,9 @@ void print_stacktrace(size_t *base_ptr) {
size_t off;
char *name = trace_address(&off, ret_addr);
if (name)
print(" [%x] <%s+%x>\n", ret_addr, name, off);
print(" [%p] <%s+%p>\n", ret_addr, name, off);
else
print(" [%x]\n", ret_addr);
print(" [%p]\n", ret_addr);
if (!old_bp)
break;
base_ptr = (void*)old_bp;