summaryrefslogtreecommitdiff
path: root/board/falco/board.c
diff options
context:
space:
mode:
Diffstat (limited to 'board/falco/board.c')
-rw-r--r--board/falco/board.c102
1 files changed, 1 insertions, 101 deletions
diff --git a/board/falco/board.c b/board/falco/board.c
index 97a7fccc53..a9eeee7723 100644
--- a/board/falco/board.c
+++ b/board/falco/board.c
@@ -31,107 +31,7 @@
#include "uart.h"
#include "util.h"
-/* GPIO signal list. Must match order from enum gpio_signal. */
-const struct gpio_info gpio_list[] = {
- /* Inputs with interrupt handlers are first for efficiency */
- {"POWER_BUTTON_L", LM4_GPIO_A, (1<<2), GPIO_INT_BOTH_DSLEEP,
- power_button_interrupt},
- {"LID_OPEN", LM4_GPIO_A, (1<<3), GPIO_INT_BOTH_DSLEEP,
- lid_interrupt},
- {"AC_PRESENT", LM4_GPIO_H, (1<<3), GPIO_INT_BOTH_DSLEEP,
- extpower_interrupt},
- {"PCH_BKLTEN", LM4_GPIO_M, (1<<3), GPIO_INT_BOTH,
- backlight_interrupt},
- {"PCH_SLP_S0_L", LM4_GPIO_G, (1<<6), GPIO_INT_BOTH,
- power_signal_interrupt},
- {"PCH_SLP_S3_L", LM4_GPIO_G, (1<<7), GPIO_INT_BOTH_DSLEEP,
- power_signal_interrupt},
- {"PCH_SLP_S5_L", LM4_GPIO_H, (1<<1), GPIO_INT_BOTH_DSLEEP,
- power_signal_interrupt},
- {"PCH_SLP_SUS_L", LM4_GPIO_G, (1<<3), GPIO_INT_BOTH,
- power_signal_interrupt},
- {"PP1050_PGOOD", LM4_GPIO_H, (1<<4), GPIO_INT_BOTH,
- power_signal_interrupt},
- {"PP1350_PGOOD", LM4_GPIO_H, (1<<6), GPIO_INT_BOTH,
- power_signal_interrupt},
- {"PP5000_PGOOD", LM4_GPIO_N, (1<<0), GPIO_INT_BOTH,
- power_signal_interrupt},
- {"VCORE_PGOOD", LM4_GPIO_C, (1<<6), GPIO_INT_BOTH,
- power_signal_interrupt},
- {"PCH_EDP_VDD_EN", LM4_GPIO_J, (1<<1), GPIO_INT_BOTH,
- lcdvcc_interrupt},
- {"RECOVERY_L", LM4_GPIO_A, (1<<5), GPIO_PULL_UP|GPIO_INT_BOTH,
- switch_interrupt},
- {"WP_L", LM4_GPIO_A, (1<<4), GPIO_INT_BOTH,
- switch_interrupt},
- {"JTAG_TCK", LM4_GPIO_C, (1<<0), GPIO_DEFAULT,
- jtag_interrupt},
- {"UART0_RX", LM4_GPIO_A, (1<<0), GPIO_PULL_UP|
- GPIO_INT_BOTH_DSLEEP,
- uart_deepsleep_interrupt},
-
- /* Other inputs */
- {"FAN_ALERT_L", LM4_GPIO_B, (1<<0), GPIO_INPUT, NULL},
- {"PCH_SUSWARN_L", LM4_GPIO_G, (1<<2), GPIO_INT_BOTH, NULL},
- {"USB1_OC_L", LM4_GPIO_E, (1<<7), GPIO_INPUT, NULL},
- {"USB2_OC_L", LM4_GPIO_E, (1<<0), GPIO_INPUT, NULL},
- {"BOARD_VERSION1", LM4_GPIO_Q, (1<<5), GPIO_INPUT, NULL},
- {"BOARD_VERSION2", LM4_GPIO_Q, (1<<6), GPIO_INPUT, NULL},
- {"BOARD_VERSION3", LM4_GPIO_Q, (1<<7), GPIO_INPUT, NULL},
- {"CPU_PGOOD", LM4_GPIO_C, (1<<4), GPIO_INPUT, NULL},
-
- /* Outputs; all unasserted by default except for reset signals */
- {"CPU_PROCHOT", LM4_GPIO_B, (1<<1), GPIO_OUT_LOW, NULL},
- {"PP1350_EN", LM4_GPIO_H, (1<<5), GPIO_OUT_LOW, NULL},
- {"PP3300_DSW_GATED_EN", LM4_GPIO_J, (1<<3), GPIO_OUT_LOW, NULL},
- {"PP3300_DX_EN", LM4_GPIO_J, (1<<2), GPIO_OUT_LOW, NULL},
- {"PP3300_LTE_EN", LM4_GPIO_D, (1<<2), GPIO_OUT_LOW, NULL},
- {"PP3300_WLAN_EN", LM4_GPIO_J, (1<<0), GPIO_OUT_LOW, NULL},
- {"SUSP_VR_EN", LM4_GPIO_C, (1<<7), GPIO_OUT_LOW, NULL},
- {"VCORE_EN", LM4_GPIO_C, (1<<5), GPIO_OUT_LOW, NULL},
- {"PP5000_EN", LM4_GPIO_H, (1<<7), GPIO_OUT_LOW, NULL},
- {"SYS_PWROK", LM4_GPIO_H, (1<<2), GPIO_OUT_LOW, NULL},
- {"WLAN_OFF_L", LM4_GPIO_J, (1<<4), GPIO_OUT_LOW, NULL},
- {"CHARGE_L", LM4_GPIO_E, (1<<6), GPIO_OUT_LOW, NULL},
-
- {"ENABLE_BACKLIGHT", LM4_GPIO_M, (1<<7), GPIO_OUT_LOW, NULL},
- {"ENABLE_TOUCHPAD", LM4_GPIO_N, (1<<1), GPIO_OUT_LOW, NULL},
- {"ENTERING_RW", LM4_GPIO_D, (1<<3), GPIO_OUT_LOW, NULL},
- {"PCH_DPWROK", LM4_GPIO_G, (1<<0), GPIO_OUT_LOW, NULL},
- /*
- * HDA_SDO is technically an output, but we need to leave it as an
- * input until we drive it high. So can't use open-drain (HI_Z).
- */
- {"PCH_HDA_SDO", LM4_GPIO_G, (1<<1), GPIO_INPUT, NULL},
- {"PCH_WAKE_L", LM4_GPIO_F, (1<<0), GPIO_OUT_HIGH, NULL},
- {"PCH_NMI_L", LM4_GPIO_F, (1<<2), GPIO_OUT_HIGH, NULL},
- {"PCH_PWRBTN_L", LM4_GPIO_H, (1<<0), GPIO_OUT_HIGH, NULL},
- {"PCH_PWROK", LM4_GPIO_F, (1<<5), GPIO_OUT_LOW, NULL},
- /*
- * PL6 is one of 4 pins on the EC which can't be used in open-drain
- * mode. To work around this PCH_RCIN_L is set to an input. It will
- * only be set to an output when it needs to be driven to 0.
- */
- {"PCH_RCIN_L", LM4_GPIO_L, (1<<6), GPIO_INPUT, NULL},
- {"PCH_RSMRST_L", LM4_GPIO_F, (1<<1), GPIO_OUT_LOW, NULL},
- {"PCH_SMI_L", LM4_GPIO_F, (1<<4), GPIO_ODR_HIGH, NULL},
- {"TOUCHSCREEN_RESET_L", LM4_GPIO_N, (1<<7), GPIO_OUT_LOW, NULL},
- {"EC_EDP_VDD_EN", LM4_GPIO_J, (1<<5), GPIO_OUT_LOW, NULL},
-
- {"LPC_CLKRUN_L", LM4_GPIO_M, (1<<2), GPIO_ODR_HIGH, NULL},
- {"USB1_ENABLE", LM4_GPIO_E, (1<<4), GPIO_OUT_LOW, NULL},
- {"USB2_ENABLE", LM4_GPIO_D, (1<<5), GPIO_OUT_LOW, NULL},
-
- {"PCH_SUSACK_L", LM4_GPIO_F, (1<<3), GPIO_OUT_HIGH, NULL},
- {"PCH_RTCRST_L", LM4_GPIO_F, (1<<6), GPIO_ODR_HIGH, NULL},
- {"PCH_SRTCRST_L", LM4_GPIO_F, (1<<7), GPIO_ODR_HIGH, NULL},
-
- {"PWR_LED_L", LM4_GPIO_N, (1<<6), GPIO_OUT_HIGH, NULL},
- {"KB_LED_EN", LM4_GPIO_D, (1<<4), GPIO_OUT_LOW, NULL},
- {"BAT_LED0", LM4_GPIO_D, (1<<0), GPIO_OUT_LOW, NULL},
- {"BAT_LED1", LM4_GPIO_D, (1<<1), GPIO_OUT_LOW, NULL},
-};
-BUILD_ASSERT(ARRAY_SIZE(gpio_list) == GPIO_COUNT);
+#include "gpio_list.h"
/* Pins with alternate functions */
const struct gpio_alt_func gpio_alt_funcs[] = {