Vladimir Serbinenko (phcoder@gmail.com) just uploaded a new patch set to gerrit, which you can find at http://review.coreboot.org/6801
-gerrit
commit 18ee7fd56eb3a384ad618db74621a6b3ebf030d9 Author: Vladimir Serbinenko phcoder@gmail.com Date: Sat Aug 30 19:28:05 2014 +0200
NOTFORMERGE: Consolidate ACPI
Demo on how this revamp would affect x220.
Change-Id: I76fb2fbcb9ca0654f2e5fd5d90bd62392165777c Signed-off-by: Vladimir Serbinenko phcoder@gmail.com --- src/arch/x86/boot/acpi.c | 112 +++++++++++++-- src/arch/x86/include/arch/acpi.h | 7 +- src/cpu/amd/model_10xxx/fidvid.c | 2 +- src/include/device/device.h | 6 + src/mainboard/advansus/a785e-i/acpi_tables.c | 2 +- src/mainboard/amd/bimini_fam10/acpi_tables.c | 2 +- src/mainboard/amd/dbm690t/acpi_tables.c | 2 +- src/mainboard/amd/dinar/acpi_tables.c | 2 +- src/mainboard/amd/inagua/acpi_tables.c | 2 +- src/mainboard/amd/mahogany/acpi_tables.c | 2 +- src/mainboard/amd/mahogany_fam10/acpi_tables.c | 2 +- src/mainboard/amd/olivehill/acpi_tables.c | 2 +- src/mainboard/amd/parmer/acpi_tables.c | 2 +- src/mainboard/amd/persimmon/acpi_tables.c | 2 +- src/mainboard/amd/pistachio/acpi_tables.c | 2 +- src/mainboard/amd/serengeti_cheetah/acpi_tables.c | 2 +- .../amd/serengeti_cheetah_fam10/acpi_tables.c | 2 +- src/mainboard/amd/south_station/acpi_tables.c | 2 +- src/mainboard/amd/thatcher/acpi_tables.c | 2 +- src/mainboard/amd/tilapia_fam10/acpi_tables.c | 2 +- src/mainboard/amd/torpedo/acpi_tables.c | 2 +- src/mainboard/amd/union_station/acpi_tables.c | 2 +- src/mainboard/aopen/dxplplusu/acpi_tables.c | 2 +- src/mainboard/apple/macbook21/acpi_tables.c | 2 +- src/mainboard/asrock/939a785gmh/acpi_tables.c | 2 +- src/mainboard/asrock/e350m1/acpi_tables.c | 2 +- src/mainboard/asrock/imb-a180/acpi_tables.c | 2 +- src/mainboard/asus/a8n_e/acpi_tables.c | 2 +- src/mainboard/asus/a8v-e_deluxe/acpi_tables.c | 2 +- src/mainboard/asus/a8v-e_se/acpi_tables.c | 2 +- src/mainboard/asus/f2a85-m/acpi_tables.c | 2 +- src/mainboard/asus/k8v-x/acpi_tables.c | 2 +- src/mainboard/asus/m2v-mx_se/acpi_tables.c | 2 +- src/mainboard/asus/m2v/acpi_tables.c | 2 +- src/mainboard/asus/m4a78-em/acpi_tables.c | 2 +- src/mainboard/asus/m4a785-m/acpi_tables.c | 2 +- src/mainboard/asus/m5a88-v/acpi_tables.c | 2 +- src/mainboard/avalue/eax-785e/acpi_tables.c | 2 +- src/mainboard/emulation/qemu-i440fx/acpi_tables.c | 2 +- src/mainboard/emulation/qemu-q35/acpi_tables.c | 2 +- src/mainboard/getac/p470/acpi_tables.c | 2 +- src/mainboard/gigabyte/m57sli/acpi_tables.c | 2 +- src/mainboard/gigabyte/ma785gm/acpi_tables.c | 2 +- src/mainboard/gigabyte/ma785gmt/acpi_tables.c | 2 +- src/mainboard/gigabyte/ma78gm/acpi_tables.c | 2 +- src/mainboard/gizmosphere/gizmo/acpi_tables.c | 2 +- src/mainboard/google/bolt/acpi_tables.c | 2 +- src/mainboard/google/butterfly/acpi_tables.c | 2 +- src/mainboard/google/falco/acpi_tables.c | 2 +- src/mainboard/google/link/acpi_tables.c | 2 +- src/mainboard/google/panther/acpi_tables.c | 2 +- src/mainboard/google/parrot/acpi_tables.c | 2 +- src/mainboard/google/peppy/acpi_tables.c | 2 +- src/mainboard/google/rambi/acpi_tables.c | 2 +- src/mainboard/google/samus/acpi_tables.c | 2 +- src/mainboard/google/slippy/acpi_tables.c | 2 +- src/mainboard/google/stout/acpi_tables.c | 2 +- src/mainboard/hp/dl145_g1/acpi_tables.c | 2 +- src/mainboard/hp/pavilion_m6_1035dx/acpi_tables.c | 2 +- src/mainboard/ibase/mb899/acpi_tables.c | 2 +- src/mainboard/iei/kino-780am2-fam10/acpi_tables.c | 2 +- src/mainboard/intel/baskingridge/acpi_tables.c | 2 +- src/mainboard/intel/bayleybay_fsp/acpi_tables.c | 2 +- src/mainboard/intel/cougar_canyon2/acpi_tables.c | 2 +- src/mainboard/intel/d945gclf/acpi_tables.c | 2 +- src/mainboard/intel/eagleheights/acpi_tables.c | 2 +- src/mainboard/intel/emeraldlake2/acpi_tables.c | 2 +- src/mainboard/intel/minnowmax/acpi_tables.c | 2 +- src/mainboard/intel/mohonpeak/acpi_tables.c | 2 +- src/mainboard/intel/wtm2/acpi_tables.c | 2 +- src/mainboard/intel/xe7501devkit/acpi_tables.c | 2 +- src/mainboard/iwave/iWRainbowG6/acpi_tables.c | 2 +- src/mainboard/iwill/dk8_htx/acpi_tables.c | 2 +- src/mainboard/jetway/nf81-t56n-lf/acpi_tables.c | 2 +- src/mainboard/jetway/pa78vm5/acpi_tables.c | 2 +- src/mainboard/kontron/986lcd-m/acpi_tables.c | 2 +- src/mainboard/kontron/kt690/acpi_tables.c | 2 +- src/mainboard/kontron/ktqm77/acpi_tables.c | 2 +- src/mainboard/lenovo/t520/acpi_tables.c | 2 +- src/mainboard/lenovo/t530/acpi_tables.c | 2 +- src/mainboard/lenovo/t60/acpi_tables.c | 2 +- src/mainboard/lenovo/x200/acpi_tables.c | 2 +- src/mainboard/lenovo/x201/acpi_tables.c | 2 +- src/mainboard/lenovo/x220/acpi_tables.c | 154 +-------------------- src/mainboard/lenovo/x230/acpi_tables.c | 28 +--- src/mainboard/lenovo/x60/acpi_tables.c | 2 +- src/mainboard/lippert/frontrunner-af/acpi_tables.c | 2 +- src/mainboard/lippert/toucan-af/acpi_tables.c | 2 +- src/mainboard/msi/ms7135/acpi_tables.c | 2 +- src/mainboard/msi/ms9652_fam10/acpi_tables.c | 2 +- src/mainboard/packardbell/ms2290/acpi_tables.c | 2 +- src/mainboard/roda/rk886ex/acpi_tables.c | 2 +- src/mainboard/roda/rk9/acpi_tables.c | 2 +- src/mainboard/samsung/lumpy/acpi_tables.c | 2 +- src/mainboard/samsung/stumpy/acpi_tables.c | 2 +- src/mainboard/siemens/sitemp_g1p1/acpi_tables.c | 2 +- src/mainboard/supermicro/h8qgi/acpi_tables.c | 2 +- src/mainboard/supermicro/h8scm/acpi_tables.c | 2 +- src/mainboard/supermicro/h8scm_fam10/acpi_tables.c | 2 +- src/mainboard/technexion/tim5690/acpi_tables.c | 2 +- src/mainboard/technexion/tim8690/acpi_tables.c | 2 +- src/mainboard/tyan/s2891/acpi_tables.c | 2 +- src/mainboard/tyan/s2892/acpi_tables.c | 2 +- src/mainboard/tyan/s2895/acpi_tables.c | 2 +- src/mainboard/tyan/s8226/acpi_tables.c | 2 +- src/mainboard/via/epia-m/acpi_tables.c | 2 +- src/mainboard/via/epia-m700/acpi_tables.c | 2 +- src/mainboard/via/epia-n/acpi_tables.c | 2 +- src/mainboard/via/vt8454c/acpi_tables.c | 2 +- src/mainboard/winent/mb6047/acpi_tables.c | 2 +- src/northbridge/intel/sandybridge/acpi.c | 68 +++++++++ src/northbridge/intel/sandybridge/northbridge.c | 3 + src/northbridge/intel/sandybridge/sandybridge.h | 4 + src/soc/intel/baytrail/acpi/globalnvs.asl | 2 +- src/soc/intel/fsp_baytrail/acpi/globalnvs.asl | 2 +- src/southbridge/intel/bd82x6x/acpi/globalnvs.asl | 4 +- src/southbridge/intel/bd82x6x/nvs.h | 1 + .../intel/fsp_bd82x6x/acpi/globalnvs.asl | 2 +- .../intel/fsp_rangeley/acpi/globalnvs.asl | 2 +- src/southbridge/intel/i82371eb/acpi_tables.c | 2 +- src/southbridge/intel/i82801gx/acpi/globalnvs.asl | 2 +- src/southbridge/intel/i82801ix/acpi/globalnvs.asl | 2 +- src/southbridge/intel/lynxpoint/acpi/globalnvs.asl | 2 +- src/southbridge/intel/sch/acpi/globalnvs.asl | 2 +- 124 files changed, 306 insertions(+), 309 deletions(-)
diff --git a/src/arch/x86/boot/acpi.c b/src/arch/x86/boot/acpi.c index d76882a..da9d958 100644 --- a/src/arch/x86/boot/acpi.c +++ b/src/arch/x86/boot/acpi.c @@ -18,7 +18,7 @@ /* * Each system port implementing ACPI has to provide two functions: * - * write_acpi_tables() + * mainboard_write_acpi_tables() * acpi_dump_apics() * * See Kontron 986LCD-M port for a good example of an ACPI implementation @@ -247,19 +247,11 @@ void acpi_create_mcfg(acpi_mcfg_t *mcfg) header->checksum = acpi_checksum((void *)mcfg, header->length); }
-/* - * This can be overridden by platform ACPI setup code, if it calls - * acpi_create_ssdt_generator(). - */ -unsigned long __attribute__((weak)) acpi_fill_ssdt_generator( - unsigned long current, const char *oem_table_id) -{ - return current; -}
void acpi_create_ssdt_generator(acpi_header_t *ssdt, const char *oem_table_id) { unsigned long current = (unsigned long)ssdt + sizeof(acpi_header_t); + device_t dev;
memset((void *)ssdt, 0, sizeof(acpi_header_t));
@@ -273,7 +265,10 @@ void acpi_create_ssdt_generator(acpi_header_t *ssdt, const char *oem_table_id) ssdt->length = sizeof(acpi_header_t);
acpigen_set_current((char *) current); - current = acpi_fill_ssdt_generator(current, oem_table_id); + for (dev = all_devices; dev; dev = dev->next) + if (dev->ops && dev->ops->acpi_fill_ssdt_generator) { + current = dev->ops->acpi_fill_ssdt_generator(current, oem_table_id); + }
/* (Re)calculate length and checksum. */ ssdt->length = current - (unsigned long)ssdt; @@ -693,6 +688,101 @@ static acpi_rsdp_t *valid_rsdp(acpi_rsdp_t *rsdp) return rsdp; }
+extern const unsigned char AmlCode[]; + +#define ALIGN_CURRENT current = (ALIGN(current, 16)) +unsigned long write_acpi_tables(unsigned long start) +{ + unsigned long current; + acpi_rsdp_t *rsdp; + acpi_rsdt_t *rsdt; + acpi_xsdt_t *xsdt; + acpi_fadt_t *fadt; + acpi_facs_t *facs; +#if CONFIG_HAVE_ACPI_SLIC + acpi_header_t *slic; +#endif + acpi_header_t *ssdt; + acpi_header_t *dsdt; + device_t dev; + + current = start; + + /* Align ACPI tables to 16byte */ + ALIGN_CURRENT; + + printk(BIOS_INFO, "ACPI: Writing ACPI tables at %lx.\n", start); + + /* We need at least an RSDP and an RSDT Table */ + rsdp = (acpi_rsdp_t *) current; + current += sizeof(acpi_rsdp_t); + ALIGN_CURRENT; + rsdt = (acpi_rsdt_t *) current; + current += sizeof(acpi_rsdt_t); + ALIGN_CURRENT; + xsdt = (acpi_xsdt_t *) current; + current += sizeof(acpi_xsdt_t); + ALIGN_CURRENT; + + /* clear all table memory */ + memset((void *) start, 0, current - start); + + acpi_write_rsdp(rsdp, rsdt, xsdt); + acpi_write_rsdt(rsdt); + acpi_write_xsdt(xsdt); + + printk(BIOS_DEBUG, "ACPI: * FACS\n"); + facs = (acpi_facs_t *) current; + current += sizeof(acpi_facs_t); + ALIGN_CURRENT; + acpi_create_facs(facs); + + printk(BIOS_DEBUG, "ACPI: * DSDT\n"); + dsdt = (acpi_header_t *) current; + memcpy(dsdt, &AmlCode, sizeof(acpi_header_t)); + current += dsdt->length; + memcpy(dsdt, &AmlCode, dsdt->length); + + ALIGN_CURRENT; + + printk(BIOS_DEBUG, "ACPI: * FADT\n"); + fadt = (acpi_fadt_t *) current; + current += sizeof(acpi_fadt_t); + ALIGN_CURRENT; + + acpi_create_fadt(fadt, facs, dsdt); + acpi_add_table(rsdp, fadt); + +#if CONFIG_HAVE_ACPI_SLIC + printk(BIOS_DEBUG, "ACPI: * SLIC\n"); + slic = (acpi_header_t *)current; + current += acpi_create_slic(current); + ALIGN_CURRENT; + acpi_add_table(rsdp, slic); +#endif + + printk(BIOS_DEBUG, "ACPI: * SSDT\n"); + ssdt = (acpi_header_t *)current; + acpi_create_ssdt_generator(ssdt, ACPI_TABLE_CREATOR); + current += ssdt->length; + acpi_add_table(rsdp, ssdt); + ALIGN_CURRENT; + + printk(BIOS_DEBUG, "current = %lx\n", current); + + for (dev = all_devices; dev; dev = dev->next) { + if (dev->ops && dev->ops->write_acpi_tables) { + current = dev->ops->write_acpi_tables(current, rsdp); + ALIGN_CURRENT; + } + } + + printk(BIOS_INFO, "ACPI: done.\n"); + return current; +} + + + static acpi_rsdp_t *rsdp;
void *acpi_get_wakeup_rsdp(void) diff --git a/src/arch/x86/include/arch/acpi.h b/src/arch/x86/include/arch/acpi.h index 9039a90..fda9fe0 100644 --- a/src/arch/x86/include/arch/acpi.h +++ b/src/arch/x86/include/arch/acpi.h @@ -484,8 +484,11 @@ typedef struct acpi_tstate { u32 status; } __attribute__ ((packed)) acpi_tstate_t;
-/* These are implemented by the target port or north/southbridge. */ unsigned long write_acpi_tables(unsigned long addr); + + +/* These are implemented by the target port or north/southbridge. */ +unsigned long mainboard_write_acpi_tables(unsigned long addr, acpi_rsdp_t *rsdp); unsigned long acpi_fill_madt(unsigned long current); unsigned long acpi_fill_mcfg(unsigned long current); unsigned long acpi_fill_srat(unsigned long current); @@ -580,7 +583,7 @@ void generate_cpu_entries(void);
#else // CONFIG_GENERATE_ACPI_TABLES
-#define write_acpi_tables(start) (start) +#define mainboard_write_acpi_tables(start) (start)
#endif /* CONFIG_GENERATE_ACPI_TABLES */
diff --git a/src/cpu/amd/model_10xxx/fidvid.c b/src/cpu/amd/model_10xxx/fidvid.c index 4297c90..2803e84 100644 --- a/src/cpu/amd/model_10xxx/fidvid.c +++ b/src/cpu/amd/model_10xxx/fidvid.c @@ -84,7 +84,7 @@ Fam10 Bios and Kernel Development Guide #31116, rev 3.48, April 22, 2010 as BKDG apparently requires. http://www.coreboot.org/ACPI#CPU_Power_Management At least for Tilapia board: - src/mainboard/<vendor>/<model>/acpi_tables.c write_acpi_tables(...) calls + src/mainboard/<vendor>/<model>/acpi_tables.c mainboard_write_acpi_tables(...) calls acpi_add_ssdt_pstates(...) in /src/northbridge/amd/amdfam10/amdfam10_acpi.c which apparently copies them from static info in diff --git a/src/include/device/device.h b/src/include/device/device.h index 19b5ea0..fabb627 100644 --- a/src/include/device/device.h +++ b/src/include/device/device.h @@ -40,6 +40,7 @@ struct chip_operations { struct bus;
struct smbios_type11; +struct acpi_rsdp;
struct device_operations { void (*read_resources)(device_t dev); @@ -56,6 +57,11 @@ struct device_operations { int (*get_smbios_data)(device_t dev, int *handle, unsigned long *current); void (*get_smbios_strings)(device_t dev, struct smbios_type11 *t); #endif +#if CONFIG_GENERATE_ACPI_TABLES + unsigned long (*write_acpi_tables)(unsigned long start, struct acpi_rsdp *rsdp); + unsigned long (*acpi_fill_ssdt_generator)(unsigned long current, + const char *oem_table_id); +#endif const struct pci_operations *ops_pci; const struct smbus_bus_operations *ops_smbus_bus; const struct pci_bus_operations * (*ops_pci_bus)(device_t dev); diff --git a/src/mainboard/advansus/a785e-i/acpi_tables.c b/src/mainboard/advansus/a785e-i/acpi_tables.c index 7853bd1..1b48334 100644 --- a/src/mainboard/advansus/a785e-i/acpi_tables.c +++ b/src/mainboard/advansus/a785e-i/acpi_tables.c @@ -70,7 +70,7 @@ unsigned long acpi_fill_madt(unsigned long current) return current; }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/amd/bimini_fam10/acpi_tables.c b/src/mainboard/amd/bimini_fam10/acpi_tables.c index 2ec11bb..7da5735 100644 --- a/src/mainboard/amd/bimini_fam10/acpi_tables.c +++ b/src/mainboard/amd/bimini_fam10/acpi_tables.c @@ -70,7 +70,7 @@ unsigned long acpi_fill_madt(unsigned long current) return current; }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/amd/dbm690t/acpi_tables.c b/src/mainboard/amd/dbm690t/acpi_tables.c index 87ff5ea..5780409 100644 --- a/src/mainboard/amd/dbm690t/acpi_tables.c +++ b/src/mainboard/amd/dbm690t/acpi_tables.c @@ -79,7 +79,7 @@ unsigned long acpi_fill_ssdt_generator(unsigned long current, const char *oem_ta return (unsigned long) (acpigen_get_current()); }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/amd/dinar/acpi_tables.c b/src/mainboard/amd/dinar/acpi_tables.c index 5ec2d74..0e4daa0 100644 --- a/src/mainboard/amd/dinar/acpi_tables.c +++ b/src/mainboard/amd/dinar/acpi_tables.c @@ -156,7 +156,7 @@ unsigned long acpi_fill_ssdt_generator(unsigned long current, const char *oem_ta return (unsigned long) (acpigen_get_current()); }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/amd/inagua/acpi_tables.c b/src/mainboard/amd/inagua/acpi_tables.c index 588345e..f34bec0 100644 --- a/src/mainboard/amd/inagua/acpi_tables.c +++ b/src/mainboard/amd/inagua/acpi_tables.c @@ -116,7 +116,7 @@ unsigned long acpi_fill_srat(unsigned long current) return current; }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/amd/mahogany/acpi_tables.c b/src/mainboard/amd/mahogany/acpi_tables.c index ef2690a..49938c3 100644 --- a/src/mainboard/amd/mahogany/acpi_tables.c +++ b/src/mainboard/amd/mahogany/acpi_tables.c @@ -85,7 +85,7 @@ unsigned long acpi_fill_ssdt_generator(unsigned long current, const char *oem_ta return (unsigned long) (acpigen_get_current()); }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/amd/mahogany_fam10/acpi_tables.c b/src/mainboard/amd/mahogany_fam10/acpi_tables.c index 01172ad..07b6e52 100644 --- a/src/mainboard/amd/mahogany_fam10/acpi_tables.c +++ b/src/mainboard/amd/mahogany_fam10/acpi_tables.c @@ -91,7 +91,7 @@ unsigned long acpi_fill_madt(unsigned long current) return current; }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/amd/olivehill/acpi_tables.c b/src/mainboard/amd/olivehill/acpi_tables.c index a02b92c..c6c9c89 100644 --- a/src/mainboard/amd/olivehill/acpi_tables.c +++ b/src/mainboard/amd/olivehill/acpi_tables.c @@ -120,7 +120,7 @@ unsigned long acpi_fill_ssdt_generator(unsigned long current, const char *oem_ta return (unsigned long) (acpigen_get_current()); }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/amd/parmer/acpi_tables.c b/src/mainboard/amd/parmer/acpi_tables.c index e24ecc8..229b29e 100644 --- a/src/mainboard/amd/parmer/acpi_tables.c +++ b/src/mainboard/amd/parmer/acpi_tables.c @@ -116,7 +116,7 @@ unsigned long acpi_fill_ssdt_generator(unsigned long current, const char *oem_ta return (unsigned long) (acpigen_get_current()); }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/amd/persimmon/acpi_tables.c b/src/mainboard/amd/persimmon/acpi_tables.c index 588345e..f34bec0 100644 --- a/src/mainboard/amd/persimmon/acpi_tables.c +++ b/src/mainboard/amd/persimmon/acpi_tables.c @@ -116,7 +116,7 @@ unsigned long acpi_fill_srat(unsigned long current) return current; }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/amd/pistachio/acpi_tables.c b/src/mainboard/amd/pistachio/acpi_tables.c index 5ef0da5..87a2cda 100644 --- a/src/mainboard/amd/pistachio/acpi_tables.c +++ b/src/mainboard/amd/pistachio/acpi_tables.c @@ -79,7 +79,7 @@ unsigned long acpi_fill_ssdt_generator(unsigned long current, const char *oem_ta return (unsigned long) (acpigen_get_current()); }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/amd/serengeti_cheetah/acpi_tables.c b/src/mainboard/amd/serengeti_cheetah/acpi_tables.c index a429c1f..f39d620 100644 --- a/src/mainboard/amd/serengeti_cheetah/acpi_tables.c +++ b/src/mainboard/amd/serengeti_cheetah/acpi_tables.c @@ -135,7 +135,7 @@ unsigned long acpi_fill_ssdt_generator(unsigned long current, const char *oem_ta return (unsigned long) (acpigen_get_current()); }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/amd/serengeti_cheetah_fam10/acpi_tables.c b/src/mainboard/amd/serengeti_cheetah_fam10/acpi_tables.c index f624424..794fde7 100644 --- a/src/mainboard/amd/serengeti_cheetah_fam10/acpi_tables.c +++ b/src/mainboard/amd/serengeti_cheetah_fam10/acpi_tables.c @@ -141,7 +141,7 @@ unsigned long acpi_fill_madt(unsigned long current) return current; }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/amd/south_station/acpi_tables.c b/src/mainboard/amd/south_station/acpi_tables.c index 588345e..f34bec0 100644 --- a/src/mainboard/amd/south_station/acpi_tables.c +++ b/src/mainboard/amd/south_station/acpi_tables.c @@ -116,7 +116,7 @@ unsigned long acpi_fill_srat(unsigned long current) return current; }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/amd/thatcher/acpi_tables.c b/src/mainboard/amd/thatcher/acpi_tables.c index e24ecc8..229b29e 100644 --- a/src/mainboard/amd/thatcher/acpi_tables.c +++ b/src/mainboard/amd/thatcher/acpi_tables.c @@ -116,7 +116,7 @@ unsigned long acpi_fill_ssdt_generator(unsigned long current, const char *oem_ta return (unsigned long) (acpigen_get_current()); }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/amd/tilapia_fam10/acpi_tables.c b/src/mainboard/amd/tilapia_fam10/acpi_tables.c index 898a955..34670c2 100644 --- a/src/mainboard/amd/tilapia_fam10/acpi_tables.c +++ b/src/mainboard/amd/tilapia_fam10/acpi_tables.c @@ -70,7 +70,7 @@ unsigned long acpi_fill_madt(unsigned long current) return current; }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/amd/torpedo/acpi_tables.c b/src/mainboard/amd/torpedo/acpi_tables.c index b916bce..dc4b4bb 100644 --- a/src/mainboard/amd/torpedo/acpi_tables.c +++ b/src/mainboard/amd/torpedo/acpi_tables.c @@ -104,7 +104,7 @@ unsigned long acpi_fill_srat(unsigned long current) return current; }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/amd/union_station/acpi_tables.c b/src/mainboard/amd/union_station/acpi_tables.c index 588345e..f34bec0 100644 --- a/src/mainboard/amd/union_station/acpi_tables.c +++ b/src/mainboard/amd/union_station/acpi_tables.c @@ -116,7 +116,7 @@ unsigned long acpi_fill_srat(unsigned long current) return current; }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/aopen/dxplplusu/acpi_tables.c b/src/mainboard/aopen/dxplplusu/acpi_tables.c index 2985e86..ba34159 100644 --- a/src/mainboard/aopen/dxplplusu/acpi_tables.c +++ b/src/mainboard/aopen/dxplplusu/acpi_tables.c @@ -93,7 +93,7 @@ unsigned long acpi_fill_madt(unsigned long current) }
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/apple/macbook21/acpi_tables.c b/src/mainboard/apple/macbook21/acpi_tables.c index f6ed4ae..4ff27d1 100644 --- a/src/mainboard/apple/macbook21/acpi_tables.c +++ b/src/mainboard/apple/macbook21/acpi_tables.c @@ -104,7 +104,7 @@ unsigned long acpi_fill_srat(unsigned long current) void smm_setup_structures(void *gnvs, void *tcg, void *smi1);
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; int i; diff --git a/src/mainboard/asrock/939a785gmh/acpi_tables.c b/src/mainboard/asrock/939a785gmh/acpi_tables.c index 52b45f7..439bf88 100644 --- a/src/mainboard/asrock/939a785gmh/acpi_tables.c +++ b/src/mainboard/asrock/939a785gmh/acpi_tables.c @@ -85,7 +85,7 @@ unsigned long acpi_fill_ssdt_generator(unsigned long current, const char *oem_ta return (unsigned long) (acpigen_get_current()); }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/asrock/e350m1/acpi_tables.c b/src/mainboard/asrock/e350m1/acpi_tables.c index 65cb796..f99abcd 100644 --- a/src/mainboard/asrock/e350m1/acpi_tables.c +++ b/src/mainboard/asrock/e350m1/acpi_tables.c @@ -115,7 +115,7 @@ unsigned long acpi_fill_srat(unsigned long current) return current; }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/asrock/imb-a180/acpi_tables.c b/src/mainboard/asrock/imb-a180/acpi_tables.c index 2c480c3..08c53f4 100644 --- a/src/mainboard/asrock/imb-a180/acpi_tables.c +++ b/src/mainboard/asrock/imb-a180/acpi_tables.c @@ -120,7 +120,7 @@ unsigned long acpi_fill_ssdt_generator(unsigned long current, const char *oem_ta return (unsigned long) (acpigen_get_current()); }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/asus/a8n_e/acpi_tables.c b/src/mainboard/asus/a8n_e/acpi_tables.c index ee8e81f..335a1f2 100644 --- a/src/mainboard/asus/a8n_e/acpi_tables.c +++ b/src/mainboard/asus/a8n_e/acpi_tables.c @@ -93,7 +93,7 @@ unsigned long acpi_fill_ssdt_generator(unsigned long current, const char *oem_ta return (unsigned long) (acpigen_get_current()); }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/asus/a8v-e_deluxe/acpi_tables.c b/src/mainboard/asus/a8v-e_deluxe/acpi_tables.c index 30914e4..5fe9eaa 100644 --- a/src/mainboard/asus/a8v-e_deluxe/acpi_tables.c +++ b/src/mainboard/asus/a8v-e_deluxe/acpi_tables.c @@ -81,7 +81,7 @@ unsigned long acpi_fill_madt(unsigned long current) return current; }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/asus/a8v-e_se/acpi_tables.c b/src/mainboard/asus/a8v-e_se/acpi_tables.c index f5f081a..149a86c 100644 --- a/src/mainboard/asus/a8v-e_se/acpi_tables.c +++ b/src/mainboard/asus/a8v-e_se/acpi_tables.c @@ -91,7 +91,7 @@ unsigned long acpi_fill_ssdt_generator(unsigned long current, const char *oem_ta return (unsigned long) (acpigen_get_current()); }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/asus/f2a85-m/acpi_tables.c b/src/mainboard/asus/f2a85-m/acpi_tables.c index 428721e..b6bdd82 100644 --- a/src/mainboard/asus/f2a85-m/acpi_tables.c +++ b/src/mainboard/asus/f2a85-m/acpi_tables.c @@ -114,7 +114,7 @@ unsigned long acpi_fill_ssdt_generator(unsigned long current, const char *oem_ta return (unsigned long) (acpigen_get_current()); }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/asus/k8v-x/acpi_tables.c b/src/mainboard/asus/k8v-x/acpi_tables.c index 065db1a..0529981 100644 --- a/src/mainboard/asus/k8v-x/acpi_tables.c +++ b/src/mainboard/asus/k8v-x/acpi_tables.c @@ -91,7 +91,7 @@ unsigned long acpi_fill_ssdt_generator(unsigned long current, const char *oem_ta return (unsigned long) (acpigen_get_current()); }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/asus/m2v-mx_se/acpi_tables.c b/src/mainboard/asus/m2v-mx_se/acpi_tables.c index 91a5da1..a6b95e2 100644 --- a/src/mainboard/asus/m2v-mx_se/acpi_tables.c +++ b/src/mainboard/asus/m2v-mx_se/acpi_tables.c @@ -92,7 +92,7 @@ unsigned long acpi_fill_ssdt_generator(unsigned long current, const char *oem_ta return (unsigned long) (acpigen_get_current()); }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/asus/m2v/acpi_tables.c b/src/mainboard/asus/m2v/acpi_tables.c index cc1070e..c8c9f94 100644 --- a/src/mainboard/asus/m2v/acpi_tables.c +++ b/src/mainboard/asus/m2v/acpi_tables.c @@ -93,7 +93,7 @@ unsigned long acpi_fill_ssdt_generator(unsigned long current, const char *oem_ta return (unsigned long) (acpigen_get_current()); }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/asus/m4a78-em/acpi_tables.c b/src/mainboard/asus/m4a78-em/acpi_tables.c index 2398c01..cfc2743 100644 --- a/src/mainboard/asus/m4a78-em/acpi_tables.c +++ b/src/mainboard/asus/m4a78-em/acpi_tables.c @@ -69,7 +69,7 @@ unsigned long acpi_fill_madt(unsigned long current) return current; }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/asus/m4a785-m/acpi_tables.c b/src/mainboard/asus/m4a785-m/acpi_tables.c index a8b6365..4b61eb7 100644 --- a/src/mainboard/asus/m4a785-m/acpi_tables.c +++ b/src/mainboard/asus/m4a785-m/acpi_tables.c @@ -93,7 +93,7 @@ unsigned long acpi_fill_madt(unsigned long current) return current; }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/asus/m5a88-v/acpi_tables.c b/src/mainboard/asus/m5a88-v/acpi_tables.c index 7853bd1..1b48334 100644 --- a/src/mainboard/asus/m5a88-v/acpi_tables.c +++ b/src/mainboard/asus/m5a88-v/acpi_tables.c @@ -70,7 +70,7 @@ unsigned long acpi_fill_madt(unsigned long current) return current; }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/avalue/eax-785e/acpi_tables.c b/src/mainboard/avalue/eax-785e/acpi_tables.c index 7853bd1..1b48334 100644 --- a/src/mainboard/avalue/eax-785e/acpi_tables.c +++ b/src/mainboard/avalue/eax-785e/acpi_tables.c @@ -70,7 +70,7 @@ unsigned long acpi_fill_madt(unsigned long current) return current; }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/emulation/qemu-i440fx/acpi_tables.c b/src/mainboard/emulation/qemu-i440fx/acpi_tables.c index 8be187a..450f935 100644 --- a/src/mainboard/emulation/qemu-i440fx/acpi_tables.c +++ b/src/mainboard/emulation/qemu-i440fx/acpi_tables.c @@ -73,7 +73,7 @@ unsigned long acpi_fill_srat(unsigned long current) }
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/emulation/qemu-q35/acpi_tables.c b/src/mainboard/emulation/qemu-q35/acpi_tables.c index 4e79b2c..d4cf44e 100644 --- a/src/mainboard/emulation/qemu-q35/acpi_tables.c +++ b/src/mainboard/emulation/qemu-q35/acpi_tables.c @@ -223,7 +223,7 @@ unsigned long acpi_fill_srat(unsigned long current) }
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/getac/p470/acpi_tables.c b/src/mainboard/getac/p470/acpi_tables.c index 9a10087..f84b802 100644 --- a/src/mainboard/getac/p470/acpi_tables.c +++ b/src/mainboard/getac/p470/acpi_tables.c @@ -144,7 +144,7 @@ unsigned long acpi_fill_srat(unsigned long current) void smm_setup_structures(void *gnvs, void *tcg, void *smi1);
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; int i; diff --git a/src/mainboard/gigabyte/m57sli/acpi_tables.c b/src/mainboard/gigabyte/m57sli/acpi_tables.c index 2e2e590..78dbc7c 100644 --- a/src/mainboard/gigabyte/m57sli/acpi_tables.c +++ b/src/mainboard/gigabyte/m57sli/acpi_tables.c @@ -100,7 +100,7 @@ unsigned long acpi_fill_ssdt_generator(unsigned long current, const char *oem_ta return (unsigned long) (acpigen_get_current()); }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/gigabyte/ma785gm/acpi_tables.c b/src/mainboard/gigabyte/ma785gm/acpi_tables.c index 7a5df88..5422681 100644 --- a/src/mainboard/gigabyte/ma785gm/acpi_tables.c +++ b/src/mainboard/gigabyte/ma785gm/acpi_tables.c @@ -70,7 +70,7 @@ unsigned long acpi_fill_madt(unsigned long current) return current; }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/gigabyte/ma785gmt/acpi_tables.c b/src/mainboard/gigabyte/ma785gmt/acpi_tables.c index 07b174c..5ad33c4 100644 --- a/src/mainboard/gigabyte/ma785gmt/acpi_tables.c +++ b/src/mainboard/gigabyte/ma785gmt/acpi_tables.c @@ -68,7 +68,7 @@ unsigned long acpi_fill_madt(unsigned long current) return current; }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/gigabyte/ma78gm/acpi_tables.c b/src/mainboard/gigabyte/ma78gm/acpi_tables.c index 07b174c..5ad33c4 100644 --- a/src/mainboard/gigabyte/ma78gm/acpi_tables.c +++ b/src/mainboard/gigabyte/ma78gm/acpi_tables.c @@ -68,7 +68,7 @@ unsigned long acpi_fill_madt(unsigned long current) return current; }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/gizmosphere/gizmo/acpi_tables.c b/src/mainboard/gizmosphere/gizmo/acpi_tables.c index a9174c0..3b2d9f7 100755 --- a/src/mainboard/gizmosphere/gizmo/acpi_tables.c +++ b/src/mainboard/gizmosphere/gizmo/acpi_tables.c @@ -117,7 +117,7 @@ unsigned long acpi_fill_srat(unsigned long current) return current; }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/google/bolt/acpi_tables.c b/src/mainboard/google/bolt/acpi_tables.c index 7f596b7..c204def 100644 --- a/src/mainboard/google/bolt/acpi_tables.c +++ b/src/mainboard/google/bolt/acpi_tables.c @@ -135,7 +135,7 @@ unsigned long acpi_fill_srat(unsigned long current) }
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; int i; diff --git a/src/mainboard/google/butterfly/acpi_tables.c b/src/mainboard/google/butterfly/acpi_tables.c index 25d8fa1..380e71c 100644 --- a/src/mainboard/google/butterfly/acpi_tables.c +++ b/src/mainboard/google/butterfly/acpi_tables.c @@ -128,7 +128,7 @@ unsigned long acpi_fill_srat(unsigned long current) }
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; int i; diff --git a/src/mainboard/google/falco/acpi_tables.c b/src/mainboard/google/falco/acpi_tables.c index d01e785..e6274d7 100644 --- a/src/mainboard/google/falco/acpi_tables.c +++ b/src/mainboard/google/falco/acpi_tables.c @@ -129,7 +129,7 @@ unsigned long acpi_fill_srat(unsigned long current) }
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; int i; diff --git a/src/mainboard/google/link/acpi_tables.c b/src/mainboard/google/link/acpi_tables.c index 36c0c04..9be007e 100644 --- a/src/mainboard/google/link/acpi_tables.c +++ b/src/mainboard/google/link/acpi_tables.c @@ -137,7 +137,7 @@ unsigned long acpi_fill_srat(unsigned long current) }
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; int i; diff --git a/src/mainboard/google/panther/acpi_tables.c b/src/mainboard/google/panther/acpi_tables.c index 1a9e1e6..1ee5e51 100644 --- a/src/mainboard/google/panther/acpi_tables.c +++ b/src/mainboard/google/panther/acpi_tables.c @@ -146,7 +146,7 @@ unsigned long acpi_fill_srat(unsigned long current) }
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; int i; diff --git a/src/mainboard/google/parrot/acpi_tables.c b/src/mainboard/google/parrot/acpi_tables.c index e126216..2743c42 100644 --- a/src/mainboard/google/parrot/acpi_tables.c +++ b/src/mainboard/google/parrot/acpi_tables.c @@ -125,7 +125,7 @@ unsigned long acpi_fill_srat(unsigned long current) }
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; int i; diff --git a/src/mainboard/google/peppy/acpi_tables.c b/src/mainboard/google/peppy/acpi_tables.c index 8cac250..cfac125 100644 --- a/src/mainboard/google/peppy/acpi_tables.c +++ b/src/mainboard/google/peppy/acpi_tables.c @@ -138,7 +138,7 @@ unsigned long acpi_fill_srat(unsigned long current) }
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; int i; diff --git a/src/mainboard/google/rambi/acpi_tables.c b/src/mainboard/google/rambi/acpi_tables.c index 7c0c646..ae541de 100644 --- a/src/mainboard/google/rambi/acpi_tables.c +++ b/src/mainboard/google/rambi/acpi_tables.c @@ -108,7 +108,7 @@ unsigned long acpi_fill_srat(unsigned long current) }
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; int i; diff --git a/src/mainboard/google/samus/acpi_tables.c b/src/mainboard/google/samus/acpi_tables.c index a96cb24..c85e7c5 100644 --- a/src/mainboard/google/samus/acpi_tables.c +++ b/src/mainboard/google/samus/acpi_tables.c @@ -139,7 +139,7 @@ unsigned long acpi_fill_srat(unsigned long current) }
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; int i; diff --git a/src/mainboard/google/slippy/acpi_tables.c b/src/mainboard/google/slippy/acpi_tables.c index 7f596b7..c204def 100644 --- a/src/mainboard/google/slippy/acpi_tables.c +++ b/src/mainboard/google/slippy/acpi_tables.c @@ -135,7 +135,7 @@ unsigned long acpi_fill_srat(unsigned long current) }
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; int i; diff --git a/src/mainboard/google/stout/acpi_tables.c b/src/mainboard/google/stout/acpi_tables.c index 667bacf..c1d47d8 100644 --- a/src/mainboard/google/stout/acpi_tables.c +++ b/src/mainboard/google/stout/acpi_tables.c @@ -131,7 +131,7 @@ unsigned long acpi_fill_srat(unsigned long current) }
#define ALIGN_CURRENT current = ((current + 0x0f) & -0x10) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; int i; diff --git a/src/mainboard/hp/dl145_g1/acpi_tables.c b/src/mainboard/hp/dl145_g1/acpi_tables.c index 8756d1e..f2100a0 100644 --- a/src/mainboard/hp/dl145_g1/acpi_tables.c +++ b/src/mainboard/hp/dl145_g1/acpi_tables.c @@ -153,7 +153,7 @@ unsigned long acpi_fill_ssdt_generator(unsigned long current, const char *oem_ta return (unsigned long) (acpigen_get_current()); }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/hp/pavilion_m6_1035dx/acpi_tables.c b/src/mainboard/hp/pavilion_m6_1035dx/acpi_tables.c index dbe550c..aac4f4e 100644 --- a/src/mainboard/hp/pavilion_m6_1035dx/acpi_tables.c +++ b/src/mainboard/hp/pavilion_m6_1035dx/acpi_tables.c @@ -114,7 +114,7 @@ unsigned long acpi_fill_ssdt_generator(unsigned long current, const char *oem_ta return (unsigned long) (acpigen_get_current()); }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/ibase/mb899/acpi_tables.c b/src/mainboard/ibase/mb899/acpi_tables.c index e6a517e..b2cbd37 100644 --- a/src/mainboard/ibase/mb899/acpi_tables.c +++ b/src/mainboard/ibase/mb899/acpi_tables.c @@ -93,7 +93,7 @@ unsigned long acpi_fill_srat(unsigned long current) void smm_setup_structures(void *gnvs, void *tcg, void *smi1);
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; int i; diff --git a/src/mainboard/iei/kino-780am2-fam10/acpi_tables.c b/src/mainboard/iei/kino-780am2-fam10/acpi_tables.c index 01172ad..07b6e52 100644 --- a/src/mainboard/iei/kino-780am2-fam10/acpi_tables.c +++ b/src/mainboard/iei/kino-780am2-fam10/acpi_tables.c @@ -91,7 +91,7 @@ unsigned long acpi_fill_madt(unsigned long current) return current; }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/intel/baskingridge/acpi_tables.c b/src/mainboard/intel/baskingridge/acpi_tables.c index e1a65b0..1ce843a 100644 --- a/src/mainboard/intel/baskingridge/acpi_tables.c +++ b/src/mainboard/intel/baskingridge/acpi_tables.c @@ -147,7 +147,7 @@ unsigned long acpi_fill_srat(unsigned long current) }
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; int i; diff --git a/src/mainboard/intel/bayleybay_fsp/acpi_tables.c b/src/mainboard/intel/bayleybay_fsp/acpi_tables.c index 5f81e26..e926da6 100644 --- a/src/mainboard/intel/bayleybay_fsp/acpi_tables.c +++ b/src/mainboard/intel/bayleybay_fsp/acpi_tables.c @@ -91,7 +91,7 @@ unsigned long acpi_fill_srat(unsigned long current) }
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; int i; diff --git a/src/mainboard/intel/cougar_canyon2/acpi_tables.c b/src/mainboard/intel/cougar_canyon2/acpi_tables.c index 60ad5c8..bea32ec 100644 --- a/src/mainboard/intel/cougar_canyon2/acpi_tables.c +++ b/src/mainboard/intel/cougar_canyon2/acpi_tables.c @@ -119,7 +119,7 @@ unsigned long acpi_fill_srat(unsigned long current) void smm_setup_structures(void *gnvs, void *tcg, void *smi1);
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; int i; diff --git a/src/mainboard/intel/d945gclf/acpi_tables.c b/src/mainboard/intel/d945gclf/acpi_tables.c index fba2b42..703994e 100644 --- a/src/mainboard/intel/d945gclf/acpi_tables.c +++ b/src/mainboard/intel/d945gclf/acpi_tables.c @@ -84,7 +84,7 @@ void smm_setup_structures(void *gnvs, void *tcg, void *smi1); #endif
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; int i; diff --git a/src/mainboard/intel/eagleheights/acpi_tables.c b/src/mainboard/intel/eagleheights/acpi_tables.c index e1d8388..ab5b95f 100644 --- a/src/mainboard/intel/eagleheights/acpi_tables.c +++ b/src/mainboard/intel/eagleheights/acpi_tables.c @@ -104,7 +104,7 @@ unsigned long acpi_fill_srat(unsigned long current)
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/intel/emeraldlake2/acpi_tables.c b/src/mainboard/intel/emeraldlake2/acpi_tables.c index e914b9b..c0d80c1 100644 --- a/src/mainboard/intel/emeraldlake2/acpi_tables.c +++ b/src/mainboard/intel/emeraldlake2/acpi_tables.c @@ -146,7 +146,7 @@ unsigned long acpi_fill_srat(unsigned long current) void smm_setup_structures(void *gnvs, void *tcg, void *smi1);
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; int i; diff --git a/src/mainboard/intel/minnowmax/acpi_tables.c b/src/mainboard/intel/minnowmax/acpi_tables.c index 881c143..2e094e8 100644 --- a/src/mainboard/intel/minnowmax/acpi_tables.c +++ b/src/mainboard/intel/minnowmax/acpi_tables.c @@ -82,7 +82,7 @@ unsigned long acpi_fill_srat(unsigned long current) }
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; int i; diff --git a/src/mainboard/intel/mohonpeak/acpi_tables.c b/src/mainboard/intel/mohonpeak/acpi_tables.c index 0349075..7acaa05 100644 --- a/src/mainboard/intel/mohonpeak/acpi_tables.c +++ b/src/mainboard/intel/mohonpeak/acpi_tables.c @@ -119,7 +119,7 @@ unsigned long acpi_fill_srat(unsigned long current) void smm_setup_structures(void *gnvs, void *tcg, void *smi1);
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; int i; diff --git a/src/mainboard/intel/wtm2/acpi_tables.c b/src/mainboard/intel/wtm2/acpi_tables.c index cf75949..068feaa 100644 --- a/src/mainboard/intel/wtm2/acpi_tables.c +++ b/src/mainboard/intel/wtm2/acpi_tables.c @@ -144,7 +144,7 @@ unsigned long acpi_fill_srat(unsigned long current) }
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; int i; diff --git a/src/mainboard/intel/xe7501devkit/acpi_tables.c b/src/mainboard/intel/xe7501devkit/acpi_tables.c index a14d24f..8be03e6 100644 --- a/src/mainboard/intel/xe7501devkit/acpi_tables.c +++ b/src/mainboard/intel/xe7501devkit/acpi_tables.c @@ -95,7 +95,7 @@ unsigned long acpi_fill_madt(unsigned long current) }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/iwave/iWRainbowG6/acpi_tables.c b/src/mainboard/iwave/iWRainbowG6/acpi_tables.c index 8095ab0..7fcb798 100644 --- a/src/mainboard/iwave/iWRainbowG6/acpi_tables.c +++ b/src/mainboard/iwave/iWRainbowG6/acpi_tables.c @@ -97,7 +97,7 @@ unsigned long acpi_fill_srat(unsigned long current) void smm_setup_structures(void *gnvs, void *tcg, void *smi1);
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; int i; diff --git a/src/mainboard/iwill/dk8_htx/acpi_tables.c b/src/mainboard/iwill/dk8_htx/acpi_tables.c index 3d180eb..1a7a18b 100644 --- a/src/mainboard/iwill/dk8_htx/acpi_tables.c +++ b/src/mainboard/iwill/dk8_htx/acpi_tables.c @@ -142,7 +142,7 @@ unsigned long acpi_fill_ssdt_generator(unsigned long current, const char *oem_ta return (unsigned long) (acpigen_get_current()); }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/jetway/nf81-t56n-lf/acpi_tables.c b/src/mainboard/jetway/nf81-t56n-lf/acpi_tables.c index 95f2a0e..0c53bce 100644 --- a/src/mainboard/jetway/nf81-t56n-lf/acpi_tables.c +++ b/src/mainboard/jetway/nf81-t56n-lf/acpi_tables.c @@ -116,7 +116,7 @@ unsigned long acpi_fill_srat(unsigned long current) return current; }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/jetway/pa78vm5/acpi_tables.c b/src/mainboard/jetway/pa78vm5/acpi_tables.c index fc6f186..fab30fb 100644 --- a/src/mainboard/jetway/pa78vm5/acpi_tables.c +++ b/src/mainboard/jetway/pa78vm5/acpi_tables.c @@ -69,7 +69,7 @@ unsigned long acpi_fill_madt(unsigned long current) return current; }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/kontron/986lcd-m/acpi_tables.c b/src/mainboard/kontron/986lcd-m/acpi_tables.c index e6a517e..b2cbd37 100644 --- a/src/mainboard/kontron/986lcd-m/acpi_tables.c +++ b/src/mainboard/kontron/986lcd-m/acpi_tables.c @@ -93,7 +93,7 @@ unsigned long acpi_fill_srat(unsigned long current) void smm_setup_structures(void *gnvs, void *tcg, void *smi1);
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; int i; diff --git a/src/mainboard/kontron/kt690/acpi_tables.c b/src/mainboard/kontron/kt690/acpi_tables.c index 520dc6c..fb24567 100644 --- a/src/mainboard/kontron/kt690/acpi_tables.c +++ b/src/mainboard/kontron/kt690/acpi_tables.c @@ -79,7 +79,7 @@ unsigned long acpi_fill_ssdt_generator(unsigned long current, const char *oem_ta return (unsigned long) (acpigen_get_current()); }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/kontron/ktqm77/acpi_tables.c b/src/mainboard/kontron/ktqm77/acpi_tables.c index cf28f8b..7f98f76 100644 --- a/src/mainboard/kontron/ktqm77/acpi_tables.c +++ b/src/mainboard/kontron/ktqm77/acpi_tables.c @@ -111,7 +111,7 @@ unsigned long acpi_fill_srat(unsigned long current) }
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; int i; diff --git a/src/mainboard/lenovo/t520/acpi_tables.c b/src/mainboard/lenovo/t520/acpi_tables.c index 5dfae0a..9ea4bf8 100644 --- a/src/mainboard/lenovo/t520/acpi_tables.c +++ b/src/mainboard/lenovo/t520/acpi_tables.c @@ -113,7 +113,7 @@ unsigned long acpi_fill_srat(unsigned long current) }
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; int i; diff --git a/src/mainboard/lenovo/t530/acpi_tables.c b/src/mainboard/lenovo/t530/acpi_tables.c index 5dfae0a..9ea4bf8 100644 --- a/src/mainboard/lenovo/t530/acpi_tables.c +++ b/src/mainboard/lenovo/t530/acpi_tables.c @@ -113,7 +113,7 @@ unsigned long acpi_fill_srat(unsigned long current) }
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; int i; diff --git a/src/mainboard/lenovo/t60/acpi_tables.c b/src/mainboard/lenovo/t60/acpi_tables.c index f6ed4ae..4ff27d1 100644 --- a/src/mainboard/lenovo/t60/acpi_tables.c +++ b/src/mainboard/lenovo/t60/acpi_tables.c @@ -104,7 +104,7 @@ unsigned long acpi_fill_srat(unsigned long current) void smm_setup_structures(void *gnvs, void *tcg, void *smi1);
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; int i; diff --git a/src/mainboard/lenovo/x200/acpi_tables.c b/src/mainboard/lenovo/x200/acpi_tables.c index 6e6cd72..92e3f0d 100644 --- a/src/mainboard/lenovo/x200/acpi_tables.c +++ b/src/mainboard/lenovo/x200/acpi_tables.c @@ -136,7 +136,7 @@ unsigned long acpi_fill_srat(unsigned long current) void smm_setup_structures(void *gnvs, void *tcg, void *smi1);
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; int i; diff --git a/src/mainboard/lenovo/x201/acpi_tables.c b/src/mainboard/lenovo/x201/acpi_tables.c index b6e99dd..85b3a72 100644 --- a/src/mainboard/lenovo/x201/acpi_tables.c +++ b/src/mainboard/lenovo/x201/acpi_tables.c @@ -113,7 +113,7 @@ unsigned long acpi_fill_srat(unsigned long current) void smm_setup_structures(void *gnvs, void *tcg, void *smi1);
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; int i; diff --git a/src/mainboard/lenovo/x220/acpi_tables.c b/src/mainboard/lenovo/x220/acpi_tables.c index 5dfae0a..fd55bc3 100644 --- a/src/mainboard/lenovo/x220/acpi_tables.c +++ b/src/mainboard/lenovo/x220/acpi_tables.c @@ -31,11 +31,6 @@ #include <cpu/cpu.h> #include <cpu/x86/msr.h>
-extern const unsigned char AmlCode[]; -#if CONFIG_HAVE_ACPI_SLIC -unsigned long acpi_create_slic(unsigned long current); -#endif - #include <southbridge/intel/bd82x6x/pch.h> #include <southbridge/intel/bd82x6x/nvs.h> #include "thermal.h" @@ -46,7 +41,7 @@ static void acpi_update_thermal_table(global_nvs_t *gnvs) gnvs->tpsv = PASSIVE_TEMPERATURE; }
-static void acpi_create_gnvs(global_nvs_t *gnvs) +void acpi_create_gnvs(global_nvs_t *gnvs) { memset((void *)gnvs, 0, sizeof(*gnvs)); gnvs->apic = 1; @@ -93,13 +88,6 @@ unsigned long acpi_fill_madt(unsigned long current) return current; }
-unsigned long acpi_fill_ssdt_generator(unsigned long current, - const char *oem_table_id) -{ - generate_cpu_entries(); - return (unsigned long) (acpigen_get_current()); -} - unsigned long acpi_fill_slit(unsigned long current) { // Not implemented @@ -111,143 +99,3 @@ unsigned long acpi_fill_srat(unsigned long current) /* No NUMA, no SRAT */ return current; } - -#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) -{ - unsigned long current; - int i; - acpi_rsdp_t *rsdp; - acpi_rsdt_t *rsdt; - acpi_xsdt_t *xsdt; - acpi_hpet_t *hpet; - acpi_madt_t *madt; - acpi_mcfg_t *mcfg; - acpi_fadt_t *fadt; - acpi_facs_t *facs; -#if CONFIG_HAVE_ACPI_SLIC - acpi_header_t *slic; -#endif - acpi_header_t *ssdt; - acpi_header_t *dsdt; - - current = start; - - /* Align ACPI tables to 16byte */ - ALIGN_CURRENT; - - printk(BIOS_INFO, "ACPI: Writing ACPI tables at %lx.\n", start); - - /* We need at least an RSDP and an RSDT Table */ - rsdp = (acpi_rsdp_t *) current; - current += sizeof(acpi_rsdp_t); - ALIGN_CURRENT; - rsdt = (acpi_rsdt_t *) current; - current += sizeof(acpi_rsdt_t); - ALIGN_CURRENT; - xsdt = (acpi_xsdt_t *) current; - current += sizeof(acpi_xsdt_t); - ALIGN_CURRENT; - - /* clear all table memory */ - memset((void *) start, 0, current - start); - - acpi_write_rsdp(rsdp, rsdt, xsdt); - acpi_write_rsdt(rsdt); - acpi_write_xsdt(xsdt); - - printk(BIOS_DEBUG, "ACPI: * FACS\n"); - facs = (acpi_facs_t *) current; - current += sizeof(acpi_facs_t); - ALIGN_CURRENT; - acpi_create_facs(facs); - - printk(BIOS_DEBUG, "ACPI: * DSDT\n"); - dsdt = (acpi_header_t *) current; - memcpy(dsdt, &AmlCode, sizeof(acpi_header_t)); - current += dsdt->length; - memcpy(dsdt, &AmlCode, dsdt->length); - - ALIGN_CURRENT; - - printk(BIOS_DEBUG, "ACPI: * FADT\n"); - fadt = (acpi_fadt_t *) current; - current += sizeof(acpi_fadt_t); - ALIGN_CURRENT; - - acpi_create_fadt(fadt, facs, dsdt); - acpi_add_table(rsdp, fadt); - - /* - * We explicitly add these tables later on: - */ - printk(BIOS_DEBUG, "ACPI: * HPET\n"); - - hpet = (acpi_hpet_t *) current; - current += sizeof(acpi_hpet_t); - ALIGN_CURRENT; - acpi_create_hpet(hpet); - acpi_add_table(rsdp, hpet); - - /* If we want to use HPET Timers Linux wants an MADT */ - printk(BIOS_DEBUG, "ACPI: * MADT\n"); - - madt = (acpi_madt_t *) current; - acpi_create_madt(madt); - current += madt->header.length; - ALIGN_CURRENT; - acpi_add_table(rsdp, madt); - - printk(BIOS_DEBUG, "ACPI: * MCFG\n"); - mcfg = (acpi_mcfg_t *) current; - acpi_create_mcfg(mcfg); - current += mcfg->header.length; - ALIGN_CURRENT; - acpi_add_table(rsdp, mcfg); - - /* Pack GNVS into the ACPI table area */ - for (i=0; i < dsdt->length; i++) { - if (*(u32*)(((u32)dsdt) + i) == 0xC0DEBABE) { - printk(BIOS_DEBUG, "ACPI: Patching up global NVS in " - "DSDT at offset 0x%04x -> 0x%08lx\n", i, current); - *(u32*)(((u32)dsdt) + i) = current; // 0x92 bytes - acpi_save_gnvs(current); - break; - } - } - - /* And fill it */ - acpi_create_gnvs((global_nvs_t *)current); - - /* And tell SMI about it */ - smm_setup_structures((void *)current, NULL, NULL); - - current += sizeof(global_nvs_t); - ALIGN_CURRENT; - - /* We patched up the DSDT, so we need to recalculate the checksum */ - dsdt->checksum = 0; - dsdt->checksum = acpi_checksum((void *)dsdt, dsdt->length); - - printk(BIOS_DEBUG, "ACPI: * DSDT @ %p Length %x\n", dsdt, - dsdt->length); - -#if CONFIG_HAVE_ACPI_SLIC - printk(BIOS_DEBUG, "ACPI: * SLIC\n"); - slic = (acpi_header_t *)current; - current += acpi_create_slic(current); - ALIGN_CURRENT; - acpi_add_table(rsdp, slic); -#endif - - printk(BIOS_DEBUG, "ACPI: * SSDT\n"); - ssdt = (acpi_header_t *)current; - acpi_create_ssdt_generator(ssdt, ACPI_TABLE_CREATOR); - current += ssdt->length; - acpi_add_table(rsdp, ssdt); - ALIGN_CURRENT; - - printk(BIOS_DEBUG, "current = %lx\n", current); - printk(BIOS_INFO, "ACPI: done.\n"); - return current; -} diff --git a/src/mainboard/lenovo/x230/acpi_tables.c b/src/mainboard/lenovo/x230/acpi_tables.c index 5dfae0a..dc8832e 100644 --- a/src/mainboard/lenovo/x230/acpi_tables.c +++ b/src/mainboard/lenovo/x230/acpi_tables.c @@ -113,13 +113,10 @@ unsigned long acpi_fill_srat(unsigned long current) }
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; int i; - acpi_rsdp_t *rsdp; - acpi_rsdt_t *rsdt; - acpi_xsdt_t *xsdt; acpi_hpet_t *hpet; acpi_madt_t *madt; acpi_mcfg_t *mcfg; @@ -133,29 +130,6 @@ unsigned long write_acpi_tables(unsigned long start)
current = start;
- /* Align ACPI tables to 16byte */ - ALIGN_CURRENT; - - printk(BIOS_INFO, "ACPI: Writing ACPI tables at %lx.\n", start); - - /* We need at least an RSDP and an RSDT Table */ - rsdp = (acpi_rsdp_t *) current; - current += sizeof(acpi_rsdp_t); - ALIGN_CURRENT; - rsdt = (acpi_rsdt_t *) current; - current += sizeof(acpi_rsdt_t); - ALIGN_CURRENT; - xsdt = (acpi_xsdt_t *) current; - current += sizeof(acpi_xsdt_t); - ALIGN_CURRENT; - - /* clear all table memory */ - memset((void *) start, 0, current - start); - - acpi_write_rsdp(rsdp, rsdt, xsdt); - acpi_write_rsdt(rsdt); - acpi_write_xsdt(xsdt); - printk(BIOS_DEBUG, "ACPI: * FACS\n"); facs = (acpi_facs_t *) current; current += sizeof(acpi_facs_t); diff --git a/src/mainboard/lenovo/x60/acpi_tables.c b/src/mainboard/lenovo/x60/acpi_tables.c index cf07067..803e300 100644 --- a/src/mainboard/lenovo/x60/acpi_tables.c +++ b/src/mainboard/lenovo/x60/acpi_tables.c @@ -106,7 +106,7 @@ unsigned long acpi_fill_srat(unsigned long current) void smm_setup_structures(void *gnvs, void *tcg, void *smi1);
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; int i; diff --git a/src/mainboard/lippert/frontrunner-af/acpi_tables.c b/src/mainboard/lippert/frontrunner-af/acpi_tables.c index 588345e..f34bec0 100644 --- a/src/mainboard/lippert/frontrunner-af/acpi_tables.c +++ b/src/mainboard/lippert/frontrunner-af/acpi_tables.c @@ -116,7 +116,7 @@ unsigned long acpi_fill_srat(unsigned long current) return current; }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/lippert/toucan-af/acpi_tables.c b/src/mainboard/lippert/toucan-af/acpi_tables.c index 588345e..f34bec0 100644 --- a/src/mainboard/lippert/toucan-af/acpi_tables.c +++ b/src/mainboard/lippert/toucan-af/acpi_tables.c @@ -116,7 +116,7 @@ unsigned long acpi_fill_srat(unsigned long current) return current; }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/msi/ms7135/acpi_tables.c b/src/mainboard/msi/ms7135/acpi_tables.c index ee8e81f..335a1f2 100644 --- a/src/mainboard/msi/ms7135/acpi_tables.c +++ b/src/mainboard/msi/ms7135/acpi_tables.c @@ -93,7 +93,7 @@ unsigned long acpi_fill_ssdt_generator(unsigned long current, const char *oem_ta return (unsigned long) (acpigen_get_current()); }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/msi/ms9652_fam10/acpi_tables.c b/src/mainboard/msi/ms9652_fam10/acpi_tables.c index b1df30d..8a7b25e 100644 --- a/src/mainboard/msi/ms9652_fam10/acpi_tables.c +++ b/src/mainboard/msi/ms9652_fam10/acpi_tables.c @@ -104,7 +104,7 @@ unsigned long acpi_fill_ssdt_generator(unsigned long current, const char *oem_ta return 0; }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/packardbell/ms2290/acpi_tables.c b/src/mainboard/packardbell/ms2290/acpi_tables.c index 165de0d..6386485 100644 --- a/src/mainboard/packardbell/ms2290/acpi_tables.c +++ b/src/mainboard/packardbell/ms2290/acpi_tables.c @@ -111,7 +111,7 @@ unsigned long acpi_fill_srat(unsigned long current) void smm_setup_structures(void *gnvs, void *tcg, void *smi1);
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; int i; diff --git a/src/mainboard/roda/rk886ex/acpi_tables.c b/src/mainboard/roda/rk886ex/acpi_tables.c index f6ed4ae..4ff27d1 100644 --- a/src/mainboard/roda/rk886ex/acpi_tables.c +++ b/src/mainboard/roda/rk886ex/acpi_tables.c @@ -104,7 +104,7 @@ unsigned long acpi_fill_srat(unsigned long current) void smm_setup_structures(void *gnvs, void *tcg, void *smi1);
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; int i; diff --git a/src/mainboard/roda/rk9/acpi_tables.c b/src/mainboard/roda/rk9/acpi_tables.c index 6e6cd72..92e3f0d 100644 --- a/src/mainboard/roda/rk9/acpi_tables.c +++ b/src/mainboard/roda/rk9/acpi_tables.c @@ -136,7 +136,7 @@ unsigned long acpi_fill_srat(unsigned long current) void smm_setup_structures(void *gnvs, void *tcg, void *smi1);
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; int i; diff --git a/src/mainboard/samsung/lumpy/acpi_tables.c b/src/mainboard/samsung/lumpy/acpi_tables.c index 96f89b7..32ce644 100644 --- a/src/mainboard/samsung/lumpy/acpi_tables.c +++ b/src/mainboard/samsung/lumpy/acpi_tables.c @@ -146,7 +146,7 @@ unsigned long acpi_fill_srat(unsigned long current) void smm_setup_structures(void *gnvs, void *tcg, void *smi1);
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; int i; diff --git a/src/mainboard/samsung/stumpy/acpi_tables.c b/src/mainboard/samsung/stumpy/acpi_tables.c index cf1473a..d246a03 100644 --- a/src/mainboard/samsung/stumpy/acpi_tables.c +++ b/src/mainboard/samsung/stumpy/acpi_tables.c @@ -147,7 +147,7 @@ unsigned long acpi_fill_srat(unsigned long current) void smm_setup_structures(void *gnvs, void *tcg, void *smi1);
#define ALIGN_CURRENT current = (ALIGN(current, 16)) -unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; int i; diff --git a/src/mainboard/siemens/sitemp_g1p1/acpi_tables.c b/src/mainboard/siemens/sitemp_g1p1/acpi_tables.c index 18e1bf9..2e4fa79 100644 --- a/src/mainboard/siemens/sitemp_g1p1/acpi_tables.c +++ b/src/mainboard/siemens/sitemp_g1p1/acpi_tables.c @@ -124,7 +124,7 @@ unsigned long acpi_fill_ssdt_generator(unsigned long current, const char *oem_ta
#define ALIGN_CURRENT current = (ALIGN(current, 16))
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; int i; diff --git a/src/mainboard/supermicro/h8qgi/acpi_tables.c b/src/mainboard/supermicro/h8qgi/acpi_tables.c index 335c5ec..07ec32e 100644 --- a/src/mainboard/supermicro/h8qgi/acpi_tables.c +++ b/src/mainboard/supermicro/h8qgi/acpi_tables.c @@ -155,7 +155,7 @@ unsigned long acpi_fill_ssdt_generator(unsigned long current, const char *oem_ta return (unsigned long) (acpigen_get_current()); }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/supermicro/h8scm/acpi_tables.c b/src/mainboard/supermicro/h8scm/acpi_tables.c index d051cef..3deafa7 100644 --- a/src/mainboard/supermicro/h8scm/acpi_tables.c +++ b/src/mainboard/supermicro/h8scm/acpi_tables.c @@ -137,7 +137,7 @@ unsigned long acpi_fill_ssdt_generator(unsigned long current, const char *oem_ta return (unsigned long) (acpigen_get_current()); }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/supermicro/h8scm_fam10/acpi_tables.c b/src/mainboard/supermicro/h8scm_fam10/acpi_tables.c index ae9cca9..e8955fb 100644 --- a/src/mainboard/supermicro/h8scm_fam10/acpi_tables.c +++ b/src/mainboard/supermicro/h8scm_fam10/acpi_tables.c @@ -83,7 +83,7 @@ unsigned long acpi_fill_madt(unsigned long current) return current; }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/technexion/tim5690/acpi_tables.c b/src/mainboard/technexion/tim5690/acpi_tables.c index 520dc6c..fb24567 100644 --- a/src/mainboard/technexion/tim5690/acpi_tables.c +++ b/src/mainboard/technexion/tim5690/acpi_tables.c @@ -79,7 +79,7 @@ unsigned long acpi_fill_ssdt_generator(unsigned long current, const char *oem_ta return (unsigned long) (acpigen_get_current()); }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/technexion/tim8690/acpi_tables.c b/src/mainboard/technexion/tim8690/acpi_tables.c index 520dc6c..fb24567 100644 --- a/src/mainboard/technexion/tim8690/acpi_tables.c +++ b/src/mainboard/technexion/tim8690/acpi_tables.c @@ -79,7 +79,7 @@ unsigned long acpi_fill_ssdt_generator(unsigned long current, const char *oem_ta return (unsigned long) (acpigen_get_current()); }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/tyan/s2891/acpi_tables.c b/src/mainboard/tyan/s2891/acpi_tables.c index 42d9152..ef0609c 100644 --- a/src/mainboard/tyan/s2891/acpi_tables.c +++ b/src/mainboard/tyan/s2891/acpi_tables.c @@ -90,7 +90,7 @@ unsigned long acpi_fill_ssdt_generator(unsigned long current, const char *oem_ta return (unsigned long) (acpigen_get_current()); }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/tyan/s2892/acpi_tables.c b/src/mainboard/tyan/s2892/acpi_tables.c index 42d9152..ef0609c 100644 --- a/src/mainboard/tyan/s2892/acpi_tables.c +++ b/src/mainboard/tyan/s2892/acpi_tables.c @@ -90,7 +90,7 @@ unsigned long acpi_fill_ssdt_generator(unsigned long current, const char *oem_ta return (unsigned long) (acpigen_get_current()); }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/tyan/s2895/acpi_tables.c b/src/mainboard/tyan/s2895/acpi_tables.c index 1974171..6935e0e 100644 --- a/src/mainboard/tyan/s2895/acpi_tables.c +++ b/src/mainboard/tyan/s2895/acpi_tables.c @@ -109,7 +109,7 @@ unsigned long acpi_fill_ssdt_generator(unsigned long current, const char *oem_ta return (unsigned long) (acpigen_get_current()); }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/tyan/s8226/acpi_tables.c b/src/mainboard/tyan/s8226/acpi_tables.c index a49b112..b2569d6 100644 --- a/src/mainboard/tyan/s8226/acpi_tables.c +++ b/src/mainboard/tyan/s8226/acpi_tables.c @@ -137,7 +137,7 @@ unsigned long acpi_fill_ssdt_generator(unsigned long current, const char *oem_ta return (unsigned long) (acpigen_get_current()); }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/via/epia-m/acpi_tables.c b/src/mainboard/via/epia-m/acpi_tables.c index 20c0e6a..c97e56c 100644 --- a/src/mainboard/via/epia-m/acpi_tables.c +++ b/src/mainboard/via/epia-m/acpi_tables.c @@ -37,7 +37,7 @@ unsigned long acpi_fill_srat(unsigned long current) return current; }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/via/epia-m700/acpi_tables.c b/src/mainboard/via/epia-m700/acpi_tables.c index 7d95616..c788886 100644 --- a/src/mainboard/via/epia-m700/acpi_tables.c +++ b/src/mainboard/via/epia-m700/acpi_tables.c @@ -117,7 +117,7 @@ unsigned long acpi_fill_srat(unsigned long current) #define ALIGN(x,a) __ALIGN_MASK(x,(typeof(x))(a)-1) #define __ALIGN_MASK(x,mask) (((x)+(mask))&~(mask))
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/via/epia-n/acpi_tables.c b/src/mainboard/via/epia-n/acpi_tables.c index 82dac53..3b2e3cc 100644 --- a/src/mainboard/via/epia-n/acpi_tables.c +++ b/src/mainboard/via/epia-n/acpi_tables.c @@ -118,7 +118,7 @@ unsigned long acpi_fill_srat(unsigned long current) return current; }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/via/vt8454c/acpi_tables.c b/src/mainboard/via/vt8454c/acpi_tables.c index a13395a..e35a3de 100644 --- a/src/mainboard/via/vt8454c/acpi_tables.c +++ b/src/mainboard/via/vt8454c/acpi_tables.c @@ -81,7 +81,7 @@ unsigned long acpi_fill_srat(unsigned long current) return current; }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/mainboard/winent/mb6047/acpi_tables.c b/src/mainboard/winent/mb6047/acpi_tables.c index 1b59fbb..058dce9 100644 --- a/src/mainboard/winent/mb6047/acpi_tables.c +++ b/src/mainboard/winent/mb6047/acpi_tables.c @@ -74,7 +74,7 @@ unsigned long acpi_fill_ssdt_generator(unsigned long current, const char *oem_ta return (unsigned long) (acpigen_get_current()); }
-unsigned long write_acpi_tables(unsigned long start) +unsigned long mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/northbridge/intel/sandybridge/acpi.c b/src/northbridge/intel/sandybridge/acpi.c index ea9ff50..20b8764 100644 --- a/src/northbridge/intel/sandybridge/acpi.c +++ b/src/northbridge/intel/sandybridge/acpi.c @@ -31,6 +31,10 @@ #include <build.h> #include "sandybridge.h" #include <drivers/intel/gma/intel_bios.h> +#include <southbridge/intel/bd82x6x/nvs.h> +#include <cbmem.h> +#include <arch/acpigen.h> +#include <cpu/cpu.h>
unsigned long acpi_fill_mcfg(unsigned long current) { @@ -199,3 +203,67 @@ int init_igd_opregion(igd_opregion_t *opregion)
return 0; } + +#define ALIGN_CURRENT current = (ALIGN(current, 16)) +unsigned long northbridge_write_acpi_tables(unsigned long start, acpi_rsdp_t *rsdp) +{ + unsigned long current; + acpi_hpet_t *hpet; + acpi_madt_t *madt; + acpi_mcfg_t *mcfg; + + current = start; + + /* + * We explicitly add these tables later on: + */ + printk(BIOS_DEBUG, "ACPI: * HPET\n"); + + hpet = (acpi_hpet_t *) current; + current += sizeof(acpi_hpet_t); + ALIGN_CURRENT; + acpi_create_hpet(hpet); + acpi_add_table(rsdp, hpet); + + /* If we want to use HPET Timers Linux wants an MADT */ + printk(BIOS_DEBUG, "ACPI: * MADT\n"); + + madt = (acpi_madt_t *) current; + acpi_create_madt(madt); + current += madt->header.length; + ALIGN_CURRENT; + acpi_add_table(rsdp, madt); + + printk(BIOS_DEBUG, "ACPI: * MCFG\n"); + mcfg = (acpi_mcfg_t *) current; + acpi_create_mcfg(mcfg); + current += mcfg->header.length; + ALIGN_CURRENT; + acpi_add_table(rsdp, mcfg); + + printk(BIOS_DEBUG, "current = %lx\n", current); + printk(BIOS_INFO, "ACPI: done.\n"); + return current; +} + +unsigned long northbridge_acpi_fill_ssdt_generator(unsigned long current, + const char *oem_table_id) +{ + global_nvs_t *gnvs = cbmem_add (CBMEM_ID_ACPI_GNVS, sizeof (*gnvs)); + + if (gnvs) { + int scopelen; + acpi_create_gnvs(gnvs); + /* And tell SMI about it */ + smm_setup_structures(gnvs, NULL, NULL); + + /* Add it to SSDT. */ + scopelen = acpigen_write_scope("\"); + scopelen += acpigen_write_name_dword("NVSA", (u32) gnvs); + acpigen_patch_len(scopelen - 1); + } + + generate_cpu_entries(); + return (unsigned long) (acpigen_get_current()); +} + diff --git a/src/northbridge/intel/sandybridge/northbridge.c b/src/northbridge/intel/sandybridge/northbridge.c index b46ae22..d22d113 100644 --- a/src/northbridge/intel/sandybridge/northbridge.c +++ b/src/northbridge/intel/sandybridge/northbridge.c @@ -444,6 +444,9 @@ static struct device_operations mc_ops = { .enable = northbridge_enable, .scan_bus = 0, .ops_pci = &intel_pci_ops, + .write_acpi_tables = northbridge_write_acpi_tables, + .acpi_fill_ssdt_generator = northbridge_acpi_fill_ssdt_generator, + };
static const struct pci_driver mc_driver_0100 __pci_driver = { diff --git a/src/northbridge/intel/sandybridge/sandybridge.h b/src/northbridge/intel/sandybridge/sandybridge.h index 291ea46..1b7c3b1 100644 --- a/src/northbridge/intel/sandybridge/sandybridge.h +++ b/src/northbridge/intel/sandybridge/sandybridge.h @@ -235,6 +235,10 @@ struct mrc_data_container *find_current_mrc_cache(void); #if !defined(__PRE_RAM__) #include "gma.h" int init_igd_opregion(igd_opregion_t *igd_opregion); +struct acpi_rsdp; +unsigned long northbridge_write_acpi_tables(unsigned long start, struct acpi_rsdp *rsdp); +unsigned long northbridge_acpi_fill_ssdt_generator(unsigned long current, + const char *oem_table_id); #endif
#endif diff --git a/src/soc/intel/baytrail/acpi/globalnvs.asl b/src/soc/intel/baytrail/acpi/globalnvs.asl index b384cea..3ec8aad 100644 --- a/src/soc/intel/baytrail/acpi/globalnvs.asl +++ b/src/soc/intel/baytrail/acpi/globalnvs.asl @@ -30,7 +30,7 @@ Name(\PICM, 0) // IOAPIC/8259 */
-OperationRegion (GNVS, SystemMemory, 0xC0DEBABE, 0x2000) +OperationRegion (GNVS, SystemMemory, NVSA, 0x2000) Field (GNVS, ByteAcc, NoLock, Preserve) { /* Miscellaneous */ diff --git a/src/soc/intel/fsp_baytrail/acpi/globalnvs.asl b/src/soc/intel/fsp_baytrail/acpi/globalnvs.asl index 696390d..56db104 100644 --- a/src/soc/intel/fsp_baytrail/acpi/globalnvs.asl +++ b/src/soc/intel/fsp_baytrail/acpi/globalnvs.asl @@ -30,7 +30,7 @@ Name(\PICM, 0) // IOAPIC/8259 */
-OperationRegion (GNVS, SystemMemory, 0xC0DEBABE, 0x2000) +OperationRegion (GNVS, SystemMemory, NVSA, 0x2000) Field (GNVS, ByteAcc, NoLock, Preserve) { /* Miscellaneous */ diff --git a/src/southbridge/intel/bd82x6x/acpi/globalnvs.asl b/src/southbridge/intel/bd82x6x/acpi/globalnvs.asl index 99edc31..35094a6 100644 --- a/src/southbridge/intel/bd82x6x/acpi/globalnvs.asl +++ b/src/southbridge/intel/bd82x6x/acpi/globalnvs.asl @@ -31,8 +31,8 @@ Name(\DSEN, 1) // Display Output Switching Enable * we have to fix it up in coreboot's ACPI creation phase. */
- -OperationRegion (GNVS, SystemMemory, 0xC0DEBABE, 0xf00) +External(NVSA) +OperationRegion (GNVS, SystemMemory, NVSA, 0xf00) Field (GNVS, ByteAcc, NoLock, Preserve) { /* Miscellaneous */ diff --git a/src/southbridge/intel/bd82x6x/nvs.h b/src/southbridge/intel/bd82x6x/nvs.h index 1038f73..9cdfb13 100644 --- a/src/southbridge/intel/bd82x6x/nvs.h +++ b/src/southbridge/intel/bd82x6x/nvs.h @@ -158,3 +158,4 @@ typedef struct { /* Used in SMM to find the ACPI GNVS address */ global_nvs_t *smm_get_gnvs(void); #endif +void acpi_create_gnvs(global_nvs_t *gnvs); diff --git a/src/southbridge/intel/fsp_bd82x6x/acpi/globalnvs.asl b/src/southbridge/intel/fsp_bd82x6x/acpi/globalnvs.asl index 2fe092d..4b2bec8 100644 --- a/src/southbridge/intel/fsp_bd82x6x/acpi/globalnvs.asl +++ b/src/southbridge/intel/fsp_bd82x6x/acpi/globalnvs.asl @@ -32,7 +32,7 @@ Name(\DSEN, 1) // Display Output Switching Enable */
-OperationRegion (GNVS, SystemMemory, 0xC0DEBABE, 0xf00) +OperationRegion (GNVS, SystemMemory, NVSA, 0xf00) Field (GNVS, ByteAcc, NoLock, Preserve) { /* Miscellaneous */ diff --git a/src/southbridge/intel/fsp_rangeley/acpi/globalnvs.asl b/src/southbridge/intel/fsp_rangeley/acpi/globalnvs.asl index 21209db..ee8fc3d 100644 --- a/src/southbridge/intel/fsp_rangeley/acpi/globalnvs.asl +++ b/src/southbridge/intel/fsp_rangeley/acpi/globalnvs.asl @@ -32,7 +32,7 @@ Name(\DSEN, 1) // Display Output Switching Enable */
-OperationRegion (GNVS, SystemMemory, 0xC0DEBABE, 0xf00) +OperationRegion (GNVS, SystemMemory, NVSA, 0xf00) Field (GNVS, ByteAcc, NoLock, Preserve) { /* Miscellaneous */ diff --git a/src/southbridge/intel/i82371eb/acpi_tables.c b/src/southbridge/intel/i82371eb/acpi_tables.c index a0cc82b..7cf651a 100644 --- a/src/southbridge/intel/i82371eb/acpi_tables.c +++ b/src/southbridge/intel/i82371eb/acpi_tables.c @@ -101,7 +101,7 @@ unsigned long __attribute__((weak)) acpi_fill_ssdt_generator(unsigned long curre return (unsigned long) acpigen_get_current(); }
-unsigned long __attribute__((weak)) write_acpi_tables(unsigned long start) +unsigned long __attribute__((weak)) mainboard_write_acpi_tables(unsigned long start) { unsigned long current; acpi_rsdp_t *rsdp; diff --git a/src/southbridge/intel/i82801gx/acpi/globalnvs.asl b/src/southbridge/intel/i82801gx/acpi/globalnvs.asl index 0384376..2e18eb1 100644 --- a/src/southbridge/intel/i82801gx/acpi/globalnvs.asl +++ b/src/southbridge/intel/i82801gx/acpi/globalnvs.asl @@ -31,7 +31,7 @@ Name(\DSEN, 1) // Display Output Switching Enable */
-OperationRegion (GNVS, SystemMemory, 0xC0DEBABE, 0x100) +OperationRegion (GNVS, SystemMemory, NVSA, 0x100) Field (GNVS, ByteAcc, NoLock, Preserve) { /* Miscellaneous */ diff --git a/src/southbridge/intel/i82801ix/acpi/globalnvs.asl b/src/southbridge/intel/i82801ix/acpi/globalnvs.asl index 0384376..2e18eb1 100644 --- a/src/southbridge/intel/i82801ix/acpi/globalnvs.asl +++ b/src/southbridge/intel/i82801ix/acpi/globalnvs.asl @@ -31,7 +31,7 @@ Name(\DSEN, 1) // Display Output Switching Enable */
-OperationRegion (GNVS, SystemMemory, 0xC0DEBABE, 0x100) +OperationRegion (GNVS, SystemMemory, NVSA, 0x100) Field (GNVS, ByteAcc, NoLock, Preserve) { /* Miscellaneous */ diff --git a/src/southbridge/intel/lynxpoint/acpi/globalnvs.asl b/src/southbridge/intel/lynxpoint/acpi/globalnvs.asl index ef05dca..94c3792 100644 --- a/src/southbridge/intel/lynxpoint/acpi/globalnvs.asl +++ b/src/southbridge/intel/lynxpoint/acpi/globalnvs.asl @@ -32,7 +32,7 @@ Name(\DSEN, 1) // Display Output Switching Enable */
-OperationRegion (GNVS, SystemMemory, 0xC0DEBABE, 0xf00) +OperationRegion (GNVS, SystemMemory, NVSA, 0xf00) Field (GNVS, ByteAcc, NoLock, Preserve) { /* Miscellaneous */ diff --git a/src/southbridge/intel/sch/acpi/globalnvs.asl b/src/southbridge/intel/sch/acpi/globalnvs.asl index 5ac1c83..8d33eee 100644 --- a/src/southbridge/intel/sch/acpi/globalnvs.asl +++ b/src/southbridge/intel/sch/acpi/globalnvs.asl @@ -31,7 +31,7 @@ Name(\DSEN, 1) // Display Output Switching Enable */
-OperationRegion (GNVS, SystemMemory, 0xC0DEBABE, 0x100) +OperationRegion (GNVS, SystemMemory, NVSA, 0x100) Field (GNVS, ByteAcc, NoLock, Preserve) { /* Miscellaneous */