soc/intel/braswell: Save/restore GMA OpRegion address

Add global/ACPI nvs variables required for IGD OpRegion.
Add functions necessary to save the ACPI OpRegion table
address in ASLB, and restore table address upon S3 resume.

Implementation modeled on existing Baytrail code.

Test: boot Windows 10 on google/edgar with Tianocore payload and
GOP display init, observe display driver loaded and functional,
display not black screen when resuming from S3 suspend.

Change-Id: I7c1fbf818510949420f70e93ed4780e94e598508
Signed-off-by: Matt DeVillier <matt.devillier@gmail.com>
Reviewed-on: https://review.coreboot.org/25197
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Patrick Rudolph <siro@das-labor.org>
This commit is contained in:
Matt DeVillier
2017-07-01 13:02:47 -05:00
committed by Martin Roth
parent c7edf18f7c
commit 132bbe6be5
4 changed files with 98 additions and 1 deletions

View File

@@ -486,6 +486,7 @@ unsigned long southcluster_write_acpi_tables(device_t device,
struct acpi_rsdp *rsdp)
{
acpi_header_t *ssdt2;
global_nvs_t *gnvs = cbmem_find(CBMEM_ID_ACPI_GNVS);
current = acpi_write_hpet(device, current, rsdp);
current = acpi_align_current(current);
@@ -496,6 +497,8 @@ unsigned long southcluster_write_acpi_tables(device_t device,
printk(BIOS_DEBUG, "ACPI: * IGD OpRegion\n");
opregion = (igd_opregion_t *)current;
intel_gma_init_igd_opregion(opregion);
if (gnvs)
gnvs->aslb = (u32)opregion;
update_igd_opregion(opregion);
current += sizeof(igd_opregion_t);
current = acpi_align_current(current);