diff options
author | Michał Żygowski <michal.zygowski@3mdeb.com> | 2018-07-27 15:59:51 +0200 |
---|---|---|
committer | Felix Held <felix-coreboot@felixheld.de> | 2018-08-04 15:19:01 +0000 |
commit | a4432f469a97b4279cb53b79acd5c835e0880981 (patch) | |
tree | b2fd8eda0e9028aac9325aee6ba3c569a7cfbf46 /src/mainboard/pcengines/apu2/gpio_ftns.h | |
parent | 6838aaebf9ec836a13d57bd85bc0e7e396834e8b (diff) | |
download | coreboot-a4432f469a97b4279cb53b79acd5c835e0880981.tar.xz |
mb/pcengines/apu2: change GPIO setting
Change GPIO setting to use IOMUX to refer to GPIO by
IOMUX register as in BKDG for Family 16h Models 30h-3fh
Processor Rev 3.06.
Change-Id: Icf4a60acabe65cd7f9985bb3af8bd577764d4196
Signed-off-by: Michał Żygowski <michal.zygowski@3mdeb.com>
Reviewed-on: https://review.coreboot.org/27665
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Reviewed-by: Felix Held <felix-coreboot@felixheld.de>
Diffstat (limited to 'src/mainboard/pcengines/apu2/gpio_ftns.h')
-rw-r--r-- | src/mainboard/pcengines/apu2/gpio_ftns.h | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/src/mainboard/pcengines/apu2/gpio_ftns.h b/src/mainboard/pcengines/apu2/gpio_ftns.h index e08ee7bcac..05f54148c4 100644 --- a/src/mainboard/pcengines/apu2/gpio_ftns.h +++ b/src/mainboard/pcengines/apu2/gpio_ftns.h @@ -16,7 +16,7 @@ #ifndef GPIO_FTNS_H #define GPIO_FTNS_H -void configure_gpio(uintptr_t base_addr, u32 iomux_gpio, u8 iomux_ftn, u32 gpio, u32 setting); +void configure_gpio(u32 iomux_gpio, u8 iomux_ftn, u32 gpio, u32 setting); int get_spd_offset(void); #define IOMUX_OFFSET 0xD00 @@ -27,6 +27,7 @@ int get_spd_offset(void); // http://www.pcengines.ch/schema/apu2c.pdf // http://www.pcengines.ch/schema/apu3a.pdf // +#define IOMUX_GPIO_22 0x09 // MODESW (APU5) #define IOMUX_GPIO_32 0x59 // MODESW (SIMSWAP2 on APU5) #define IOMUX_GPIO_33 0x5A // SIMSWAP (SIMSWAP3 on APU5) #define IOMUX_GPIO_49 0x40 // STRAP0 @@ -41,6 +42,7 @@ int get_spd_offset(void); #define IOMUX_GPIO_68 0x48 // PE4_WDIS (SIMSWAP1 on APU5) #define IOMUX_GPIO_71 0x4D // PROCHOT +#define GPIO_22 0x24 // MODESW (APU5) #define GPIO_32 0x164 // MODESW (SIMSWAP2 on APU5) #define GPIO_33 0x168 // SIMSWAP (SIMSWAP3 on APU5) #define GPIO_49 0x100 // STRAP0 @@ -55,9 +57,10 @@ int get_spd_offset(void); #define GPIO_68 0x120 // PE4_WDIS (SIMSWAP1 on APU5) #define GPIO_71 0x134 // PROCHOT -#define GPIO_OUTPUT_ENABLE 23 -#define GPIO_OUTPUT_VALUE 22 -#define GPIO_PULL_DOWN_ENABLE 21 -#define GPIO_PULL_UP_ENABLE 20 +#define GPIO_OUTPUT_ENABLE BIT23 +#define GPIO_OUTPUT_VALUE BIT22 +#define GPIO_PULL_DOWN_ENABLE BIT21 +#define GPIO_PULL_UP_ENABLE BIT20 +#define GPIO_PIN_STS BIT16 #endif /* GPIO_FTNS_H */ |