summaryrefslogtreecommitdiff
path: root/board/bds
diff options
context:
space:
mode:
authorRandall Spangler <rspangler@chromium.org>2013-05-21 11:03:29 -0700
committerChromeBot <chrome-bot@google.com>2013-05-23 11:08:44 -0700
commita1006865e7f695ddd1c730cc9c6c6a6f109c43b9 (patch)
tree70f68e84e2340b7bf4210de177ee000ece27fda0 /board/bds
parentbd8fec9bae8fc36cc1e46bf0417f2da00530b522 (diff)
downloadchrome-ec-a1006865e7f695ddd1c730cc9c6c6a6f109c43b9.tar.gz
Move write protect GPIO handling to flash module
Write protect signal naming is now consistent across boards. New CONFIG_WP_ACTIVE_HIGH is present on systems where the write protect signal is active-high (e.g. Link). This will be used in the next CL, which moves flash_get_protect() to flash_common.c BUG=chrome-os-partner:15613 BRANCH=none TEST=flashinfo properly reports WP signal status Change-Id: I502ab033c3eb36661cc3ee97320874b3fbf6fc0d Signed-off-by: Randall Spangler <rspangler@chromium.org> Reviewed-on: https://gerrit.chromium.org/gerrit/56087 Reviewed-by: Vic Yang <victoryang@chromium.org>
Diffstat (limited to 'board/bds')
-rw-r--r--board/bds/board.c2
-rw-r--r--board/bds/board.h5
2 files changed, 5 insertions, 2 deletions
diff --git a/board/bds/board.c b/board/bds/board.c
index 92372437a5..d0808f4f37 100644
--- a/board/bds/board.c
+++ b/board/bds/board.c
@@ -43,6 +43,6 @@ const struct gpio_info gpio_list[GPIO_COUNT] = {
{"RECOVERYn", LM4_GPIO_D, (1<<1), GPIO_PULL_UP, NULL},
{"DEBUG_LED", LM4_GPIO_A, (1<<7), GPIO_OUT_LOW, NULL},
/* Unimplemented signals which we need to emulate for now */
- GPIO_SIGNAL_NOT_IMPLEMENTED("WRITE_PROTECT"),
+ GPIO_SIGNAL_NOT_IMPLEMENTED("WP"),
GPIO_SIGNAL_NOT_IMPLEMENTED("ENTERING_RW"),
};
diff --git a/board/bds/board.h b/board/bds/board.h
index 770269a9b4..0abb267637 100644
--- a/board/bds/board.h
+++ b/board/bds/board.h
@@ -21,6 +21,9 @@
#define CONFIG_EOPTION
#define CONFIG_PSTORE
+/* Write protect is active high */
+#define CONFIG_WP_ACTIVE_HIGH
+
#ifndef __ASSEMBLER__
enum adc_channel
@@ -46,7 +49,7 @@ enum gpio_signal {
GPIO_DEBUG_LED, /* Debug LED */
/* Signals which aren't implemented on BDS but we'll emulate anyway, to
* make it more convenient to debug other code. */
- GPIO_WRITE_PROTECT, /* Write protect input */
+ GPIO_WP, /* Write protect input */
GPIO_ENTERING_RW, /* EC entering RW code */
/* Number of GPIOs; not an actual GPIO */