summaryrefslogtreecommitdiff
path: root/src/mainboard/google/samus
diff options
context:
space:
mode:
Diffstat (limited to 'src/mainboard/google/samus')
-rw-r--r--src/mainboard/google/samus/ec.h4
-rw-r--r--src/mainboard/google/samus/mainboard.c14
2 files changed, 18 insertions, 0 deletions
diff --git a/src/mainboard/google/samus/ec.h b/src/mainboard/google/samus/ec.h
index 1ba16777ce..295d04001f 100644
--- a/src/mainboard/google/samus/ec.h
+++ b/src/mainboard/google/samus/ec.h
@@ -22,6 +22,10 @@
#include <ec/google/chromeec/ec_commands.h>
+#define SAMUS_EC_BOARD_VERSION_EVT 3
+#define SAMUS_EC_BOARD_VERSION_EVT2 4
+#define SAMUS_EC_BOARD_VERSION_EVT3 5
+
#define EC_SCI_GPI 36 /* GPIO36 is EC_SCI# */
#define EC_SMI_GPI 34 /* GPIO34 is EC_SMI# */
diff --git a/src/mainboard/google/samus/mainboard.c b/src/mainboard/google/samus/mainboard.c
index 89303b9017..85e9dfbbee 100644
--- a/src/mainboard/google/samus/mainboard.c
+++ b/src/mainboard/google/samus/mainboard.c
@@ -32,12 +32,26 @@
#include <arch/io.h>
#include <arch/interrupt.h>
#include <boot/coreboot_tables.h>
+#include <ec/google/chromeec/ec.h>
#include "ec.h"
void mainboard_suspend_resume(void)
{
}
+const char *smbios_mainboard_version(void)
+{
+ switch (google_chromeec_get_board_version()) {
+ case SAMUS_EC_BOARD_VERSION_EVT:
+ return "EVT";
+ case SAMUS_EC_BOARD_VERSION_EVT2:
+ return "EVT2";
+ case SAMUS_EC_BOARD_VERSION_EVT3:
+ return "EVT3";
+ }
+ return "Unknown";
+}
+
static void mainboard_init(device_t dev)
{
mainboard_ec_init();