Angel Pons | 560796c | 2020-04-03 01:22:52 +0200 | [diff] [blame] | 1 | /* SPDX-License-Identifier: GPL-2.0-only */ |
Piotr Król | dcd2f17 | 2016-05-27 12:04:13 +0200 | [diff] [blame] | 2 | |
| 3 | #ifndef GPIO_FTNS_H |
| 4 | #define GPIO_FTNS_H |
| 5 | |
Kyösti Mälkki | c27df87 | 2017-01-16 19:58:53 +0200 | [diff] [blame] | 6 | int get_spd_offset(void); |
Piotr Król | dcd2f17 | 2016-05-27 12:04:13 +0200 | [diff] [blame] | 7 | |
Felix Held | 99c4a29 | 2021-08-04 19:28:45 +0200 | [diff] [blame] | 8 | /* |
| 9 | * Based on PC Engines APU2C and APU3A schematics |
| 10 | * http://www.pcengines.ch/schema/apu2c.pdf |
| 11 | * http://www.pcengines.ch/schema/apu3a.pdf |
| 12 | * Beware that the GPIO pin numbers on the package don't match the internal GPIO numbers |
| 13 | */ |
Kyösti Mälkki | 7051a40 | 2020-06-01 09:37:05 +0300 | [diff] [blame] | 14 | #define GPIO_22 0x09 // MODESW (APU5) |
| 15 | #define GPIO_32 0x59 // MODESW (SIMSWAP2 on APU5) |
| 16 | #define GPIO_33 0x5A // SIMSWAP (SIMSWAP3 on APU5) |
| 17 | #define GPIO_49 0x40 // STRAP0 |
| 18 | #define GPIO_50 0x41 // STRAP1 |
| 19 | #define GPIO_51 0x42 // PE3 Reset (SIM1 Reset on APU5) |
| 20 | #define GPIO_55 0x43 // PE4 Reset (SIM2 Reset on APU5) |
| 21 | #define GPIO_57 0x44 // LED1# |
| 22 | #define GPIO_58 0x45 // LED2# |
| 23 | #define GPIO_59 0x46 // LED3# |
| 24 | #define GPIO_64 0x47 // PE3_WDIS (SIM3 Reset on APU5) |
| 25 | #define GPIO_66 0x5B // SPKR |
| 26 | #define GPIO_68 0x48 // PE4_WDIS (SIMSWAP1 on APU5) |
| 27 | #define GPIO_71 0x4D // PROCHOT |
Piotr Król | dcd2f17 | 2016-05-27 12:04:13 +0200 | [diff] [blame] | 28 | |
Felix Held | 2909b48 | 2021-08-05 19:43:48 +0200 | [diff] [blame] | 29 | #define GPIO_22_IOMUX_GPIOxx 0 |
| 30 | #define GPIO_32_IOMUX_GPIOxx 0 |
| 31 | #define GPIO_33_IOMUX_GPIOxx 0 |
| 32 | #define GPIO_49_IOMUX_GPIOxx 2 |
| 33 | #define GPIO_50_IOMUX_GPIOxx 2 |
| 34 | #define GPIO_51_IOMUX_GPIOxx 2 |
| 35 | #define GPIO_55_IOMUX_GPIOxx 3 |
| 36 | #define GPIO_57_IOMUX_GPIOxx 1 |
| 37 | #define GPIO_58_IOMUX_GPIOxx 1 |
| 38 | #define GPIO_59_IOMUX_GPIOxx 3 |
| 39 | #define GPIO_64_IOMUX_GPIOxx 2 |
| 40 | #define GPIO_68_IOMUX_GPIOxx 0 |
| 41 | #define GPIO_71_IOMUX_GPIOxx 0 |
| 42 | |
Piotr Król | dcd2f17 | 2016-05-27 12:04:13 +0200 | [diff] [blame] | 43 | #endif /* GPIO_FTNS_H */ |