gm45: Convert to per-device ACPI

Change-Id: Ib04b03b2dc2ad3bfa886b43df9dd6518bbb46e3f
Signed-off-by: Vladimir Serbinenko <phcoder@gmail.com>
Reviewed-on: http://review.coreboot.org/6803
Tested-by: build bot (Jenkins)
Reviewed-by: Aaron Durbin <adurbin@google.com>
This commit is contained in:
Vladimir Serbinenko
2014-08-30 22:39:20 +02:00
parent 8ffc085e1a
commit 33769a5caa
10 changed files with 73 additions and 447 deletions

View File

@@ -27,6 +27,9 @@
#include <device/device.h>
#include <device/pci.h>
#include <device/pci_ids.h>
#include <cbmem.h>
#include <arch/acpigen.h>
#include <cpu/cpu.h>
#include "gm45.h"
unsigned long acpi_fill_mcfg(unsigned long current)
@@ -105,3 +108,29 @@ unsigned long acpi_fill_dmar(unsigned long current)
/* TODO: reserve GTT for 0.2.0 and 0.2.1? */
return current;
}
#define ALIGN_CURRENT current = (ALIGN(current, 16))
unsigned long northbridge_write_acpi_tables(unsigned long start, struct acpi_rsdp *rsdp)
{
unsigned long current;
#if CONFIG_IOMMU
acpi_dmar_t *dmar;
#endif
current = start;
#if CONFIG_IOMMU
printk(BIOS_DEBUG, "ACPI: * DMAR\n");
dmar = (acpi_dmar_t *) current;
acpi_create_dmar(dmar);
current += dmar->header.length;
ALIGN_CURRENT;
acpi_add_table(rsdp, dmar);
#endif
ALIGN_CURRENT;
printk(BIOS_DEBUG, "current = %lx\n", current);
return current;
}