]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
x86: cros_ec: Enable cros_ec for link
authorSimon Glass <sjg@chromium.org>
Fri, 10 Oct 2014 13:30:16 +0000 (07:30 -0600)
committerSimon Glass <sjg@chromium.org>
Thu, 23 Oct 2014 03:50:33 +0000 (21:50 -0600)
Add defines to enable the Chrome OS EC interface and set it up on init.

Signed-off-by: Simon Glass <sjg@chromium.org>
board/chromebook-x86/coreboot/Makefile
board/chromebook-x86/coreboot/coreboot.c [new file with mode: 0644]
include/configs/coreboot.h

index 4f2ac898ebcf3c52ebcb78aef0345612a5d94e0d..27ebe78eb139184cf3687832d13d467ece6ddb20 100644 (file)
@@ -12,4 +12,4 @@
 # SPDX-License-Identifier:     GPL-2.0+
 #
 
-obj-y  += coreboot_start.o
+obj-y  += coreboot_start.o coreboot.o
diff --git a/board/chromebook-x86/coreboot/coreboot.c b/board/chromebook-x86/coreboot/coreboot.c
new file mode 100644 (file)
index 0000000..0240c34
--- /dev/null
@@ -0,0 +1,16 @@
+/*
+ * Copyright (C) 2013 Google, Inc
+ *
+ * SPDX-License-Identifier:    GPL-2.0+
+ */
+
+#include <common.h>
+#include <cros_ec.h>
+
+int arch_early_init_r(void)
+{
+       if (cros_ec_board_init())
+               return -1;
+
+       return 0;
+}
index f03a768ed7bc48a3e7a439f4678a484144091d92..ce614c813b2621fe1fa4124e729a9ef874644d33 100644 (file)
  */
 #define CONFIG_PCI
 
+#define CONFIG_CROS_EC
+#define CONFIG_CROS_EC_LPC
+#define CONFIG_CMD_CROS_EC
+#define CONFIG_ARCH_EARLY_INIT_R
+
 /*-----------------------------------------------------------------------
  * USB configuration
  */