summaryrefslogtreecommitdiff
path: root/board/ryu_sh_loader/gpio.inc
blob: d4c9e850543c54f8e5c380a0847845b4a01e269b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
/* -*- mode:c -*-
 *
 * Copyright (c) 2014 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.
 */

/* Interrupts */
GPIO_INT(AP_IN_SUSPEND,        E, 9,  GPIO_INT_BOTH,                   power_signal_interrupt)

/* Outputs */
GPIO(SH_EC_SIGNAL,         A, 7,  GPIO_OUT_LOW)
GPIO(SH_IRQ_L,             A, 11, GPIO_OUT_LOW)

/* Inputs */
GPIO(LID_CLOSED,           A,  2, GPIO_INPUT)
GPIO(BASE_PRESENT,         A,  3, GPIO_INPUT)

#if 0
/* Alternate functions */
GPIO(UART_TX,              A,  9, GPIO_OUT_LOW)
GPIO(UART_RX,              A, 10, GPIO_OUT_LOW)
#endif

/* Needed to bypass flash write protection */
UNIMPLEMENTED(ENTERING_RW)
UNIMPLEMENTED(WP)

/*
 * I2C pins should be configured as inputs until I2C module is
 * initialized. This will avoid driving the lines unintentionally.
 */
GPIO(SLAVE_I2C_SCL,        B,  6, GPIO_INPUT)
GPIO(SLAVE_I2C_SDA,        B,  7, GPIO_INPUT)

ALTERNATE(A, 0x0600, 1, MODULE_UART,   0) /* USART1: PA9/PA10 */
ALTERNATE(B, 0x00C0, 1, MODULE_I2C,    0) /* I2C SLAVE:PB6/7 */