stdio: Added LOG_ specifiers to all prints
Signed-off-by: Michael Shaw <spencershawiscool@gmail.com>
This commit is contained in:
parent
25abb1f0f5
commit
92396db851
6 changed files with 21 additions and 12 deletions
18
init/acpi.c
18
init/acpi.c
|
|
@ -15,7 +15,7 @@ struct madt *__madt = NULL;
|
|||
void rsdt_print(struct rsdt *rsdt)
|
||||
{
|
||||
int num_sdt = (rsdt->h.length - sizeof(rsdt->h)) / 4;
|
||||
printf("Number of RSDT entries: %d\n", num_sdt);
|
||||
printf(LOG_INFO "Number of RSDT entries: %d\n", num_sdt);
|
||||
|
||||
for (int i = 0; i < num_sdt; i++) {
|
||||
/* 2 steps silences warning */
|
||||
|
|
@ -28,7 +28,8 @@ void rsdt_print(struct rsdt *rsdt)
|
|||
|
||||
char buf[9];
|
||||
memcpy(buf, h->signature, 4);
|
||||
printf("[ACPI] %s %d %x \n", buf, h->revision, h->checksum);
|
||||
printf(LOG_INFO "[ACPI] %s %d %x \n", buf, h->revision,
|
||||
h->checksum);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -41,18 +42,23 @@ void acpi_init()
|
|||
struct rsdt *rsdt = (struct rsdt *)rsdt_addr;
|
||||
rsdt_print(rsdt);
|
||||
|
||||
printf(LOG_ERROR "Test\n");
|
||||
printf(LOG_WARN "Test\n");
|
||||
printf(LOG_SUCCESS "Test\n");
|
||||
printf(LOG_INFO "Test\n");
|
||||
|
||||
if (__madt == NULL) {
|
||||
printf("Failed to locate MADT\n");
|
||||
printf(LOG_WARN "Failed to locate MADT\n");
|
||||
} else {
|
||||
/* First variable entry in MADT */
|
||||
int offset = 0x2C;
|
||||
int length = __madt->h.length;
|
||||
printf("MADT Length: %x\n", length);
|
||||
printf(LOG_INFO "MADT Length: %x\n", length);
|
||||
|
||||
while ((offset = madt_parse_next_entry(offset)))
|
||||
;
|
||||
}
|
||||
|
||||
printf("ACPI version: %d\n", rsdp->revision);
|
||||
printf("ACPI initialized\n");
|
||||
printf(LOG_INFO "ACPI version: %d\n", rsdp->revision);
|
||||
printf(LOG_INFO "ACPI initialized\n");
|
||||
}
|
||||
|
|
|
|||
|
|
@ -28,5 +28,5 @@ void gdt_init()
|
|||
__gdtr.offset = (uint64_t)__gdt;
|
||||
gdt_load();
|
||||
|
||||
printf("GDT initialized\n");
|
||||
printf(LOG_SUCCESS "GDT initialized\n");
|
||||
}
|
||||
|
|
|
|||
|
|
@ -23,5 +23,5 @@ void idt_init()
|
|||
__idtr.offset = (uint64_t)__idt;
|
||||
idt_load();
|
||||
|
||||
printf("IDT successfully loaded\n");
|
||||
printf(LOG_SUCCESS "IDT successfully loaded\n");
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue