coreboot
coreboot is an Open Source project aimed at replacing the proprietary BIOS found in most computers.
gpio.c File Reference
#include <baseboard/gpio.h>
#include <baseboard/variants.h>
#include <boardid.h>
#include <commonlib/helpers.h>
#include <soc/gpio.h>
Include dependency graph for gpio.c:

Go to the source code of this file.

Functions

const struct pad_configvariant_gpio_override_table (size_t *num)
 
const struct pad_configvariant_early_gpio_table (size_t *num)
 
const struct pad_configvariant_romstage_gpio_table (size_t *num)
 

Variables

static const struct pad_config board_id0_overrides []
 
static const struct pad_config early_gpio_table []
 
static const struct pad_config romstage_gpio_table []
 

Function Documentation

◆ variant_early_gpio_table()

const struct pad_config* variant_early_gpio_table ( size_t num)

Definition at line 76 of file gpio.c.

References ARRAY_SIZE, and early_gpio_table.

◆ variant_gpio_override_table()

const struct pad_config* variant_gpio_override_table ( size_t num)

Definition at line 64 of file gpio.c.

References ARRAY_SIZE, board_id(), board_id0_overrides, BOARD_ID_UNKNOWN, and NULL.

Here is the call graph for this function:

◆ variant_romstage_gpio_table()

const struct pad_config* variant_romstage_gpio_table ( size_t num)

Definition at line 83 of file gpio.c.

References ARRAY_SIZE, and romstage_gpio_table.

Variable Documentation

◆ board_id0_overrides

const struct pad_config board_id0_overrides[]
static
Initial value:
= {
PAD_CFG_NF(GPP_R4, NONE, DEEP, NF2),
PAD_CFG_NF(GPP_R5, NONE, DEEP, NF2),
PAD_CFG_NF(GPP_R6, NONE, DEEP, NF2),
PAD_CFG_NF(GPP_S2, NONE, DEEP, NF2),
PAD_CFG_NF(GPP_S3, NONE, DEEP, NF2),
PAD_CFG_NF(GPP_S6, NONE, DEEP, NF2),
PAD_CFG_NF(GPP_S7, NONE, DEEP, NF2),
}
#define GPP_R4
#define GPP_R7
#define GPP_S0
#define GPP_R6
#define GPP_S7
#define GPP_S3
#define GPP_S1
#define GPP_S6
#define GPP_R5
#define GPP_S2
#define PAD_NC(pin)
Definition: gpio_defs.h:263
#define PAD_CFG_NF(pad, pull, rst, func)
Definition: gpio_defs.h:197

Definition at line 1 of file gpio.c.

Referenced by variant_gpio_override_table().

◆ early_gpio_table

const struct pad_config early_gpio_table[]
static
Initial value:
= {
PAD_CFG_GPO(GPP_F12, 0, DEEP),
PAD_CFG_GPO(GPP_H12, 0, DEEP),
PAD_CFG_GPI_APIC(GPP_A13, NONE, PLTRST, LEVEL, INVERT),
PAD_CFG_GPO(GPP_D6, 1, DEEP),
PAD_CFG_NF(GPP_H4, NONE, DEEP, NF1),
PAD_CFG_NF(GPP_H5, NONE, DEEP, NF1),
PAD_CFG_NF(GPP_H10, NONE, DEEP, NF2),
PAD_CFG_NF(GPP_H11, NONE, DEEP, NF2),
PAD_CFG_GPO(GPP_H13, 1, DEEP),
}
#define GPP_F12
#define GPP_H11
#define GPP_D6
#define GPP_H12
#define GPP_H13
#define GPP_H5
#define GPP_A13
#define GPP_F18
#define GPP_H10
#define GPP_E12
#define GPP_H4
#define PAD_CFG_GPI(pad, pull, rst)
Definition: gpio_defs.h:284
#define PAD_CFG_GPI_APIC(pad, pull, rst, trig, inv)
Definition: gpio_defs.h:376
#define PAD_CFG_GPO(pad, val, rst)
Definition: gpio_defs.h:247
#define PAD_CFG_GPI_GPIO_DRIVER(pad, pull, rst)
Definition: gpio_defs.h:323

Definition at line 1 of file gpio.c.

Referenced by variant_early_gpio_table().

◆ romstage_gpio_table

const struct pad_config romstage_gpio_table[]
static
Initial value:
= {
PAD_CFG_GPO(GPP_H12, 1, DEEP),
}

Definition at line 1 of file gpio.c.

Referenced by variant_romstage_gpio_table().