Jonathon Hall | a86704a | 2023-09-14 14:41:20 -0400 | [diff] [blame^] | 1 | /* SPDX-License-Identifier: GPL-2.0-only */ |
| 2 | |
| 3 | #include <bootblock_common.h> |
| 4 | #include <console/console.h> |
| 5 | #include <delay.h> |
| 6 | #include <device/pci_ops.h> |
| 7 | #include <ec/acpi/ec.h> |
| 8 | #include <gpio.h> |
| 9 | #include <soc/pci_devs.h> |
| 10 | |
| 11 | static const struct pad_config early_gpio_table[] = { |
| 12 | PAD_CFG_NF(GPP_C20, NONE, DEEP, NF1), /* UART2_RXD */ |
| 13 | PAD_CFG_NF(GPP_C21, NONE, DEEP, NF1), /* UART2_TXD */ |
| 14 | }; |
| 15 | |
| 16 | void bootblock_mainboard_early_init(void) |
| 17 | { |
| 18 | gpio_configure_pads(early_gpio_table, ARRAY_SIZE(early_gpio_table)); |
| 19 | } |
| 20 | |
| 21 | void bootblock_mainboard_init(void) |
| 22 | { |
| 23 | /* |
| 24 | * Ensure the panel is powered on. ACPI _PTS disables it, if the system |
| 25 | * is powered up again we need to turn it on. |
| 26 | */ |
| 27 | ec_write(0xa3, 0); |
| 28 | } |