Sean Rhodes | 5da05b6 | 2022-01-10 21:58:04 +0000 | [diff] [blame] | 1 | /* SPDX-License-Identifier: GPL-2.0-only */ |
| 2 | |
| 3 | #include <bootblock_common.h> |
Sean Rhodes | ae64b6e | 2022-06-14 12:29:40 +0100 | [diff] [blame] | 4 | #include <intelblocks/lpc_lib.h> |
Elyes Haouas | 9f599c2 | 2024-06-04 10:25:05 +0200 | [diff] [blame^] | 5 | #include <gpio.h> |
Sean Rhodes | 5da05b6 | 2022-01-10 21:58:04 +0000 | [diff] [blame] | 6 | #include <variants.h> |
| 7 | |
| 8 | void bootblock_mainboard_init(void) |
| 9 | { |
| 10 | const struct pad_config *pads; |
| 11 | size_t num; |
| 12 | |
| 13 | pads = variant_early_gpio_table(&num); |
| 14 | gpio_configure_pads(pads, num); |
Sean Rhodes | ae64b6e | 2022-06-14 12:29:40 +0100 | [diff] [blame] | 15 | |
| 16 | if (CONFIG(EC_STARLABS_NUVOTON)) |
| 17 | lpc_open_mmio_window(0xfe800000, 0x10000); |
Sean Rhodes | 5da05b6 | 2022-01-10 21:58:04 +0000 | [diff] [blame] | 18 | } |