limine: Do not return SMBIOS response if not present

This commit is contained in:
mintsuki 2023-08-10 19:01:07 -05:00
parent 49b27fc47b
commit 0baf774eef
1 changed files with 5 additions and 1 deletions

View File

@ -614,7 +614,11 @@ FEAT_START
smbios_response->entry_64 = reported_addr(smbios_entry_64);
}
smbios_request->response = reported_addr(smbios_response);
if (smbios_entry_32 == NULL && smbios_entry_64 == NULL) {
pmm_free(smbios_response, sizeof(struct limine_smbios_response));
} else {
smbios_request->response = reported_addr(smbios_response);
}
FEAT_END
#if defined (UEFI)