mirror of
https://github.com/linuxboot/heads.git
synced 2024-12-20 21:43:11 +00:00
146b78e08c
Add patches for coreboot 4.17: - show ME status even when device is disable (kept from 4.15) - zero unused part of SMBIOS region Signed-off-by: Daniel Pineda <daniel.pineda@puri.sm>
35 lines
1.3 KiB
Diff
35 lines
1.3 KiB
Diff
From 517c2ad54bfc44b984457ca30c34410487eb2be9 Mon Sep 17 00:00:00 2001
|
|
From: Jonathon Hall <jonathon.hall@puri.sm>
|
|
Date: Wed, 27 Jul 2022 09:45:40 -0400
|
|
Subject: [PATCH 3/3] x86: Zero unused part of SMBIOS region
|
|
|
|
Since SMBIOS was increased from 4K to 32K, the unused region could include
|
|
parts of the ACPI region from a prior boot, which may confuse the OS if it
|
|
finds remanent table signatures.
|
|
|
|
Change-Id: I0ebac7c70a6887c6d3380702d242618e86e84185
|
|
Signed-off-by: Jonathon Hall <jonathon.hall@puri.sm>
|
|
---
|
|
src/arch/x86/tables.c | 5 +++++
|
|
1 file changed, 5 insertions(+)
|
|
|
|
diff --git a/src/arch/x86/tables.c b/src/arch/x86/tables.c
|
|
index 8d2f7b6f20..282dfc58a8 100644
|
|
--- a/src/arch/x86/tables.c
|
|
+++ b/src/arch/x86/tables.c
|
|
@@ -151,6 +151,11 @@ static unsigned long write_smbios_table(unsigned long rom_table_end)
|
|
|
|
new_high_table_pointer =
|
|
smbios_write_tables(high_table_pointer);
|
|
+ /* Clear the unused part of the region, in case other table
|
|
+ * signatures could be present from a prior boot
|
|
+ */
|
|
+ memset((void *)new_high_table_pointer, 0, high_table_pointer +
|
|
+ MAX_SMBIOS_SIZE - new_high_table_pointer);
|
|
rom_table_end = ALIGN_UP(rom_table_end, 16);
|
|
memcpy((void *)rom_table_end, (void *)high_table_pointer,
|
|
sizeof(struct smbios_entry));
|
|
--
|
|
2.25.1
|
|
|