coreboot
coreboot is an Open Source project aimed at replacing the proprietary BIOS found in most computers.
gpio.h
Go to the documentation of this file.
1 /* SPDX-License-Identifier: GPL-2.0-only */
2 
3 #ifndef CARRIER_GPIO_H
4 #define CARRIER_GPIO_H
5 
6 #include <gpio.h>
7 
8 /*
9  * Bidirectional GPIO port when both RX and TX buffer is enabled
10  * TODO: move this macros to src/soc/intel/common/block/include/intelblocks/gpio_defs.h
11  */
12 #ifndef PAD_CFG_GPIO_BIDIRECT_IOS
13 #define PAD_CFG_GPIO_BIDIRECT_IOS(pad, val, pull, rst, trig, iosstate, iosterm, own) \
14  _PAD_CFG_STRUCT(pad, \
15  PAD_FUNC(GPIO) | PAD_RESET(rst) | PAD_TRIG(trig) | \
16  PAD_BUF(NO_DISABLE) | val, \
17  PAD_PULL(pull) | PAD_CFG_OWN_GPIO(own) | \
18  PAD_IOSSTATE(iosstate) | PAD_IOSTERM(iosterm))
19 #endif
20 
21 #ifndef PAD_CFG_GPIO_BIDIRECT
22 #define PAD_CFG_GPIO_BIDIRECT(pad, val, pull, rst, trig, own) \
23  _PAD_CFG_STRUCT(pad, \
24  PAD_FUNC(GPIO) | PAD_RESET(rst) | PAD_TRIG(trig) | \
25  PAD_BUF(NO_DISABLE) | val, \
26  PAD_PULL(pull) | PAD_CFG_OWN_GPIO(own))
27 #endif
28 
29 void carrier_gpio_configure(void);
30 
31 #endif /* CARRIER_GPIO_H */
void carrier_gpio_configure(void)
Definition: gpio.c:264