summaryrefslogtreecommitdiff
path: root/src/vendorcode/google
diff options
context:
space:
mode:
Diffstat (limited to 'src/vendorcode/google')
-rw-r--r--src/vendorcode/google/chromeos/gnvs.c9
-rw-r--r--src/vendorcode/google/chromeos/gnvs.h1
2 files changed, 9 insertions, 1 deletions
diff --git a/src/vendorcode/google/chromeos/gnvs.c b/src/vendorcode/google/chromeos/gnvs.c
index 024dbf8f7e..aaca95aa43 100644
--- a/src/vendorcode/google/chromeos/gnvs.c
+++ b/src/vendorcode/google/chromeos/gnvs.c
@@ -23,7 +23,7 @@
#include <console/console.h>
#include "gnvs.h"
-chromeos_acpi_t *vboot_data;
+chromeos_acpi_t *vboot_data = NULL;
static u32 me_hash_saved[8];
void chromeos_init_vboot(chromeos_acpi_t *chromeos)
@@ -41,7 +41,14 @@ void chromeos_set_me_hash(u32 *hash, int len)
/* Copy to NVS or save until it is ready */
if (vboot_data)
+ /* This does never happen! */
memcpy(vboot_data->mehh, hash, len*sizeof(u32));
else
memcpy(me_hash_saved, hash, len*sizeof(u32));
}
+
+void acpi_get_vdat_info(void **vdat_addr, uint32_t *vdat_size)
+{
+ *vdat_addr = vboot_data;
+ *vdat_size = sizeof(*vboot_data);
+}
diff --git a/src/vendorcode/google/chromeos/gnvs.h b/src/vendorcode/google/chromeos/gnvs.h
index 6dd740fb77..40674944fa 100644
--- a/src/vendorcode/google/chromeos/gnvs.h
+++ b/src/vendorcode/google/chromeos/gnvs.h
@@ -64,5 +64,6 @@ typedef struct {
extern chromeos_acpi_t *vboot_data;
void chromeos_init_vboot(chromeos_acpi_t *chromeos);
void chromeos_set_me_hash(u32*, int);
+void acpi_get_vdat_info(void **vdat_addr, uint32_t *vdat_size);
#endif