[coreboot-gerrit] Change in coreboot[master]: nb/haswell: set ASLB gnvs to OpRegion CBMEM table

Matt DeVillier (Code Review) gerrit at coreboot.org
Sat Jun 17 19:57:29 CEST 2017


Matt DeVillier has uploaded this change for review. ( https://review.coreboot.org/20254


Change subject: nb/haswell: set ASLB gnvs to OpRegion CBMEM table
......................................................................

nb/haswell: set ASLB gnvs to OpRegion CBMEM table

Intel's Windows display driver requires ASLB to point to
the OpRegion CBMEM table/memory region in order to make use
of it. This patch brings Haswell in line with SNB/IVB.

Change-Id: Ie062cbfe7e7f60c2a4e2b9111f6b6da87ced7a39
Signed-off-by: Matt DeVillier <matt.devillier at gmail.com>
---
M src/northbridge/intel/haswell/gma.c
1 file changed, 13 insertions(+), 0 deletions(-)



  git pull ssh://review.coreboot.org:29418/coreboot refs/changes/54/20254/1

diff --git a/src/northbridge/intel/haswell/gma.c b/src/northbridge/intel/haswell/gma.c
index fa4dec9..63c2627 100644
--- a/src/northbridge/intel/haswell/gma.c
+++ b/src/northbridge/intel/haswell/gma.c
@@ -14,6 +14,8 @@
  */
 
 #include <arch/io.h>
+#include <cbfs.h>
+#include <cbmem.h>
 #include <console/console.h>
 #include <bootmode.h>
 #include <delay.h>
@@ -26,6 +28,7 @@
 #include <northbridge/intel/common/gma_opregion.h>
 #include <stdlib.h>
 #include <string.h>
+#include <southbridge/intel/lynxpoint/nvs.h>
 
 #include "chip.h"
 #include "haswell.h"
@@ -514,12 +517,22 @@
 		      struct acpi_rsdp *const rsdp)
 {
 	igd_opregion_t *opregion = (igd_opregion_t *)current;
+	global_nvs_t *gnvs;
 
 	if (init_igd_opregion(opregion) != CB_SUCCESS)
 		return current;
 
 	current += sizeof(igd_opregion_t);
 
+	/* GNVS has been already set up */
+	gnvs = cbmem_find(CBMEM_ID_ACPI_GNVS);
+	if (gnvs) {
+		/* IGD OpRegion Base Address */
+		gnvs->aslb = (u32)(uintptr_t)opregion;
+	} else {
+		printk(BIOS_ERR, "Error: GNVS table not found.\n");
+	}
+
 	gma_enable_swsci();
 
 	current = acpi_align_current(current);

-- 
To view, visit https://review.coreboot.org/20254
To unsubscribe, visit https://review.coreboot.org/settings

Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: Ie062cbfe7e7f60c2a4e2b9111f6b6da87ced7a39
Gerrit-Change-Number: 20254
Gerrit-PatchSet: 1
Gerrit-Owner: Matt DeVillier <matt.devillier at gmail.com>



More information about the coreboot-gerrit mailing list