|
|
9ae3a8 |
From 464ceecd1e9c070e613624fb896df54b7e4a3e38 Mon Sep 17 00:00:00 2001
|
|
|
9ae3a8 |
From: Laszlo Ersek <lersek@redhat.com>
|
|
|
9ae3a8 |
Date: Wed, 11 May 2016 12:33:42 +0200
|
|
|
9ae3a8 |
Subject: [PATCH 03/10] acpi: strip compiler info in built-in DSDT
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
RH-Author: Laszlo Ersek <lersek@redhat.com>
|
|
|
9ae3a8 |
Message-id: <1462970028-10959-2-git-send-email-lersek@redhat.com>
|
|
|
9ae3a8 |
Patchwork-id: 70378
|
|
|
9ae3a8 |
O-Subject: [RHEL-7.3 qemu-kvm PATCH v2 1/7] acpi: strip compiler info in built-in DSDT
|
|
|
9ae3a8 |
Bugzilla: 1330969
|
|
|
9ae3a8 |
RH-Acked-by: Igor Mammedov <imammedo@redhat.com>
|
|
|
9ae3a8 |
RH-Acked-by: Michael S. Tsirkin <mst@redhat.com>
|
|
|
9ae3a8 |
RH-Acked-by: Thomas Huth <thuth@redhat.com>
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
From: "Michael S. Tsirkin" <mst@redhat.com>
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
IASL stores it's revision in each table header it generates.
|
|
|
9ae3a8 |
That's not nice since guests will see a change each time they move
|
|
|
9ae3a8 |
between hypervisors. We generally fill our own info for tables, but we
|
|
|
9ae3a8 |
(and seabios) forgot to do this for the built-in DSDT.
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
Modifications in DSDT table:
|
|
|
9ae3a8 |
OEM ID: "BXPC" -> "BOCHS "
|
|
|
9ae3a8 |
OEM Table ID: "BXDSDT" -> "BXPCDSDT"
|
|
|
9ae3a8 |
Compiler ID: "INTL" -> "BXPC"
|
|
|
9ae3a8 |
Compiler Version: 0x20130823 -> 0x00000001
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
Tested-by: Marcel Apfelbaum <marcel.a@redhat.com>
|
|
|
9ae3a8 |
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
|
|
|
9ae3a8 |
(cherry picked from commit 53db092ad1c81c30a617f44e83e8fb9e27c001ba)
|
|
|
9ae3a8 |
Signed-off-by: Laszlo Ersek <lersek@redhat.com>
|
|
|
9ae3a8 |
Signed-off-by: Miroslav Rezanina <mrezanin@redhat.com>
|
|
|
9ae3a8 |
---
|
|
|
9ae3a8 |
hw/i386/acpi-build.c | 8 +++++++-
|
|
|
9ae3a8 |
1 file changed, 7 insertions(+), 1 deletion(-)
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
diff --git a/hw/i386/acpi-build.c b/hw/i386/acpi-build.c
|
|
|
9ae3a8 |
index 8be1286..a3a4c3b 100644
|
|
|
9ae3a8 |
--- a/hw/i386/acpi-build.c
|
|
|
9ae3a8 |
+++ b/hw/i386/acpi-build.c
|
|
|
9ae3a8 |
@@ -924,10 +924,16 @@ build_mcfg_q35(GArray *table_data, GArray *linker, AcpiMcfgInfo *info)
|
|
|
9ae3a8 |
static void
|
|
|
9ae3a8 |
build_dsdt(GArray *table_data, GArray *linker, AcpiMiscInfo *misc)
|
|
|
9ae3a8 |
{
|
|
|
9ae3a8 |
- void *dsdt;
|
|
|
9ae3a8 |
+ AcpiTableHeader *dsdt;
|
|
|
9ae3a8 |
+
|
|
|
9ae3a8 |
assert(misc->dsdt_code && misc->dsdt_size);
|
|
|
9ae3a8 |
+
|
|
|
9ae3a8 |
dsdt = acpi_data_push(table_data, misc->dsdt_size);
|
|
|
9ae3a8 |
memcpy(dsdt, misc->dsdt_code, misc->dsdt_size);
|
|
|
9ae3a8 |
+
|
|
|
9ae3a8 |
+ memset(dsdt, 0, sizeof *dsdt);
|
|
|
9ae3a8 |
+ build_header(linker, table_data, dsdt, ACPI_DSDT_SIGNATURE,
|
|
|
9ae3a8 |
+ misc->dsdt_size, 1);
|
|
|
9ae3a8 |
}
|
|
|
9ae3a8 |
|
|
|
9ae3a8 |
/* Build final rsdt table */
|
|
|
9ae3a8 |
--
|
|
|
9ae3a8 |
1.8.3.1
|
|
|
9ae3a8 |
|