fix/kernel: Proper memcmp usage in acpi_init
This commit is contained in:
parent
74ef29a2ea
commit
a7e9e1339e
1 changed files with 3 additions and 1 deletions
|
@ -18,9 +18,11 @@ void acpi_init(void)
|
||||||
|
|
||||||
acpi_rsdp_t *rsdp = (acpi_rsdp_t *)vallocat(kvm_ctx, 1, VALLOC_RW, rsdp_response->address);
|
acpi_rsdp_t *rsdp = (acpi_rsdp_t *)vallocat(kvm_ctx, 1, VALLOC_RW, rsdp_response->address);
|
||||||
|
|
||||||
if (memcmp(rsdp->signature, "RSD PTR", 7) == 0)
|
if (memcmp(rsdp->signature, "RSD PTR", 7) != 0)
|
||||||
kpanic(NULL, "Invalid RSDP signature!");
|
kpanic(NULL, "Invalid RSDP signature!");
|
||||||
|
|
||||||
|
log_early("RSDP Signature: %.*s", 7, rsdp->signature);
|
||||||
|
|
||||||
if (rsdp->revision != 0)
|
if (rsdp->revision != 0)
|
||||||
{
|
{
|
||||||
acpi_uses_xsdt = 1;
|
acpi_uses_xsdt = 1;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue