summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAseda Aboagye <aaboagye@google.com>2020-01-03 12:15:18 -0800
committerCommit Bot <commit-bot@chromium.org>2020-01-03 23:22:09 +0000
commit891aef19bb73822b5ec6c7ee088f99cf1c793253 (patch)
treed16039c311fb866b030660bdc04e410a176fc444
parent6f821a63b5d40b01c216e6919a3f5e0dfb0c8d82 (diff)
downloadchrome-ec-891aef19bb73822b5ec6c7ee088f99cf1c793253.tar.gz
dedede: Add initial baseboard skeleton
This commit simply adds the few baseboard files for dedede. It only contains support for the NPCX7 variant boards at the moment. BUG=b:146172102, b:146557556 BRANCH=None TEST=None Change-Id: I714dc44c5f54330f43fa20f31f982ac556eda9b9 Signed-off-by: Aseda Aboagye <aaboagye@google.com> Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/ec/+/1986313 Tested-by: Aseda Aboagye <aaboagye@chromium.org> Auto-Submit: Aseda Aboagye <aaboagye@chromium.org> Reviewed-by: Diana Z <dzigterman@chromium.org> Commit-Queue: Diana Z <dzigterman@chromium.org>
-rw-r--r--baseboard/dedede/baseboard.c8
-rw-r--r--baseboard/dedede/baseboard.h56
-rw-r--r--baseboard/dedede/build.mk9
3 files changed, 73 insertions, 0 deletions
diff --git a/baseboard/dedede/baseboard.c b/baseboard/dedede/baseboard.c
new file mode 100644
index 0000000000..6a626990ca
--- /dev/null
+++ b/baseboard/dedede/baseboard.c
@@ -0,0 +1,8 @@
+/* Copyright 2020 The Chromium OS Authors. All rights reserved.
+ * Use of this source code is governed by a BSD-style license that can be
+ * found in the LICENSE file.
+ */
+
+/* Dedede family-specific configuration */
+
+#include "common.h"
diff --git a/baseboard/dedede/baseboard.h b/baseboard/dedede/baseboard.h
new file mode 100644
index 0000000000..c6a8aedf46
--- /dev/null
+++ b/baseboard/dedede/baseboard.h
@@ -0,0 +1,56 @@
+/* Copyright 2020 The Chromium OS Authors. All rights reserved.
+ * Use of this source code is governed by a BSD-style license that can be
+ * found in the LICENSE file.
+ */
+
+/* Dedede board configuration */
+
+#ifndef __CROS_EC_BASEBOARD_H
+#define __CROS_EC_BASEBOARD_H
+
+/*
+ * By default, enable all console messages excepted HC, ACPI and event:
+ * The sensor stack is generating a lot of activity.
+ */
+#define CC_DEFAULT (CC_ALL & ~(CC_MASK(CC_EVENTS) | CC_MASK(CC_LPC)))
+#define CONFIG_SUPPRESSED_HOST_COMMANDS \
+ EC_CMD_CONSOLE_SNAPSHOT, EC_CMD_CONSOLE_READ, EC_CMD_USB_PD_DISCOVERY,\
+ EC_CMD_USB_PD_POWER_INFO, EC_CMD_PD_GET_LOG_ENTRY, \
+ EC_CMD_MOTION_SENSE_CMD, EC_CMD_GET_NEXT_EVENT
+
+/*
+ * Variant EC defines. Pick one:
+ * VARIANT_DEDEDE_EC_NPCX796FC
+ */
+#ifdef VARIANT_DEDEDE_EC_NPCX796FC
+ /* NPCX7 config */
+ #define NPCX_UART_MODULE2 1 /* GPIO64/65 are used as UART pins. */
+ #define NPCX_TACH_SEL2 0 /* No tach. */
+ #define NPCX7_PWM1_SEL 1 /* GPIO C2 is used as PWM1. */
+
+ /* Internal SPI flash on NPCX7 */
+ #define CONFIG_FLASH_SIZE (512 * 1024)
+ #define CONFIG_SPI_FLASH_REGS
+ #define CONFIG_SPI_FLASH_W25Q80 /* Internal SPI flash type. */
+#else
+#error "Must define a VARIANT_DEDEDE_EC!"
+#endif
+
+/* Common EC defines */
+#define CONFIG_HOSTCMD_ESPI
+#define CONFIG_HOSTCMD_EVENTS
+#define CONFIG_KEYBOARD_PROTOCOL_8042
+#define CONFIG_I2C
+#define CONFIG_VBOOT_HASH
+#define CONFIG_CRC8
+#define CONFIG_CROS_BOARD_INFO
+#define CONFIG_BOARD_VERSION_CBI
+#define CONFIG_LOW_POWER_IDLE
+#define CONFIG_BOARD_HAS_RTC_RESET
+
+#ifndef __ASSEMBLER__
+
+#include "gpio_signal.h"
+
+#endif /* !__ASSEMBLER__ */
+#endif /* __CROS_EC_BASEBOARD_H */
diff --git a/baseboard/dedede/build.mk b/baseboard/dedede/build.mk
new file mode 100644
index 0000000000..bc1b80a1da
--- /dev/null
+++ b/baseboard/dedede/build.mk
@@ -0,0 +1,9 @@
+# -*- makefile -*-
+# Copyright 2020 The Chromium OS Authors. All rights reserved.
+# Use of this source code is governed by a BSD-style license that can be
+# found in the LICENSE file.
+#
+# Baseboard specific files build
+#
+
+baseboard-y=baseboard.o