summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/soc/intel/skylake/acpi.c19
-rw-r--r--src/soc/intel/skylake/include/soc/acpi.h3
-rw-r--r--src/soc/intel/skylake/include/soc/nvs.h2
3 files changed, 17 insertions, 7 deletions
diff --git a/src/soc/intel/skylake/acpi.c b/src/soc/intel/skylake/acpi.c
index 1c3ec792ae..18cd2d94aa 100644
--- a/src/soc/intel/skylake/acpi.c
+++ b/src/soc/intel/skylake/acpi.c
@@ -22,6 +22,7 @@
#include <arch/acpi.h>
#include <arch/acpigen.h>
#include <arch/io.h>
+#include <arch/ioapic.h>
#include <arch/smp/mpspec.h>
#include <cbmem.h>
#include <chip.h>
@@ -167,7 +168,7 @@ static int get_cores_per_package(void)
return cores;
}
-void acpi_init_gnvs(global_nvs_t *gnvs)
+static void acpi_create_gnvs(global_nvs_t *gnvs)
{
const struct device *dev = dev_find_slot(0, PCH_DEVFN_LPC);
const struct soc_intel_skylake_config *config = dev->chip_info;
@@ -204,6 +205,18 @@ unsigned long acpi_fill_mcfg(unsigned long current)
return current;
}
+unsigned long acpi_fill_madt(unsigned long current)
+{
+ /* Local APICs */
+ current = acpi_create_madt_lapics(current);
+
+ /* IOAPIC */
+ current += acpi_create_madt_ioapic((acpi_madt_ioapic_t *) current,
+ 2, IO_APIC_ADDR, 0);
+
+ return acpi_madt_irq_overrides(current);
+}
+
void acpi_fill_in_fadt(acpi_fadt_t *fadt)
{
const uint16_t pmbase = ACPI_BASE_ADDRESS;
@@ -550,7 +563,6 @@ unsigned long southcluster_write_acpi_tables(device_t device,
ssdt2 = (acpi_header_t *)current;
memset(ssdt2, 0, sizeof(acpi_header_t));
- acpi_create_serialio_ssdt(ssdt2);
if (ssdt2->length) {
current += ssdt2->length;
acpi_add_table(rsdp, ssdt2);
@@ -580,6 +592,7 @@ void southcluster_inject_dsdt(device_t device)
if (gnvs) {
acpi_create_gnvs(gnvs);
+ acpi_mainboard_gnvs(gnvs);
acpi_save_gnvs((unsigned long)gnvs);
/* And tell SMI about it */
smm_setup_structures(gnvs, NULL, NULL);
@@ -591,6 +604,6 @@ void southcluster_inject_dsdt(device_t device)
}
}
-__attribute__((weak)) void acpi_create_serialio_ssdt(acpi_header_t *ssdt)
+__attribute__((weak)) void acpi_mainboard_gnvs(global_nvs_t *gnvs)
{
}
diff --git a/src/soc/intel/skylake/include/soc/acpi.h b/src/soc/intel/skylake/include/soc/acpi.h
index cd1a6639cc..7418fe0be5 100644
--- a/src/soc/intel/skylake/include/soc/acpi.h
+++ b/src/soc/intel/skylake/include/soc/acpi.h
@@ -30,10 +30,9 @@
#define PSS_LATENCY_TRANSITION 10
#define PSS_LATENCY_BUSMASTER 10
-void acpi_create_serialio_ssdt(acpi_header_t *ssdt);
void acpi_fill_in_fadt(acpi_fadt_t *fadt);
unsigned long acpi_madt_irq_overrides(unsigned long current);
-void acpi_init_gnvs(global_nvs_t *gnvs);
+void acpi_mainboard_gnvs(global_nvs_t *gnvs);
void southcluster_inject_dsdt(device_t device);
unsigned long southcluster_write_acpi_tables(device_t device,
unsigned long current, struct acpi_rsdp *rsdp);
diff --git a/src/soc/intel/skylake/include/soc/nvs.h b/src/soc/intel/skylake/include/soc/nvs.h
index c9fcb4e2df..20530f166d 100644
--- a/src/soc/intel/skylake/include/soc/nvs.h
+++ b/src/soc/intel/skylake/include/soc/nvs.h
@@ -62,8 +62,6 @@ typedef struct {
chromeos_acpi_t chromeos;
} __attribute__((packed)) global_nvs_t;
-void acpi_create_gnvs(global_nvs_t *gnvs);
-
#if ENV_SMM
/* Used in SMM to find the ACPI GNVS address */
global_nvs_t *smm_get_gnvs(void);