| 1 |
|
| 2 |
|
| 3 |
#include <baseboard/variants.h> |
| 4 |
#include <bootstate.h> |
| 5 |
#include <console/console.h> |
| 6 |
#include <fw_config.h> |
| 7 |
#include <gpio.h> |
| 8 |
|
| 9 |
#define GPIO_PADBASED_OVERRIDE(b, a) gpio_padbased_override(b, a, ARRAY_SIZE(a)) |
| 10 |
|
| 11 |
static const struct pad_config fp_disable_pads[] = { |
| 12 |
|
| 13 |
PAD_NC(GPP_B11, NONE), |
| 14 |
|
| 15 |
PAD_NC(GPP_C22, NONE), |
| 16 |
|
| 17 |
PAD_NC(GPP_C23, NONE), |
| 18 |
|
| 19 |
PAD_NC(GPP_E10, NONE), |
| 20 |
|
| 21 |
PAD_NC(GPP_F11, NONE), |
| 22 |
|
| 23 |
PAD_NC(GPP_F12, NONE), |
| 24 |
|
| 25 |
PAD_NC(GPP_F13, NONE), |
| 26 |
|
| 27 |
PAD_NC(GPP_F17, NONE), |
| 28 |
}; |
| 29 |
|
| 30 |
void fw_config_gpio_padbased_override(struct pad_config *padbased_table) |
| 31 |
{ |
| 32 |
if (fw_config_probe(FW_CONFIG(FP_MCU, FP_MCU_ABSENT))) { |
| 33 |
printk(BIOS_INFO, "Configure GPIOs for no FP module.\n"); |
| 34 |
GPIO_PADBASED_OVERRIDE(padbased_table, fp_disable_pads); |
| 35 |
} |
| 36 |
} |