hvmloader: provide hvmloader_acpi_build_tables()
authorBoris Ostrovsky <boris.ostrovsky@oracle.com>
Tue, 9 Aug 2016 15:27:39 +0000 (17:27 +0200)
committerJan Beulich <jbeulich@suse.com>
Tue, 9 Aug 2016 15:27:39 +0000 (17:27 +0200)
In preparation for moving out ACPI builder make all
BIOSes call hvmloader_acpi_build_tables() instead of
calling ACPI code directly.

No functional changes.

Signed-off-by: Boris Ostrovsky <boris.ostrovsky@oracle.com>
Acked-by: Jan Beulich <jbeulich@suse.com>
tools/firmware/hvmloader/ovmf.c
tools/firmware/hvmloader/rombios.c
tools/firmware/hvmloader/seabios.c
tools/firmware/hvmloader/util.c
tools/firmware/hvmloader/util.h

index db9fa7adb8e8e2d55eaf5197b5577e75970e678d..74fec5684097579579877dd6888c08ff121482ba 100644 (file)
@@ -125,7 +125,7 @@ static void ovmf_acpi_build_tables(void)
         .dsdt_15cpu_len = 0
     };
 
-    acpi_build_tables(&config, ACPI_PHYSICAL_ADDRESS);
+    hvmloader_acpi_build_tables(&config, ACPI_PHYSICAL_ADDRESS);
 }
 
 static void ovmf_create_smbios_tables(void)
index 1f15b94b8db86bfc014e131833ee02ba7b82fcc1..1f8fc2d7913a2c96cac807ffa6c2fd29768f7265 100644 (file)
@@ -180,7 +180,7 @@ static void rombios_acpi_build_tables(void)
         .dsdt_15cpu_len = dsdt_15cpu_len,
     };
 
-    acpi_build_tables(&config, ACPI_PHYSICAL_ADDRESS);
+    hvmloader_acpi_build_tables(&config, ACPI_PHYSICAL_ADDRESS);
 }
 
 static void rombios_create_mp_tables(void)
index c6b3d9fb6b02182051d2eab2181274d6976127ac..9f66a7947daa0fa7fd73d2a7b4b347dffc50e591 100644 (file)
@@ -100,7 +100,7 @@ static void seabios_acpi_build_tables(void)
         .dsdt_15cpu_len = 0,
     };
 
-    acpi_build_tables(&config, rsdp);
+    hvmloader_acpi_build_tables(&config, rsdp);
     add_table(rsdp);
 }
 
index a1a6de1e57f10a989e76292010056de92b3cc5e0..4accab6e20faac13f3befe40a585bb69bc5a6920 100644 (file)
@@ -21,6 +21,7 @@
 #include "config.h"
 #include "hypercall.h"
 #include "ctype.h"
+#include "acpi/acpi2_0.h"
 #include <stdint.h>
 #include <xen/xen.h>
 #include <xen/memory.h>
@@ -856,6 +857,12 @@ int hpet_exists(unsigned long hpet_base)
     return ((hpet_id >> 16) == 0x8086);
 }
 
+void hvmloader_acpi_build_tables(struct acpi_config *config,
+                                 unsigned int physical)
+{
+    acpi_build_tables(config, physical);
+}
+
 /*
  * Local variables:
  * mode: C
index 31268175d83a2e2fd270222f04f5b20807eb5897..b226df4e9542fafd7407245cdecedd9b9fdf15fa 100644 (file)
@@ -273,6 +273,10 @@ extern struct e820map memory_map;
 bool check_overlap(uint64_t start, uint64_t size,
                    uint64_t reserved_start, uint64_t reserved_size);
 
+struct acpi_config;
+void hvmloader_acpi_build_tables(struct acpi_config *config,
+                                 unsigned int physical);
+
 #endif /* __HVMLOADER_UTIL_H__ */
 
 /*