summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/southbridge/intel/bd82x6x/lpc.c4
-rw-r--r--src/southbridge/intel/ibexpeak/lpc.c4
-rw-r--r--src/southbridge/intel/lynxpoint/lpc.c9
3 files changed, 16 insertions, 1 deletions
diff --git a/src/southbridge/intel/bd82x6x/lpc.c b/src/southbridge/intel/bd82x6x/lpc.c
index fa05d54097..a1c7c2a289 100644
--- a/src/southbridge/intel/bd82x6x/lpc.c
+++ b/src/southbridge/intel/bd82x6x/lpc.c
@@ -33,6 +33,7 @@
#include <arch/acpigen.h>
#include <drivers/intel/gma/i915.h>
#include <cbmem.h>
+#include <string.h>
#include "pch.h"
#include "nvs.h"
@@ -680,6 +681,9 @@ static unsigned long southbridge_fill_ssdt(unsigned long current, const char *oe
if (gnvs) {
int scopelen;
+
+ memset(gnvs, 0, sizeof (*gnvs));
+
acpi_create_gnvs(gnvs);
/* IGD OpRegion Base Address */
gnvs->aslb = (u32)opregion;
diff --git a/src/southbridge/intel/ibexpeak/lpc.c b/src/southbridge/intel/ibexpeak/lpc.c
index 7580aa99fe..27ece63359 100644
--- a/src/southbridge/intel/ibexpeak/lpc.c
+++ b/src/southbridge/intel/ibexpeak/lpc.c
@@ -34,6 +34,7 @@
#include <arch/acpigen.h>
#include <drivers/intel/gma/i915.h>
#include <cbmem.h>
+#include <string.h>
#include "pch.h"
#include "nvs.h"
@@ -674,6 +675,9 @@ static unsigned long southbridge_fill_ssdt(unsigned long current, const char *oe
if (gnvs) {
int scopelen;
+
+ memset(gnvs, 0, sizeof (*gnvs));
+
acpi_create_gnvs(gnvs);
/* IGD OpRegion Base Address */
gnvs->aslb = (u32)opregion;
diff --git a/src/southbridge/intel/lynxpoint/lpc.c b/src/southbridge/intel/lynxpoint/lpc.c
index d1a7203041..451aeabc2e 100644
--- a/src/southbridge/intel/lynxpoint/lpc.c
+++ b/src/southbridge/intel/lynxpoint/lpc.c
@@ -745,7 +745,14 @@ static void set_subsystem(device_t dev, unsigned vendor, unsigned device)
static unsigned long southbridge_fill_ssdt(unsigned long current, const char *oem_table_id)
{
- global_nvs_t *gnvs = cbmem_add (CBMEM_ID_ACPI_GNVS, sizeof (*gnvs));
+ global_nvs_t *gnvs;
+
+ gnvs = cbmem_find(CBMEM_ID_ACPI_GNVS);
+ if (!gnvs) {
+ gnvs = cbmem_add(CBMEM_ID_ACPI_GNVS, sizeof (*gnvs));
+ if (gnvs)
+ memset(gnvs, 0, sizeof(*gnvs));
+ }
if (gnvs) {
int scopelen;