diff options
Diffstat (limited to 'board/nocturne_fp/gpio_rw.inc')
-rw-r--r-- | board/nocturne_fp/gpio_rw.inc | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/board/nocturne_fp/gpio_rw.inc b/board/nocturne_fp/gpio_rw.inc new file mode 100644 index 0000000000..a2032271bc --- /dev/null +++ b/board/nocturne_fp/gpio_rw.inc @@ -0,0 +1,38 @@ +/* + * Copyright 2021 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. + */ + +#ifndef SECTION_IS_RW +#error "This file should only be included in RW." +#endif + +/* Interrupts */ +GPIO_INT(FPS_INT, PIN(A, 0), GPIO_INT_RISING, fps_event) +GPIO_INT(PCH_SLP_S0_L, PIN(D,13), GPIO_INT_BOTH, slp_event) +GPIO_INT(PCH_SLP_S3_L, PIN(A,11), GPIO_INT_BOTH, slp_event) + +#ifdef APPLY_RESET_LOOP_FIX +GPIO_INT(WP, PIN(B, 7), GPIO_INT_BOTH, wp_event) +#endif + +/* Inputs */ +/* + * The S4 and SUS sleep lines are unused in code, but are maintained in this + * gpio list to ensure that they are not repurposed. This is because these + * inputs are driven on nocturne. + */ +GPIO(PCH_SLP_S4_L, PIN(D, 8), GPIO_INPUT) +GPIO(PCH_SLP_SUS_L, PIN(D, 3), GPIO_INPUT) +/* TODO(b/178808871): Only enable pull up when doing detection. */ +GPIO(FP_SPI_SEL, PIN(E, 1), GPIO_INPUT | GPIO_PULL_UP) + +/* Outputs */ +GPIO(DIVIDER_HIGHSIDE, PIN(B, 8), GPIO_OUT_LOW) +GPIO(FP_RST_ODL, PIN(E, 0), GPIO_OUT_HIGH) +GPIO(SPI4_NSS, PIN(E, 4), GPIO_OUT_HIGH) +GPIO(USER_PRES_L, PIN(C, 5), GPIO_ODR_HIGH) + +/* SPI4 master to sensor: PE2/5/6 (CLK/MISO/MOSI) */ +ALTERNATE(PIN_MASK(E, 0x0064), GPIO_ALT_SPI, MODULE_SPI_MASTER, 0) |