diff options
author | Anton Staaf <robotboy@chromium.org> | 2016-02-22 10:53:33 -0800 |
---|---|---|
committer | chrome-bot <chrome-bot@chromium.org> | 2016-02-22 23:50:52 -0800 |
commit | 0a644a91250671bb20a7815105ec532b42da19c1 (patch) | |
tree | a6871aa61a82970b8cf716c7a64c6d0f3fc73705 /board/llama | |
parent | 74615c1011382d930f3c4be72ec043ad35856b95 (diff) | |
download | chrome-ec-0a644a91250671bb20a7815105ec532b42da19c1.tar.gz |
GPIO: Move definitions of GPIO_KB_INPUT and OUTPUT
Previously these were often done in board.c files, which made it
impossible to include the gpio.inc anywhere else. As part of
refactoring the GPIO code we now need to be able to include gpio.inc
from common/gpio.c. Moving these defines into gpio.inc makes them
available wherever gpio.inc is included.
Signed-off-by: Anton Staaf <robotboy@chromium.org>
BRANCH=None
BUG=None
TEST=make buildall -j
Change-Id: I28e7b5a1d40b113ae824b18f020b2d1e51e0c08a
Reviewed-on: https://chromium-review.googlesource.com/328822
Commit-Ready: Anton Staaf <robotboy@chromium.org>
Tested-by: Anton Staaf <robotboy@chromium.org>
Reviewed-by: Bill Richardson <wfrichar@chromium.org>
Diffstat (limited to 'board/llama')
-rw-r--r-- | board/llama/board.c | 3 | ||||
-rw-r--r-- | board/llama/gpio.inc | 3 |
2 files changed, 3 insertions, 3 deletions
diff --git a/board/llama/board.c b/board/llama/board.c index a8e422b4f9..625f53cdb2 100644 --- a/board/llama/board.c +++ b/board/llama/board.c @@ -27,9 +27,6 @@ #define CPRINTS(format, args...) cprints(CC_CHIPSET, format, ## args) #define CPRINTF(format, args...) cprintf(CC_CHIPSET, format, ## args) -#define GPIO_KB_INPUT (GPIO_INPUT | GPIO_PULL_UP | GPIO_INT_BOTH) -#define GPIO_KB_OUTPUT GPIO_ODR_HIGH - #include "gpio_list.h" /* power signal list. Must match order of enum power_signal. */ diff --git a/board/llama/gpio.inc b/board/llama/gpio.inc index d49812445e..12e400c916 100644 --- a/board/llama/gpio.inc +++ b/board/llama/gpio.inc @@ -13,6 +13,9 @@ GPIO_INT(LID_OPEN, PIN(C, 13), GPIO_INT_BOTH, lid_interru GPIO_INT(SUSPEND_L, PIN(C, 7), GPIO_INT_BOTH, power_signal_interrupt) /* AP suspend/resume state */ /* Keyboard inputs */ +#define GPIO_KB_INPUT (GPIO_INPUT | GPIO_PULL_UP | GPIO_INT_BOTH) +#define GPIO_KB_OUTPUT GPIO_ODR_HIGH + GPIO_INT(KB_IN00, PIN(C, 8), GPIO_KB_INPUT, keyboard_raw_gpio_interrupt) GPIO_INT(KB_IN01, PIN(C, 9), GPIO_KB_INPUT, keyboard_raw_gpio_interrupt) GPIO_INT(KB_IN02, PIN(C, 10), GPIO_KB_INPUT, keyboard_raw_gpio_interrupt) |