summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Hendricks <dhendrix@chromium.org>2012-09-05 13:34:17 -0700
committerGerrit <chrome-bot@google.com>2012-09-05 14:38:12 -0700
commit95aa023645ebc5a86e69cc9c870a850af2bf1dc8 (patch)
tree5f32ee014d2568f68ef57533362afe531298c61f
parentb2e4b8c45c443c292ff9cad911ce9ee77487dad3 (diff)
downloadchrome-ec-95aa023645ebc5a86e69cc9c870a850af2bf1dc8.tar.gz
daisy: add GPIO_I2C_* pins to board header and GPIO table
This adds the I2C pins to the listing of Daisy GPIOs. This allows us to use GPIO_I2C_* for shared Daisy/Snow code. BRANCH=snow BUG=none TEST=compile tested for Daisy and Snow Signed-off-by: David Hendricks <dhendrix@chromium.org> Change-Id: I7413921b2dbe3f8cd79c88ab4bfc8ace0d72bd56 Reviewed-on: https://gerrit.chromium.org/gerrit/32261 Commit-Ready: David Hendricks <dhendrix@chromium.org> Tested-by: David Hendricks <dhendrix@chromium.org> Reviewed-by: Doug Anderson <dianders@chromium.org>
-rw-r--r--board/daisy/board.c9
-rw-r--r--board/daisy/board.h4
2 files changed, 12 insertions, 1 deletions
diff --git a/board/daisy/board.c b/board/daisy/board.c
index 7a2a0083f2..2d09a79a04 100644
--- a/board/daisy/board.c
+++ b/board/daisy/board.c
@@ -64,7 +64,14 @@ const struct gpio_info gpio_list[GPIO_COUNT] = {
/* Other inputs */
{"AC_PWRBTN_L", GPIO_A, (1<<0), GPIO_INT_BOTH, NULL},
{"SPI1_NSS", GPIO_A, (1<<4), GPIO_PULL_UP, NULL},
-
+ /*
+ * I2C pins should be configured as inputs until I2C module is
+ * initialized. This will avoid driving the lines unintentionally.
+ */
+ {"I2C1_SCL", GPIO_B, (1<<6), GPIO_INPUT, NULL},
+ {"I2C1_SDA", GPIO_B, (1<<7), GPIO_INPUT, NULL},
+ {"I2C2_SCL", GPIO_B, (1<<10), GPIO_INPUT, NULL},
+ {"I2C2_SDA", GPIO_B, (1<<11), GPIO_INPUT, NULL},
/* Outputs */
{"AC_STATUS", GPIO_A, (1<<5), GPIO_OUT_HIGH, NULL},
{"SPI1_MISO", GPIO_A, (1<<6), GPIO_OUT_HIGH, NULL},
diff --git a/board/daisy/board.h b/board/daisy/board.h
index 887df7e758..91d7ed473f 100644
--- a/board/daisy/board.h
+++ b/board/daisy/board.h
@@ -71,6 +71,10 @@ enum gpio_signal {
/* Other inputs */
GPIO_AC_PWRBTN_L,
GPIO_SPI1_NSS,
+ GPIO_I2C1_SCL,
+ GPIO_I2C1_SDA,
+ GPIO_I2C2_SCL,
+ GPIO_I2C2_SDA,
/* Outputs */
GPIO_AC_STATUS,
GPIO_SPI1_MISO,