diff options
| -rw-r--r-- | arch/arm/mach-mx1/devices.c | 1 | ||||
| -rw-r--r-- | arch/arm/mach-mx1/mx1ads.c | 2 | ||||
| -rw-r--r-- | arch/arm/mach-mx2/mx27ads.c | 4 | ||||
| -rw-r--r-- | arch/arm/mach-mx2/pcm038.c | 7 | ||||
| -rw-r--r-- | arch/arm/plat-mxc/include/mach/iomux-mx1-mx2.h | 416 | ||||
| -rw-r--r-- | arch/arm/plat-mxc/include/mach/iomux-mx1.h | 166 | ||||
| -rw-r--r-- | arch/arm/plat-mxc/include/mach/iomux-mx21.h | 126 | ||||
| -rw-r--r-- | arch/arm/plat-mxc/include/mach/iomux-mx27.h | 207 | ||||
| -rw-r--r-- | arch/arm/plat-mxc/include/mach/iomux-mx2x.h | 237 | ||||
| -rw-r--r-- | arch/arm/plat-mxc/include/mach/iomux.h | 127 | ||||
| -rw-r--r-- | arch/arm/plat-mxc/iomux-mx1-mx2.c | 2 |
11 files changed, 872 insertions, 423 deletions
diff --git a/arch/arm/mach-mx1/devices.c b/arch/arm/mach-mx1/devices.c index 686d8d2dbb24..cea8f2c71192 100644 --- a/arch/arm/mach-mx1/devices.c +++ b/arch/arm/mach-mx1/devices.c | |||
| @@ -23,6 +23,7 @@ | |||
| 23 | #include <linux/init.h> | 23 | #include <linux/init.h> |
| 24 | #include <linux/platform_device.h> | 24 | #include <linux/platform_device.h> |
| 25 | #include <linux/gpio.h> | 25 | #include <linux/gpio.h> |
| 26 | #include <mach/irqs.h> | ||
| 26 | #include <mach/hardware.h> | 27 | #include <mach/hardware.h> |
| 27 | 28 | ||
| 28 | static struct resource imx_csi_resources[] = { | 29 | static struct resource imx_csi_resources[] = { |
diff --git a/arch/arm/mach-mx1/mx1ads.c b/arch/arm/mach-mx1/mx1ads.c index 2e4b185fe4a9..be7dd75ebbe1 100644 --- a/arch/arm/mach-mx1/mx1ads.c +++ b/arch/arm/mach-mx1/mx1ads.c | |||
| @@ -24,7 +24,7 @@ | |||
| 24 | #include <mach/hardware.h> | 24 | #include <mach/hardware.h> |
| 25 | #include <mach/common.h> | 25 | #include <mach/common.h> |
| 26 | #include <mach/imx-uart.h> | 26 | #include <mach/imx-uart.h> |
| 27 | #include <mach/iomux-mx1-mx2.h> | 27 | #include <mach/iomux.h> |
| 28 | #include "devices.h" | 28 | #include "devices.h" |
| 29 | 29 | ||
| 30 | /* | 30 | /* |
diff --git a/arch/arm/mach-mx2/mx27ads.c b/arch/arm/mach-mx2/mx27ads.c index 2b5c67f54571..7721c470d5ab 100644 --- a/arch/arm/mach-mx2/mx27ads.c +++ b/arch/arm/mach-mx2/mx27ads.c | |||
| @@ -31,7 +31,7 @@ | |||
| 31 | #include <asm/mach/map.h> | 31 | #include <asm/mach/map.h> |
| 32 | #include <mach/gpio.h> | 32 | #include <mach/gpio.h> |
| 33 | #include <mach/imx-uart.h> | 33 | #include <mach/imx-uart.h> |
| 34 | #include <mach/iomux-mx1-mx2.h> | 34 | #include <mach/iomux.h> |
| 35 | #include <mach/board-mx27ads.h> | 35 | #include <mach/board-mx27ads.h> |
| 36 | 36 | ||
| 37 | #include "devices.h" | 37 | #include "devices.h" |
| @@ -196,7 +196,7 @@ static int mxc_fec_pins[] = { | |||
| 196 | PD11_AOUT_FEC_TX_CLK, | 196 | PD11_AOUT_FEC_TX_CLK, |
| 197 | PD12_AOUT_FEC_RXD0, | 197 | PD12_AOUT_FEC_RXD0, |
| 198 | PD13_AOUT_FEC_RX_DV, | 198 | PD13_AOUT_FEC_RX_DV, |
| 199 | PD14_AOUT_FEC_CLR, | 199 | PD14_AOUT_FEC_RX_CLK, |
| 200 | PD15_AOUT_FEC_COL, | 200 | PD15_AOUT_FEC_COL, |
| 201 | PD16_AIN_FEC_TX_ER, | 201 | PD16_AIN_FEC_TX_ER, |
| 202 | PF23_AIN_FEC_TX_EN | 202 | PF23_AIN_FEC_TX_EN |
diff --git a/arch/arm/mach-mx2/pcm038.c b/arch/arm/mach-mx2/pcm038.c index dfd4156da7d5..534fd9a4ff9f 100644 --- a/arch/arm/mach-mx2/pcm038.c +++ b/arch/arm/mach-mx2/pcm038.c | |||
| @@ -20,11 +20,12 @@ | |||
| 20 | #include <linux/platform_device.h> | 20 | #include <linux/platform_device.h> |
| 21 | #include <linux/mtd/physmap.h> | 21 | #include <linux/mtd/physmap.h> |
| 22 | #include <linux/mtd/plat-ram.h> | 22 | #include <linux/mtd/plat-ram.h> |
| 23 | #include <linux/io.h> | ||
| 23 | #include <asm/mach/arch.h> | 24 | #include <asm/mach/arch.h> |
| 24 | #include <asm/mach-types.h> | 25 | #include <asm/mach-types.h> |
| 25 | #include <mach/common.h> | 26 | #include <mach/common.h> |
| 26 | #include <mach/hardware.h> | 27 | #include <mach/hardware.h> |
| 27 | #include <mach/iomux-mx1-mx2.h> | 28 | #include <mach/iomux.h> |
| 28 | #include <asm/mach/time.h> | 29 | #include <asm/mach/time.h> |
| 29 | #include <mach/imx-uart.h> | 30 | #include <mach/imx-uart.h> |
| 30 | #include <mach/board-pcm038.h> | 31 | #include <mach/board-pcm038.h> |
| @@ -170,7 +171,7 @@ static int mxc_fec_pins[] = { | |||
| 170 | PD11_AOUT_FEC_TX_CLK, | 171 | PD11_AOUT_FEC_TX_CLK, |
| 171 | PD12_AOUT_FEC_RXD0, | 172 | PD12_AOUT_FEC_RXD0, |
| 172 | PD13_AOUT_FEC_RX_DV, | 173 | PD13_AOUT_FEC_RX_DV, |
| 173 | PD14_AOUT_FEC_CLR, | 174 | PD14_AOUT_FEC_RX_CLK, |
| 174 | PD15_AOUT_FEC_COL, | 175 | PD15_AOUT_FEC_COL, |
| 175 | PD16_AIN_FEC_TX_ER, | 176 | PD16_AIN_FEC_TX_ER, |
| 176 | PF23_AIN_FEC_TX_EN | 177 | PF23_AIN_FEC_TX_EN |
| @@ -217,7 +218,7 @@ static void __init pcm038_init(void) | |||
| 217 | mxc_register_device(&mxc_uart_device1, &uart_pdata[1]); | 218 | mxc_register_device(&mxc_uart_device1, &uart_pdata[1]); |
| 218 | mxc_register_device(&mxc_uart_device2, &uart_pdata[2]); | 219 | mxc_register_device(&mxc_uart_device2, &uart_pdata[2]); |
| 219 | 220 | ||
| 220 | mxc_gpio_mode(PE16_AF_RTCK); /* OWIRE */ | 221 | mxc_gpio_mode(PE16_AF_OWIRE); |
| 221 | mxc_register_device(&mxc_nand_device, &pcm038_nand_board_info); | 222 | mxc_register_device(&mxc_nand_device, &pcm038_nand_board_info); |
| 222 | 223 | ||
| 223 | platform_add_devices(platform_devices, ARRAY_SIZE(platform_devices)); | 224 | platform_add_devices(platform_devices, ARRAY_SIZE(platform_devices)); |
diff --git a/arch/arm/plat-mxc/include/mach/iomux-mx1-mx2.h b/arch/arm/plat-mxc/include/mach/iomux-mx1-mx2.h deleted file mode 100644 index 95a383be628e..000000000000 --- a/arch/arm/plat-mxc/include/mach/iomux-mx1-mx2.h +++ /dev/null | |||
| @@ -1,416 +0,0 @@ | |||
| 1 | /* | ||
| 2 | * Copyright (C) 2008 by Sascha Hauer <kernel@pengutronix.de> | ||
| 3 | * | ||
| 4 | * This program is free software; you can redistribute it and/or | ||
| 5 | * modify it under the terms of the GNU General Public License | ||
| 6 | * as published by the Free Software Foundation; either version 2 | ||
| 7 | * of the License, or (at your option) any later version. | ||
| 8 | * This program is distributed in the hope that it will be useful, | ||
| 9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 11 | * GNU General Public License for more details. | ||
| 12 | * | ||
| 13 | * You should have received a copy of the GNU General Public License | ||
| 14 | * along with this program; if not, write to the Free Software | ||
| 15 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, | ||
| 16 | * MA 02110-1301, USA. | ||
| 17 | */ | ||
| 18 | |||
| 19 | #ifndef _MXC_GPIO_MX1_MX2_H | ||
| 20 | #define _MXC_GPIO_MX1_MX2_H | ||
| 21 | |||
| 22 | #include <linux/io.h> | ||
| 23 | |||
| 24 | /* | ||
| 25 | * GPIO Module and I/O Multiplexer | ||
| 26 | * x = 0..3 for reg_A, reg_B, reg_C, reg_D | ||
| 27 | */ | ||
| 28 | #define VA_GPIO_BASE IO_ADDRESS(GPIO_BASE_ADDR) | ||
| 29 | #define MXC_DDIR(x) (0x00 + ((x) << 8)) | ||
| 30 | #define MXC_OCR1(x) (0x04 + ((x) << 8)) | ||
| 31 | #define MXC_OCR2(x) (0x08 + ((x) << 8)) | ||
| 32 | #define MXC_ICONFA1(x) (0x0c + ((x) << 8)) | ||
| 33 | #define MXC_ICONFA2(x) (0x10 + ((x) << 8)) | ||
| 34 | #define MXC_ICONFB1(x) (0x14 + ((x) << 8)) | ||
| 35 | #define MXC_ICONFB2(x) (0x18 + ((x) << 8)) | ||
| 36 | #define MXC_DR(x) (0x1c + ((x) << 8)) | ||
| 37 | #define MXC_GIUS(x) (0x20 + ((x) << 8)) | ||
| 38 | #define MXC_SSR(x) (0x24 + ((x) << 8)) | ||
| 39 | #define MXC_ICR1(x) (0x28 + ((x) << 8)) | ||
| 40 | #define MXC_ICR2(x) (0x2c + ((x) << 8)) | ||
| 41 | #define MXC_IMR(x) (0x30 + ((x) << 8)) | ||
| 42 | #define MXC_ISR(x) (0x34 + ((x) << 8)) | ||
| 43 | #define MXC_GPR(x) (0x38 + ((x) << 8)) | ||
| 44 | #define MXC_SWR(x) (0x3c + ((x) << 8)) | ||
| 45 | #define MXC_PUEN(x) (0x40 + ((x) << 8)) | ||
| 46 | |||
| 47 | #ifdef CONFIG_ARCH_MX1 | ||
| 48 | # define GPIO_PORT_MAX 3 | ||
| 49 | #endif | ||
| 50 | #ifdef CONFIG_ARCH_MX2 | ||
| 51 | # define GPIO_PORT_MAX 5 | ||
| 52 | #endif | ||
| 53 | |||
| 54 | #ifndef GPIO_PORT_MAX | ||
| 55 | # error "GPIO config port count unknown!" | ||
| 56 | #endif | ||
| 57 | |||
| 58 | #define GPIO_PIN_MASK 0x1f | ||
| 59 | |||
| 60 | #define GPIO_PORT_SHIFT 5 | ||
| 61 | #define GPIO_PORT_MASK (0x7 << GPIO_PORT_SHIFT) | ||
| 62 | |||
| 63 | #define GPIO_PORTA (0 << GPIO_PORT_SHIFT) | ||
| 64 | #define GPIO_PORTB (1 << GPIO_PORT_SHIFT) | ||
| 65 | #define GPIO_PORTC (2 << GPIO_PORT_SHIFT) | ||
| 66 | #define GPIO_PORTD (3 << GPIO_PORT_SHIFT) | ||
| 67 | #define GPIO_PORTE (4 << GPIO_PORT_SHIFT) | ||
| 68 | #define GPIO_PORTF (5 << GPIO_PORT_SHIFT) | ||
| 69 | |||
| 70 | #define GPIO_OUT (1 << 8) | ||
| 71 | #define GPIO_IN (0 << 8) | ||
| 72 | #define GPIO_PUEN (1 << 9) | ||
| 73 | |||
| 74 | #define GPIO_PF (1 << 10) | ||
| 75 | #define GPIO_AF (1 << 11) | ||
| 76 | |||
| 77 | #define GPIO_OCR_SHIFT 12 | ||
| 78 | #define GPIO_OCR_MASK (3 << GPIO_OCR_SHIFT) | ||
| 79 | #define GPIO_AIN (0 << GPIO_OCR_SHIFT) | ||
| 80 | #define GPIO_BIN (1 << GPIO_OCR_SHIFT) | ||
| 81 | #define GPIO_CIN (2 << GPIO_OCR_SHIFT) | ||
| 82 | #define GPIO_GPIO (3 << GPIO_OCR_SHIFT) | ||
| 83 | |||
| 84 | #define GPIO_AOUT_SHIFT 14 | ||
| 85 | #define GPIO_AOUT_MASK (3 << GPIO_AOUT_SHIFT) | ||
| 86 | #define GPIO_AOUT (0 << GPIO_AOUT_SHIFT) | ||
| 87 | #define GPIO_AOUT_ISR (1 << GPIO_AOUT_SHIFT) | ||
| 88 | #define GPIO_AOUT_0 (2 << GPIO_AOUT_SHIFT) | ||
| 89 | #define GPIO_AOUT_1 (3 << GPIO_AOUT_SHIFT) | ||
| 90 | |||
| 91 | #define GPIO_BOUT_SHIFT 16 | ||
| 92 | #define GPIO_BOUT_MASK (3 << GPIO_BOUT_SHIFT) | ||
| 93 | #define GPIO_BOUT (0 << GPIO_BOUT_SHIFT) | ||
| 94 | #define GPIO_BOUT_ISR (1 << GPIO_BOUT_SHIFT) | ||
| 95 | #define GPIO_BOUT_0 (2 << GPIO_BOUT_SHIFT) | ||
| 96 | #define GPIO_BOUT_1 (3 << GPIO_BOUT_SHIFT) | ||
| 97 | |||
| 98 | extern void mxc_gpio_mode(int gpio_mode); | ||
| 99 | extern int mxc_gpio_setup_multiple_pins(const int *pin_list, unsigned count, | ||
| 100 | const char *label); | ||
| 101 | extern void mxc_gpio_release_multiple_pins(const int *pin_list, int count); | ||
| 102 | |||
| 103 | /*-------------------------------------------------------------------------*/ | ||
| 104 | |||
| 105 | /* assignements for GPIO alternate/primary functions */ | ||
| 106 | |||
| 107 | /* FIXME: This list is not completed. The correct directions are | ||
| 108 | * missing on some (many) pins | ||
| 109 | */ | ||
| 110 | #ifdef CONFIG_ARCH_MX1 | ||
| 111 | #define PA0_AIN_SPI2_CLK (GPIO_PORTA | GPIO_OUT | 0) | ||
| 112 | #define PA0_AF_ETMTRACESYNC (GPIO_PORTA | GPIO_AF | 0) | ||
| 113 | #define PA1_AOUT_SPI2_RXD (GPIO_PORTA | GPIO_IN | 1) | ||
| 114 | #define PA1_PF_TIN (GPIO_PORTA | GPIO_PF | 1) | ||
| 115 | #define PA2_PF_PWM0 (GPIO_PORTA | GPIO_OUT | GPIO_PF | 2) | ||
| 116 | #define PA3_PF_CSI_MCLK (GPIO_PORTA | GPIO_PF | 3) | ||
| 117 | #define PA4_PF_CSI_D0 (GPIO_PORTA | GPIO_PF | 4) | ||
| 118 | #define PA5_PF_CSI_D1 (GPIO_PORTA | GPIO_PF | 5) | ||
| 119 | #define PA6_PF_CSI_D2 (GPIO_PORTA | GPIO_PF | 6) | ||
| 120 | #define PA7_PF_CSI_D3 (GPIO_PORTA | GPIO_PF | 7) | ||
| 121 | #define PA8_PF_CSI_D4 (GPIO_PORTA | GPIO_PF | 8) | ||
| 122 | #define PA9_PF_CSI_D5 (GPIO_PORTA | GPIO_PF | 9) | ||
| 123 | #define PA10_PF_CSI_D6 (GPIO_PORTA | GPIO_PF | 10) | ||
| 124 | #define PA11_PF_CSI_D7 (GPIO_PORTA | GPIO_PF | 11) | ||
| 125 | #define PA12_PF_CSI_VSYNC (GPIO_PORTA | GPIO_PF | 12) | ||
| 126 | #define PA13_PF_CSI_HSYNC (GPIO_PORTA | GPIO_PF | 13) | ||
| 127 | #define PA14_PF_CSI_PIXCLK (GPIO_PORTA | GPIO_PF | 14) | ||
| 128 | #define PA15_PF_I2C_SDA (GPIO_PORTA | GPIO_OUT | GPIO_PF | 15) | ||
| 129 | #define PA16_PF_I2C_SCL (GPIO_PORTA | GPIO_OUT | GPIO_PF | 16) | ||
| 130 | #define PA17_AF_ETMTRACEPKT4 (GPIO_PORTA | GPIO_AF | 17) | ||
| 131 | #define PA17_AIN_SPI2_SS (GPIO_PORTA | GPIO_OUT | 17) | ||
| 132 | #define PA18_AF_ETMTRACEPKT5 (GPIO_PORTA | GPIO_AF | 18) | ||
| 133 | #define PA19_AF_ETMTRACEPKT6 (GPIO_PORTA | GPIO_AF | 19) | ||
| 134 | #define PA20_AF_ETMTRACEPKT7 (GPIO_PORTA | GPIO_AF | 20) | ||
| 135 | #define PA21_PF_A0 (GPIO_PORTA | GPIO_PF | 21) | ||
| 136 | #define PA22_PF_CS4 (GPIO_PORTA | GPIO_PF | 22) | ||
| 137 | #define PA23_PF_CS5 (GPIO_PORTA | GPIO_PF | 23) | ||
| 138 | #define PA24_PF_A16 (GPIO_PORTA | GPIO_PF | 24) | ||
| 139 | #define PA24_AF_ETMTRACEPKT0 (GPIO_PORTA | GPIO_AF | 24) | ||
| 140 | #define PA25_PF_A17 (GPIO_PORTA | GPIO_PF | 25) | ||
| 141 | #define PA25_AF_ETMTRACEPKT1 (GPIO_PORTA | GPIO_AF | 25) | ||
| 142 | #define PA26_PF_A18 (GPIO_PORTA | GPIO_PF | 26) | ||
| 143 | #define PA26_AF_ETMTRACEPKT2 (GPIO_PORTA | GPIO_AF | 26) | ||
| 144 | #define PA27_PF_A19 (GPIO_PORTA | GPIO_PF | 27) | ||
| 145 | #define PA27_AF_ETMTRACEPKT3 (GPIO_PORTA | GPIO_AF | 27) | ||
| 146 | #define PA28_PF_A20 (GPIO_PORTA | GPIO_PF | 28) | ||
| 147 | #define PA28_AF_ETMPIPESTAT0 (GPIO_PORTA | GPIO_AF | 28) | ||
| 148 | #define PA29_PF_A21 (GPIO_PORTA | GPIO_PF | 29) | ||
| 149 | #define PA29_AF_ETMPIPESTAT1 (GPIO_PORTA | GPIO_AF | 29) | ||
| 150 | #define PA30_PF_A22 (GPIO_PORTA | GPIO_PF | 30) | ||
| 151 | #define PA30_AF_ETMPIPESTAT2 (GPIO_PORTA | GPIO_AF | 30) | ||
| 152 | #define PA31_PF_A23 (GPIO_PORTA | GPIO_PF | 31) | ||
| 153 | #define PA31_AF_ETMTRACECLK (GPIO_PORTA | GPIO_AF | 31) | ||
| 154 | #define PB8_PF_SD_DAT0 (GPIO_PORTB | GPIO_PF | GPIO_PUEN | 8) | ||
| 155 | #define PB8_AF_MS_PIO (GPIO_PORTB | GPIO_AF | 8) | ||
| 156 | #define PB9_PF_SD_DAT1 (GPIO_PORTB | GPIO_PF | GPIO_PUEN | 9) | ||
| 157 | #define PB9_AF_MS_PI1 (GPIO_PORTB | GPIO_AF | 9) | ||
| 158 | #define PB10_PF_SD_DAT2 (GPIO_PORTB | GPIO_PF | GPIO_PUEN | 10) | ||
| 159 | #define PB10_AF_MS_SCLKI (GPIO_PORTB | GPIO_AF | 10) | ||
| 160 | #define PB11_PF_SD_DAT3 (GPIO_PORTB | GPIO_PF | 11) | ||
| 161 | #define PB11_AF_MS_SDIO (GPIO_PORTB | GPIO_AF | 11) | ||
| 162 | #define PB12_PF_SD_CLK (GPIO_PORTB | GPIO_PF | 12) | ||
| 163 | #define PB12_AF_MS_SCLK0 (GPIO_PORTB | GPIO_AF | 12) | ||
| 164 | #define PB13_PF_SD_CMD (GPIO_PORTB | GPIO_PF | GPIO_PUEN | 13) | ||
| 165 | #define PB13_AF_MS_BS (GPIO_PORTB | GPIO_AF | 13) | ||
| 166 | #define PB14_AF_SSI_RXFS (GPIO_PORTB | GPIO_AF | 14) | ||
| 167 | #define PB15_AF_SSI_RXCLK (GPIO_PORTB | GPIO_AF | 15) | ||
| 168 | #define PB16_AF_SSI_RXDAT (GPIO_PORTB | GPIO_IN | GPIO_AF | 16) | ||
| 169 | #define PB17_AF_SSI_TXDAT (GPIO_PORTB | GPIO_OUT | GPIO_AF | 17) | ||
| 170 | #define PB18_AF_SSI_TXFS (GPIO_PORTB | GPIO_AF | 18) | ||
| 171 | #define PB19_AF_SSI_TXCLK (GPIO_PORTB | GPIO_AF | 19) | ||
| 172 | #define PB20_PF_USBD_AFE (GPIO_PORTB | GPIO_PF | 20) | ||
| 173 | #define PB21_PF_USBD_OE (GPIO_PORTB | GPIO_PF | 21) | ||
| 174 | #define PB22_PFUSBD_RCV (GPIO_PORTB | GPIO_PF | 22) | ||
| 175 | #define PB23_PF_USBD_SUSPND (GPIO_PORTB | GPIO_PF | 23) | ||
| 176 | #define PB24_PF_USBD_VP (GPIO_PORTB | GPIO_PF | 24) | ||
| 177 | #define PB25_PF_USBD_VM (GPIO_PORTB | GPIO_PF | 25) | ||
| 178 | #define PB26_PF_USBD_VPO (GPIO_PORTB | GPIO_PF | 26) | ||
| 179 | #define PB27_PF_USBD_VMO (GPIO_PORTB | GPIO_PF | 27) | ||
| 180 | #define PB28_PF_UART2_CTS (GPIO_PORTB | GPIO_OUT | GPIO_PF | 28) | ||
| 181 | #define PB29_PF_UART2_RTS (GPIO_PORTB | GPIO_IN | GPIO_PF | 29) | ||
| 182 | #define PB30_PF_UART2_TXD (GPIO_PORTB | GPIO_OUT | GPIO_PF | 30) | ||
| 183 | #define PB31_PF_UART2_RXD (GPIO_PORTB | GPIO_IN | GPIO_PF | 31) | ||
| 184 | #define PC3_PF_SSI_RXFS (GPIO_PORTC | GPIO_PF | 3) | ||
| 185 | #define PC4_PF_SSI_RXCLK (GPIO_PORTC | GPIO_PF | 4) | ||
| 186 | #define PC5_PF_SSI_RXDAT (GPIO_PORTC | GPIO_IN | GPIO_PF | 5) | ||
| 187 | #define PC6_PF_SSI_TXDAT (GPIO_PORTC | GPIO_OUT | GPIO_PF | 6) | ||
| 188 | #define PC7_PF_SSI_TXFS (GPIO_PORTC | GPIO_PF | 7) | ||
| 189 | #define PC8_PF_SSI_TXCLK (GPIO_PORTC | GPIO_PF | 8) | ||
| 190 | #define PC9_PF_UART1_CTS (GPIO_PORTC | GPIO_OUT | GPIO_PF | 9) | ||
| 191 | #define PC10_PF_UART1_RTS (GPIO_PORTC | GPIO_IN | GPIO_PF | 10) | ||
| 192 | #define PC11_PF_UART1_TXD (GPIO_PORTC | GPIO_OUT | GPIO_PF | 11) | ||
| 193 | #define PC12_PF_UART1_RXD (GPIO_PORTC | GPIO_IN | GPIO_PF | 12) | ||
| 194 | #define PC13_PF_SPI1_SPI_RDY (GPIO_PORTC | GPIO_PF | 13) | ||
| 195 | #define PC14_PF_SPI1_SCLK (GPIO_PORTC | GPIO_PF | 14) | ||
| 196 | #define PC15_PF_SPI1_SS (GPIO_PORTC | GPIO_PF | 15) | ||
| 197 | #define PC16_PF_SPI1_MISO (GPIO_PORTC | GPIO_PF | 16) | ||
| 198 | #define PC17_PF_SPI1_MOSI (GPIO_PORTC | GPIO_PF | 17) | ||
| 199 | #define PC24_BIN_UART3_RI (GPIO_PORTC | GPIO_OUT | GPIO_BIN | 24) | ||
| 200 | #define PC25_BIN_UART3_DSR (GPIO_PORTC | GPIO_OUT | GPIO_BIN | 25) | ||
| 201 | #define PC26_AOUT_UART3_DTR (GPIO_PORTC | GPIO_IN | 26) | ||
| 202 | #define PC27_BIN_UART3_DCD (GPIO_PORTC | GPIO_OUT | GPIO_BIN | 27) | ||
| 203 | #define PC28_BIN_UART3_CTS (GPIO_PORTC | GPIO_OUT | GPIO_BIN | 28) | ||
| 204 | #define PC29_AOUT_UART3_RTS (GPIO_PORTC | GPIO_IN | 29) | ||
| 205 | #define PC30_BIN_UART3_TX (GPIO_PORTC | GPIO_BIN | 30) | ||
| 206 | #define PC31_AOUT_UART3_RX (GPIO_PORTC | GPIO_IN | 31) | ||
| 207 | #define PD6_PF_LSCLK (GPIO_PORTD | GPIO_OUT | GPIO_PF | 6) | ||
| 208 | #define PD7_PF_REV (GPIO_PORTD | GPIO_PF | 7) | ||
| 209 | #define PD7_AF_UART2_DTR (GPIO_PORTD | GPIO_IN | GPIO_AF | 7) | ||
| 210 | #define PD7_AIN_SPI2_SCLK (GPIO_PORTD | GPIO_AIN | 7) | ||
| 211 | #define PD8_PF_CLS (GPIO_PORTD | GPIO_PF | 8) | ||
| 212 | #define PD8_AF_UART2_DCD (GPIO_PORTD | GPIO_OUT | GPIO_AF | 8) | ||
| 213 | #define PD8_AIN_SPI2_SS (GPIO_PORTD | GPIO_AIN | 8) | ||
| 214 | #define PD9_PF_PS (GPIO_PORTD | GPIO_PF | 9) | ||
| 215 | #define PD9_AF_UART2_RI (GPIO_PORTD | GPIO_OUT | GPIO_AF | 9) | ||
| 216 | #define PD9_AOUT_SPI2_RXD (GPIO_PORTD | GPIO_IN | 9) | ||
| 217 | #define PD10_PF_SPL_SPR (GPIO_PORTD | GPIO_OUT | GPIO_PF | 10) | ||
| 218 | #define PD10_AF_UART2_DSR (GPIO_PORTD | GPIO_OUT | GPIO_AF | 10) | ||
| 219 | #define PD10_AIN_SPI2_TXD (GPIO_PORTD | GPIO_OUT | 10) | ||
| 220 | #define PD11_PF_CONTRAST (GPIO_PORTD | GPIO_OUT | GPIO_PF | 11) | ||
| 221 | #define PD12_PF_ACD_OE (GPIO_PORTD | GPIO_OUT | GPIO_PF | 12) | ||
| 222 | #define PD13_PF_LP_HSYNC (GPIO_PORTD | GPIO_OUT | GPIO_PF | 13) | ||
| 223 | #define PD14_PF_FLM_VSYNC (GPIO_PORTD | GPIO_OUT | GPIO_PF | 14) | ||
| 224 | #define PD15_PF_LD0 (GPIO_PORTD | GPIO_OUT | GPIO_PF | 15) | ||
| 225 | #define PD16_PF_LD1 (GPIO_PORTD | GPIO_OUT | GPIO_PF | 16) | ||
| 226 | #define PD17_PF_LD2 (GPIO_PORTD | GPIO_OUT | GPIO_PF | 17) | ||
| 227 | #define PD18_PF_LD3 (GPIO_PORTD | GPIO_OUT | GPIO_PF | 18) | ||
| 228 | #define PD19_PF_LD4 (GPIO_PORTD | GPIO_OUT | GPIO_PF | 19) | ||
| 229 | #define PD20_PF_LD5 (GPIO_PORTD | GPIO_OUT | GPIO_PF | 20) | ||
| 230 | #define PD21_PF_LD6 (GPIO_PORTD | GPIO_OUT | GPIO_PF | 21) | ||
| 231 | #define PD22_PF_LD7 (GPIO_PORTD | GPIO_OUT | GPIO_PF | 22) | ||
| 232 | #define PD23_PF_LD8 (GPIO_PORTD | GPIO_OUT | GPIO_PF | 23) | ||
| 233 | #define PD24_PF_LD9 (GPIO_PORTD | GPIO_OUT | GPIO_PF | 24) | ||
| 234 | #define PD25_PF_LD10 (GPIO_PORTD | GPIO_OUT | GPIO_PF | 25) | ||
| 235 | #define PD26_PF_LD11 (GPIO_PORTD | GPIO_OUT | GPIO_PF | 26) | ||
| 236 | #define PD27_PF_LD12 (GPIO_PORTD | GPIO_OUT | GPIO_PF | 27) | ||
| 237 | #define PD28_PF_LD13 (GPIO_PORTD | GPIO_OUT | GPIO_PF | 28) | ||
| 238 | #define PD29_PF_LD14 (GPIO_PORTD | GPIO_OUT | GPIO_PF | 29) | ||
| 239 | #define PD30_PF_LD15 (GPIO_PORTD | GPIO_OUT | GPIO_PF | 30) | ||
| 240 | #define PD31_PF_TMR2OUT (GPIO_PORTD | GPIO_PF | 31) | ||
| 241 | #define PD31_BIN_SPI2_TXD (GPIO_PORTD | GPIO_BIN | 31) | ||
| 242 | #endif | ||
| 243 | |||
| 244 | #ifdef CONFIG_ARCH_MX2 | ||
| 245 | #define PA0_PF_USBH2_CLK (GPIO_PORTA | GPIO_PF | 0) | ||
| 246 | #define PA1_PF_USBH2_DIR (GPIO_PORTA | GPIO_PF | 1) | ||
| 247 | #define PA2_PF_USBH2_DATA7 (GPIO_PORTA | GPIO_PF | 2) | ||
| 248 | #define PA3_PF_USBH2_NXT (GPIO_PORTA | GPIO_PF | 3) | ||
| 249 | #define PA4_PF_USBH2_STP (GPIO_PORTA | GPIO_PF | 4) | ||
| 250 | #define PA5_PF_LSCLK (GPIO_PORTA | GPIO_OUT | GPIO_PF | 5) | ||
| 251 | #define PA6_PF_LD0 (GPIO_PORTA | GPIO_OUT | GPIO_PF | 6) | ||
| 252 | #define PA7_PF_LD1 (GPIO_PORTA | GPIO_OUT | GPIO_PF | 7) | ||
| 253 | #define PA8_PF_LD2 (GPIO_PORTA | GPIO_OUT | GPIO_PF | 8) | ||
| 254 | #define PA9_PF_LD3 (GPIO_PORTA | GPIO_OUT | GPIO_PF | 9) | ||
| 255 | #define PA10_PF_LD4 (GPIO_PORTA | GPIO_OUT | GPIO_PF | 10) | ||
| 256 | #define PA11_PF_LD5 (GPIO_PORTA | GPIO_OUT | GPIO_PF | 11) | ||
| 257 | #define PA12_PF_LD6 (GPIO_PORTA | GPIO_OUT | GPIO_PF | 12) | ||
| 258 | #define PA13_PF_LD7 (GPIO_PORTA | GPIO_OUT | GPIO_PF | 13) | ||
| 259 | #define PA14_PF_LD8 (GPIO_PORTA | GPIO_OUT | GPIO_PF | 14) | ||
| 260 | #define PA15_PF_LD9 (GPIO_PORTA | GPIO_OUT | GPIO_PF | 15) | ||
| 261 | #define PA16_PF_LD10 (GPIO_PORTA | GPIO_OUT | GPIO_PF | 16) | ||
| 262 | #define PA17_PF_LD11 (GPIO_PORTA | GPIO_OUT | GPIO_PF | 17) | ||
| 263 | #define PA18_PF_LD12 (GPIO_PORTA | GPIO_OUT | GPIO_PF | 18) | ||
| 264 | #define PA19_PF_LD13 (GPIO_PORTA | GPIO_OUT | GPIO_PF | 19) | ||
| 265 | #define PA20_PF_LD14 (GPIO_PORTA | GPIO_OUT | GPIO_PF | 20) | ||
| 266 | #define PA21_PF_LD15 (GPIO_PORTA | GPIO_OUT | GPIO_PF | 21) | ||
| 267 | #define PA22_PF_LD16 (GPIO_PORTA | GPIO_OUT | GPIO_PF | 22) | ||
| 268 | #define PA23_PF_LD17 (GPIO_PORTA | GPIO_OUT | GPIO_PF | 23) | ||
| 269 | #define PA24_PF_REV (GPIO_PORTA | GPIO_OUT | GPIO_PF | 24) | ||
| 270 | #define PA25_PF_CLS (GPIO_PORTA | GPIO_OUT | GPIO_PF | 25) | ||
| 271 | #define PA26_PF_PS (GPIO_PORTA | GPIO_OUT | GPIO_PF | 26) | ||
| 272 | #define PA27_PF_SPL_SPR (GPIO_PORTA | GPIO_OUT | GPIO_PF | 27) | ||
| 273 | #define PA28_PF_HSYNC (GPIO_PORTA | GPIO_OUT | GPIO_PF | 28) | ||
| 274 | #define PA29_PF_VSYNC (GPIO_PORTA | GPIO_OUT | GPIO_PF | 29) | ||
| 275 | #define PA30_PF_CONTRAST (GPIO_PORTA | GPIO_OUT | GPIO_PF | 30) | ||
| 276 | #define PA31_PF_OE_ACD (GPIO_PORTA | GPIO_OUT | GPIO_PF | 31) | ||
| 277 | #define PB4_PF_SD2_D0 (GPIO_PORTB | GPIO_PF | 4) | ||
| 278 | #define PB5_PF_SD2_D1 (GPIO_PORTB | GPIO_PF | 5) | ||
| 279 | #define PB6_PF_SD2_D2 (GPIO_PORTB | GPIO_PF | 6) | ||
| 280 | #define PB7_PF_SD2_D3 (GPIO_PORTB | GPIO_PF | 7) | ||
| 281 | #define PB8_PF_SD2_CMD (GPIO_PORTB | GPIO_PF | 8) | ||
| 282 | #define PB9_PF_SD2_CLK (GPIO_PORTB | GPIO_PF | 9) | ||
| 283 | #define PB10_PF_CSI_D0 (GPIO_PORTB | GPIO_OUT | GPIO_PF | 10) | ||
| 284 | #define PB10_AF_UART6_TXD (GPIO_PORTB | GPIO_OUT | GPIO_AF | 10) | ||
| 285 | #define PB11_PF_CSI_D1 (GPIO_PORTB | GPIO_OUT | GPIO_PF | 11) | ||
| 286 | #define PB11_AF_UART6_RXD (GPIO_PORTB | GPIO_IN | GPIO_AF | 11) | ||
| 287 | #define PB12_PF_CSI_D2 (GPIO_PORTB | GPIO_OUT | GPIO_PF | 12) | ||
| 288 | #define PB12_AF_UART6_CTS (GPIO_PORTB | GPIO_OUT | GPIO_AF | 12) | ||
| 289 | #define PB13_PF_CSI_D3 (GPIO_PORTB | GPIO_OUT | GPIO_PF | 13) | ||
| 290 | #define PB13_AF_UART6_RTS (GPIO_PORTB | GPIO_IN | GPIO_AF | 13) | ||
| 291 | #define PB14_PF_CSI_D4 (GPIO_PORTB | GPIO_OUT | GPIO_PF | 14) | ||
| 292 | #define PB15_PF_CSI_MCLK (GPIO_PORTB | GPIO_OUT | GPIO_PF | 15) | ||
| 293 | #define PB16_PF_CSI_PIXCLK (GPIO_PORTB | GPIO_OUT | GPIO_PF | 16) | ||
| 294 | #define PB17_PF_CSI_D5 (GPIO_PORTB | GPIO_OUT | GPIO_PF | 17) | ||
| 295 | #define PB18_PF_CSI_D6 (GPIO_PORTB | GPIO_OUT | GPIO_PF | 18) | ||
| 296 | #define PB18_AF_UART5_TXD (GPIO_PORTB | GPIO_OUT | GPIO_AF | 18) | ||
| 297 | #define PB19_PF_CSI_D7 (GPIO_PORTB | GPIO_OUT | GPIO_PF | 19) | ||
| 298 | #define PB19_AF_UART5_RXD (GPIO_PORTB | GPIO_IN | GPIO_AF | 19) | ||
| 299 | #define PB20_PF_CSI_VSYNC (GPIO_PORTB | GPIO_OUT | GPIO_PF | 20) | ||
| 300 | #define PB20_AF_UART5_CTS (GPIO_PORTB | GPIO_OUT | GPIO_AF | 20) | ||
| 301 | #define PB21_PF_CSI_HSYNC (GPIO_PORTB | GPIO_OUT | GPIO_PF | 21) | ||
| 302 | #define PB21_AF_UART5_RTS (GPIO_PORTB | GPIO_IN | GPIO_AF | 21) | ||
| 303 | #define PB22_PF_USBH1_SUSP (GPIO_PORTB | GPIO_PF | 22) | ||
| 304 | #define PB23_PF_USB_PWR (GPIO_PORTB | GPIO_PF | 23) | ||
| 305 | #define PB24_PF_USB_OC_B (GPIO_PORTB | GPIO_PF | 24) | ||
| 306 | #define PB25_PF_USBH1_RCV (GPIO_PORTB | GPIO_PF | 25) | ||
| 307 | #define PB26_PF_USBH1_FS (GPIO_PORTB | GPIO_PF | 26) | ||
| 308 | #define PB27_PF_USBH1_OE_B (GPIO_PORTB | GPIO_PF | 27) | ||
| 309 | #define PB28_PF_USBH1_TXDM (GPIO_PORTB | GPIO_PF | 28) | ||
| 310 | #define PB29_PF_USBH1_TXDP (GPIO_PORTB | GPIO_PF | 29) | ||
| 311 | #define PB30_PF_USBH1_RXDM (GPIO_PORTB | GPIO_PF | 30) | ||
| 312 | #define PB31_PF_USBH1_RXDP (GPIO_PORTB | GPIO_PF | 31) | ||
| 313 | #define PB26_AF_UART4_RTS (GPIO_PORTB | GPIO_IN | GPIO_PF | 26) | ||
| 314 | #define PB28_AF_UART4_TXD (GPIO_PORTB | GPIO_OUT | GPIO_AF | 28) | ||
| 315 | #define PB29_AF_UART4_CTS (GPIO_PORTB | GPIO_OUT | GPIO_AF | 29) | ||
| 316 | #define PB31_AF_UART4_RXD (GPIO_PORTB | GPIO_IN | GPIO_AF | 31) | ||
| 317 | #define PC5_PF_I2C2_SDA (GPIO_PORTC | GPIO_IN | GPIO_PF | 5) | ||
| 318 | #define PC6_PF_I2C2_SCL (GPIO_PORTC | GPIO_IN | GPIO_PF | 6) | ||
| 319 | #define PC7_PF_USBOTG_DATA5 (GPIO_PORTC | GPIO_OUT | GPIO_PF | 7) | ||
| 320 | #define PC8_PF_USBOTG_DATA6 (GPIO_PORTC | GPIO_OUT | GPIO_PF | 8) | ||
| 321 | #define PC9_PF_USBOTG_DATA0 (GPIO_PORTC | GPIO_OUT | GPIO_PF | 9) | ||
| 322 | #define PC10_PF_USBOTG_DATA2 (GPIO_PORTC | GPIO_OUT | GPIO_PF | 10) | ||
| 323 | #define PC11_PF_USBOTG_DATA1 (GPIO_PORTC | GPIO_OUT | GPIO_PF | 11) | ||
| 324 | #define PC12_PF_USBOTG_DATA4 (GPIO_PORTC | GPIO_OUT | GPIO_PF | 12) | ||
| 325 | #define PC13_PF_USBOTG_DATA3 (GPIO_PORTC | GPIO_OUT | GPIO_PF | 13) | ||
| 326 | #define PC16_PF_SSI4_FS (GPIO_PORTC | GPIO_IN | GPIO_PF | 16) | ||
| 327 | #define PC17_PF_SSI4_RXD (GPIO_PORTC | GPIO_IN | GPIO_PF | 17) | ||
| 328 | #define PC18_PF_SSI4_TXD (GPIO_PORTC | GPIO_IN | GPIO_PF | 18) | ||
| 329 | #define PC19_PF_SSI4_CLK (GPIO_PORTC | GPIO_IN | GPIO_PF | 19) | ||
| 330 | #define PC20_PF_SSI1_FS (GPIO_PORTC | GPIO_IN | GPIO_PF | 20) | ||
| 331 | #define PC21_PF_SSI1_RXD (GPIO_PORTC | GPIO_IN | GPIO_PF | 21) | ||
| 332 | #define PC22_PF_SSI1_TXD (GPIO_PORTC | GPIO_IN | GPIO_PF | 22) | ||
| 333 | #define PC23_PF_SSI1_CLK (GPIO_PORTC | GPIO_IN | GPIO_PF | 23) | ||
| 334 | #define PC24_PF_SSI2_FS (GPIO_PORTC | GPIO_IN | GPIO_PF | 24) | ||
| 335 | #define PC25_PF_SSI2_RXD (GPIO_PORTC | GPIO_IN | GPIO_PF | 25) | ||
| 336 | #define PC26_PF_SSI2_TXD (GPIO_PORTC | GPIO_IN | GPIO_PF | 26) | ||
| 337 | #define PC27_PF_SSI2_CLK (GPIO_PORTC | GPIO_IN | GPIO_PF | 27) | ||
| 338 | #define PC28_PF_SSI3_FS (GPIO_PORTC | GPIO_IN | GPIO_PF | 28) | ||
| 339 | #define PC29_PF_SSI3_RXD (GPIO_PORTC | GPIO_IN | GPIO_PF | 29) | ||
| 340 | #define PC30_PF_SSI3_TXD (GPIO_PORTC | GPIO_IN | GPIO_PF | 30) | ||
| 341 | #define PC31_PF_SSI3_CLK (GPIO_PORTC | GPIO_IN | GPIO_PF | 31) | ||
| 342 | #define PD0_AIN_FEC_TXD0 (GPIO_PORTD | GPIO_OUT | GPIO_AIN | 0) | ||
| 343 | #define PD1_AIN_FEC_TXD1 (GPIO_PORTD | GPIO_OUT | GPIO_AIN | 1) | ||
| 344 | #define PD2_AIN_FEC_TXD2 (GPIO_PORTD | GPIO_OUT | GPIO_AIN | 2) | ||
| 345 | #define PD3_AIN_FEC_TXD3 (GPIO_PORTD | GPIO_OUT | GPIO_AIN | 3) | ||
| 346 | #define PD4_AOUT_FEC_RX_ER (GPIO_PORTD | GPIO_IN | GPIO_AOUT | 4) | ||
| 347 | #define PD5_AOUT_FEC_RXD1 (GPIO_PORTD | GPIO_IN | GPIO_AOUT | 5) | ||
| 348 | #define PD6_AOUT_FEC_RXD2 (GPIO_PORTD | GPIO_IN | GPIO_AOUT | 6) | ||
| 349 | #define PD7_AOUT_FEC_RXD3 (GPIO_PORTD | GPIO_IN | GPIO_AOUT | 7) | ||
| 350 | #define PD8_AF_FEC_MDIO (GPIO_PORTD | GPIO_IN | GPIO_AF | 8) | ||
| 351 | #define PD9_AIN_FEC_MDC (GPIO_PORTD | GPIO_OUT | GPIO_AIN | 9) | ||
| 352 | #define PD10_AOUT_FEC_CRS (GPIO_PORTD | GPIO_IN | GPIO_AOUT | 10) | ||
| 353 | #define PD11_AOUT_FEC_TX_CLK (GPIO_PORTD | GPIO_IN | GPIO_AOUT | 11) | ||
| 354 | #define PD12_AOUT_FEC_RXD0 (GPIO_PORTD | GPIO_IN | GPIO_AOUT | 12) | ||
| 355 | #define PD13_AOUT_FEC_RX_DV (GPIO_PORTD | GPIO_IN | GPIO_AOUT | 13) | ||
| 356 | #define PD14_AOUT_FEC_CLR (GPIO_PORTD | GPIO_IN | GPIO_AOUT | 14) | ||
| 357 | #define PD15_AOUT_FEC_COL (GPIO_PORTD | GPIO_IN | GPIO_AOUT | 15) | ||
| 358 | #define PD16_AIN_FEC_TX_ER (GPIO_PORTD | GPIO_OUT | GPIO_AIN | 16) | ||
| 359 | #define PD17_PF_I2C_DATA (GPIO_PORTD | GPIO_OUT | GPIO_PF | 17) | ||
| 360 | #define PD18_PF_I2C_CLK (GPIO_PORTD | GPIO_OUT | GPIO_PF | 18) | ||
| 361 | #define PD19_AF_USBH2_DATA4 (GPIO_PORTD | GPIO_AF | 19) | ||
| 362 | #define PD20_AF_USBH2_DATA3 (GPIO_PORTD | GPIO_AF | 20) | ||
| 363 | #define PD21_AF_USBH2_DATA6 (GPIO_PORTD | GPIO_AF | 21) | ||
| 364 | #define PD22_AF_USBH2_DATA0 (GPIO_PORTD | GPIO_AF | 22) | ||
| 365 | #define PD23_AF_USBH2_DATA2 (GPIO_PORTD | GPIO_AF | 23) | ||
| 366 | #define PD24_AF_USBH2_DATA1 (GPIO_PORTD | GPIO_AF | 24) | ||
| 367 | #define PD25_PF_CSPI1_RDY (GPIO_PORTD | GPIO_OUT | GPIO_PF | 25) | ||
| 368 | #define PD26_PF_CSPI1_SS2 (GPIO_PORTD | GPIO_OUT | GPIO_PF | 26) | ||
| 369 | #define PD26_AF_USBH2_DATA5 (GPIO_PORTD | GPIO_AF | 26) | ||
| 370 | #define PD27_PF_CSPI1_SS1 (GPIO_PORTD | GPIO_OUT | GPIO_PF | 27) | ||
| 371 | #define PD28_PF_CSPI1_SS0 (GPIO_PORTD | GPIO_OUT | GPIO_PF | 28) | ||
| 372 | #define PD29_PF_CSPI1_SCLK (GPIO_PORTD | GPIO_OUT | GPIO_PF | 29) | ||
| 373 | #define PD30_PF_CSPI1_MISO (GPIO_PORTD | GPIO_IN | GPIO_PF | 30) | ||
| 374 | #define PD31_PF_CSPI1_MOSI (GPIO_PORTD | GPIO_OUT | GPIO_PF | 31) | ||
| 375 | #define PF23_AIN_FEC_TX_EN (GPIO_PORTF | GPIO_OUT | GPIO_AIN | 23) | ||
| 376 | #define PE0_PF_USBOTG_NXT (GPIO_PORTE | GPIO_OUT | GPIO_PF | 0) | ||
| 377 | #define PE1_PF_USBOTG_STP (GPIO_PORTE | GPIO_OUT | GPIO_PF | 1) | ||
| 378 | #define PE2_PF_USBOTG_DIR (GPIO_PORTE | GPIO_OUT | GPIO_PF | 2) | ||
| 379 | #define PE3_PF_UART2_CTS (GPIO_PORTE | GPIO_OUT | GPIO_PF | 3) | ||
| 380 | #define PE4_PF_UART2_RTS (GPIO_PORTE | GPIO_IN | GPIO_PF | 4) | ||
| 381 | #define PE6_PF_UART2_TXD (GPIO_PORTE | GPIO_OUT | GPIO_PF | 6) | ||
| 382 | #define PE7_PF_UART2_RXD (GPIO_PORTE | GPIO_IN | GPIO_PF | 7) | ||
| 383 | #define PE8_PF_UART3_TXD (GPIO_PORTE | GPIO_OUT | GPIO_PF | 8) | ||
| 384 | #define PE9_PF_UART3_RXD (GPIO_PORTE | GPIO_IN | GPIO_PF | 9) | ||
| 385 | #define PE10_PF_UART3_CTS (GPIO_PORTE | GPIO_OUT | GPIO_PF | 10) | ||
| 386 | #define PE11_PF_UART3_RTS (GPIO_PORTE | GPIO_IN | GPIO_PF | 11) | ||
| 387 | #define PE12_PF_UART1_TXD (GPIO_PORTE | GPIO_OUT | GPIO_PF | 12) | ||
| 388 | #define PE13_PF_UART1_RXD (GPIO_PORTE | GPIO_IN | GPIO_PF | 13) | ||
| 389 | #define PE14_PF_UART1_CTS (GPIO_PORTE | GPIO_OUT | GPIO_PF | 14) | ||
| 390 | #define PE15_PF_UART1_RTS (GPIO_PORTE | GPIO_IN | GPIO_PF | 15) | ||
| 391 | #define PE16_AF_RTCK (GPIO_PORTE | GPIO_OUT | GPIO_AF | 16) | ||
| 392 | #define PE16_PF_RTCK (GPIO_PORTE | GPIO_OUT | GPIO_PF | 16) | ||
| 393 | #define PE18_PF_SDHC1_D0 (GPIO_PORTE | GPIO_PF | 18) | ||
| 394 | #define PE18_AF_CSPI3_MISO (GPIO_PORTE | GPIO_IN | GPIO_AF | 18) | ||
| 395 | #define PE19_PF_SDHC1_D1 (GPIO_PORTE | GPIO_PF | 19) | ||
| 396 | #define PE20_PF_SDHC1_D2 (GPIO_PORTE | GPIO_PF | 20) | ||
| 397 | #define PE21_PF_SDHC1_D3 (GPIO_PORTE | GPIO_PF | 21) | ||
| 398 | #define PE21_AF_CSPI3_SS (GPIO_PORTE | GPIO_OUT | GPIO_AF | 21) | ||
| 399 | #define PE22_PF_SDHC1_CMD (GPIO_PORTE | GPIO_PF | 22) | ||
| 400 | #define PE22_AF_CSPI3_MOSI (GPIO_PORTE | GPIO_OUT | GPIO_AF | 22) | ||
| 401 | #define PE22_PF_SDHC1_CLK (GPIO_PORTE | GPIO_PF | 23) | ||
| 402 | #define PE23_AF_CSPI3_SCLK (GPIO_PORTE | GPIO_OUT | GPIO_AF | 23) | ||
| 403 | #define PE24_PF_USBOTG_CLK (GPIO_PORTE | GPIO_OUT | GPIO_PF | 24) | ||
| 404 | #define PE25_PF_USBOTG_DATA7 (GPIO_PORTE | GPIO_OUT | GPIO_PF | 25) | ||
| 405 | #endif | ||
| 406 | |||
| 407 | /* decode irq number to use with IMR(x), ISR(x) and friends */ | ||
| 408 | #define IRQ_TO_REG(irq) ((irq - MXC_INTERNAL_IRQS) >> 5) | ||
| 409 | |||
| 410 | #define IRQ_GPIOA(x) (MXC_GPIO_IRQ_START + x) | ||
| 411 | #define IRQ_GPIOB(x) (IRQ_GPIOA(32) + x) | ||
| 412 | #define IRQ_GPIOC(x) (IRQ_GPIOB(32) + x) | ||
| 413 | #define IRQ_GPIOD(x) (IRQ_GPIOC(32) + x) | ||
| 414 | #define IRQ_GPIOE(x) (IRQ_GPIOD(32) + x) | ||
| 415 | |||
| 416 | #endif /* _MXC_GPIO_MX1_MX2_H */ | ||
diff --git a/arch/arm/plat-mxc/include/mach/iomux-mx1.h b/arch/arm/plat-mxc/include/mach/iomux-mx1.h new file mode 100644 index 000000000000..bf23305c19cc --- /dev/null +++ b/arch/arm/plat-mxc/include/mach/iomux-mx1.h | |||
| @@ -0,0 +1,166 @@ | |||
| 1 | /* | ||
| 2 | * Copyright (C) 2008 by Sascha Hauer <kernel@pengutronix.de> | ||
| 3 | * | ||
| 4 | * This program is free software; you can redistribute it and/or | ||
| 5 | * modify it under the terms of the GNU General Public License | ||
| 6 | * as published by the Free Software Foundation; either version 2 | ||
| 7 | * of the License, or (at your option) any later version. | ||
| 8 | * This program is distributed in the hope that it will be useful, | ||
| 9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 11 | * GNU General Public License for more details. | ||
| 12 | * | ||
| 13 | * You should have received a copy of the GNU General Public License | ||
| 14 | * along with this program; if not, write to the Free Software | ||
| 15 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, | ||
| 16 | * MA 02110-1301, USA. | ||
| 17 | */ | ||
| 18 | |||
| 19 | #ifndef _MXC_IOMUX_MX1_H | ||
| 20 | #define _MXC_IOMUX_MX1_H | ||
| 21 | |||
| 22 | #ifndef GPIO_PORTA | ||
| 23 | #error Please include mach/iomux.h | ||
| 24 | #endif | ||
| 25 | |||
| 26 | /* FIXME: This list is not completed. The correct directions are | ||
| 27 | * missing on some (many) pins | ||
| 28 | */ | ||
| 29 | |||
| 30 | |||
| 31 | /* Primary GPIO pin functions */ | ||
| 32 | |||
| 33 | #define PA0_AIN_SPI2_CLK (GPIO_PORTA | GPIO_AIN | GPIO_OUT | 0) | ||
| 34 | #define PA0_AF_ETMTRACESYNC (GPIO_PORTA | GPIO_AF | 0) | ||
| 35 | #define PA1_AOUT_SPI2_RXD (GPIO_PORTA | GPIO_AOUT | GPIO_IN | 1) | ||
| 36 | #define PA1_PF_TIN (GPIO_PORTA | GPIO_PF | 1) | ||
| 37 | #define PA2_PF_PWM0 (GPIO_PORTA | GPIO_PF | GPIO_OUT | 2) | ||
| 38 | #define PA3_PF_CSI_MCLK (GPIO_PORTA | GPIO_PF | 3) | ||
| 39 | #define PA4_PF_CSI_D0 (GPIO_PORTA | GPIO_PF | 4) | ||
| 40 | #define PA5_PF_CSI_D1 (GPIO_PORTA | GPIO_PF | 5) | ||
| 41 | #define PA6_PF_CSI_D2 (GPIO_PORTA | GPIO_PF | 6) | ||
| 42 | #define PA7_PF_CSI_D3 (GPIO_PORTA | GPIO_PF | 7) | ||
| 43 | #define PA8_PF_CSI_D4 (GPIO_PORTA | GPIO_PF | 8) | ||
| 44 | #define PA9_PF_CSI_D5 (GPIO_PORTA | GPIO_PF | 9) | ||
| 45 | #define PA10_PF_CSI_D6 (GPIO_PORTA | GPIO_PF | 10) | ||
| 46 | #define PA11_PF_CSI_D7 (GPIO_PORTA | GPIO_PF | 11) | ||
| 47 | #define PA12_PF_CSI_VSYNC (GPIO_PORTA | GPIO_PF | 12) | ||
| 48 | #define PA13_PF_CSI_HSYNC (GPIO_PORTA | GPIO_PF | 13) | ||
| 49 | #define PA14_PF_CSI_PIXCLK (GPIO_PORTA | GPIO_PF | 14) | ||
| 50 | #define PA15_PF_I2C_SDA (GPIO_PORTA | GPIO_PF | GPIO_OUT | 15) | ||
| 51 | #define PA16_PF_I2C_SCL (GPIO_PORTA | GPIO_PF | GPIO_OUT | 16) | ||
| 52 | #define PA17_AF_ETMTRACEPKT4 (GPIO_PORTA | GPIO_AF | 17) | ||
| 53 | #define PA17_AIN_SPI2_SS (GPIO_PORTA | GPIO_AIN | GPIO_OUT | 17) | ||
| 54 | #define PA18_AF_ETMTRACEPKT5 (GPIO_PORTA | GPIO_AF | 18) | ||
| 55 | #define PA19_AF_ETMTRACEPKT6 (GPIO_PORTA | GPIO_AF | 19) | ||
| 56 | #define PA20_AF_ETMTRACEPKT7 (GPIO_PORTA | GPIO_AF | 20) | ||
| 57 | #define PA21_PF_A0 (GPIO_PORTA | GPIO_PF | 21) | ||
| 58 | #define PA22_PF_CS4 (GPIO_PORTA | GPIO_PF | 22) | ||
| 59 | #define PA23_PF_CS5 (GPIO_PORTA | GPIO_PF | 23) | ||
| 60 | #define PA24_PF_A16 (GPIO_PORTA | GPIO_PF | 24) | ||
| 61 | #define PA24_AF_ETMTRACEPKT0 (GPIO_PORTA | GPIO_AF | 24) | ||
| 62 | #define PA25_PF_A17 (GPIO_PORTA | GPIO_PF | 25) | ||
| 63 | #define PA25_AF_ETMTRACEPKT1 (GPIO_PORTA | GPIO_AF | 25) | ||
| 64 | #define PA26_PF_A18 (GPIO_PORTA | GPIO_PF | 26) | ||
| 65 | #define PA26_AF_ETMTRACEPKT2 (GPIO_PORTA | GPIO_AF | 26) | ||
| 66 | #define PA27_PF_A19 (GPIO_PORTA | GPIO_PF | 27) | ||
| 67 | #define PA27_AF_ETMTRACEPKT3 (GPIO_PORTA | GPIO_AF | 27) | ||
| 68 | #define PA28_PF_A20 (GPIO_PORTA | GPIO_PF | 28) | ||
| 69 | #define PA28_AF_ETMPIPESTAT0 (GPIO_PORTA | GPIO_AF | 28) | ||
| 70 | #define PA29_PF_A21 (GPIO_PORTA | GPIO_PF | 29) | ||
| 71 | #define PA29_AF_ETMPIPESTAT1 (GPIO_PORTA | GPIO_AF | 29) | ||
| 72 | #define PA30_PF_A22 (GPIO_PORTA | GPIO_PF | 30) | ||
| 73 | #define PA30_AF_ETMPIPESTAT2 (GPIO_PORTA | GPIO_AF | 30) | ||
| 74 | #define PA31_PF_A23 (GPIO_PORTA | GPIO_PF | 31) | ||
| 75 | #define PA31_AF_ETMTRACECLK (GPIO_PORTA | GPIO_AF | 31) | ||
| 76 | #define PB8_PF_SD_DAT0 (GPIO_PORTB | GPIO_PF | GPIO_PUEN | 8) | ||
| 77 | #define PB8_AF_MS_PIO (GPIO_PORTB | GPIO_AF | 8) | ||
| 78 | #define PB9_PF_SD_DAT1 (GPIO_PORTB | GPIO_PF | GPIO_PUEN | 9) | ||
| 79 | #define PB9_AF_MS_PI1 (GPIO_PORTB | GPIO_AF | 9) | ||
| 80 | #define PB10_PF_SD_DAT2 (GPIO_PORTB | GPIO_PF | GPIO_PUEN | 10) | ||
| 81 | #define PB10_AF_MS_SCLKI (GPIO_PORTB | GPIO_AF | 10) | ||
| 82 | #define PB11_PF_SD_DAT3 (GPIO_PORTB | GPIO_PF | 11) | ||
| 83 | #define PB11_AF_MS_SDIO (GPIO_PORTB | GPIO_AF | 11) | ||
| 84 | #define PB12_PF_SD_CLK (GPIO_PORTB | GPIO_PF | 12) | ||
| 85 | #define PB12_AF_MS_SCLK0 (GPIO_PORTB | GPIO_AF | 12) | ||
| 86 | #define PB13_PF_SD_CMD (GPIO_PORTB | GPIO_PF | GPIO_PUEN | 13) | ||
| 87 | #define PB13_AF_MS_BS (GPIO_PORTB | GPIO_AF | 13) | ||
| 88 | #define PB14_AF_SSI_RXFS (GPIO_PORTB | GPIO_AF | 14) | ||
| 89 | #define PB15_AF_SSI_RXCLK (GPIO_PORTB | GPIO_AF | 15) | ||
| 90 | #define PB16_AF_SSI_RXDAT (GPIO_PORTB | GPIO_AF | GPIO_IN | 16) | ||
| 91 | #define PB17_AF_SSI_TXDAT (GPIO_PORTB | GPIO_AF | GPIO_OUT | 17) | ||
| 92 | #define PB18_AF_SSI_TXFS (GPIO_PORTB | GPIO_AF | 18) | ||
| 93 | #define PB19_AF_SSI_TXCLK (GPIO_PORTB | GPIO_AF | 19) | ||
| 94 | #define PB20_PF_USBD_AFE (GPIO_PORTB | GPIO_PF | 20) | ||
| 95 | #define PB21_PF_USBD_OE (GPIO_PORTB | GPIO_PF | 21) | ||
| 96 | #define PB22_PF_USBD_RCV (GPIO_PORTB | GPIO_PF | 22) | ||
| 97 | #define PB23_PF_USBD_SUSPND (GPIO_PORTB | GPIO_PF | 23) | ||
| 98 | #define PB24_PF_USBD_VP (GPIO_PORTB | GPIO_PF | 24) | ||
| 99 | #define PB25_PF_USBD_VM (GPIO_PORTB | GPIO_PF | 25) | ||
| 100 | #define PB26_PF_USBD_VPO (GPIO_PORTB | GPIO_PF | 26) | ||
| 101 | #define PB27_PF_USBD_VMO (GPIO_PORTB | GPIO_PF | 27) | ||
| 102 | #define PB28_PF_UART2_CTS (GPIO_PORTB | GPIO_PF | GPIO_OUT | 28) | ||
| 103 | #define PB29_PF_UART2_RTS (GPIO_PORTB | GPIO_PF | GPIO_IN | 29) | ||
| 104 | #define PB30_PF_UART2_TXD (GPIO_PORTB | GPIO_PF | GPIO_OUT | 30) | ||
| 105 | #define PB31_PF_UART2_RXD (GPIO_PORTB | GPIO_PF | GPIO_IN | 31) | ||
| 106 | #define PC3_PF_SSI_RXFS (GPIO_PORTC | GPIO_PF | 3) | ||
| 107 | #define PC4_PF_SSI_RXCLK (GPIO_PORTC | GPIO_PF | 4) | ||
| 108 | #define PC5_PF_SSI_RXDAT (GPIO_PORTC | GPIO_PF | GPIO_IN | 5) | ||
| 109 | #define PC6_PF_SSI_TXDAT (GPIO_PORTC | GPIO_PF | GPIO_OUT | 6) | ||
| 110 | #define PC7_PF_SSI_TXFS (GPIO_PORTC | GPIO_PF | 7) | ||
| 111 | #define PC8_PF_SSI_TXCLK (GPIO_PORTC | GPIO_PF | 8) | ||
| 112 | #define PC9_PF_UART1_CTS (GPIO_PORTC | GPIO_PF | GPIO_OUT | 9) | ||
| 113 | #define PC10_PF_UART1_RTS (GPIO_PORTC | GPIO_PF | GPIO_IN | 10) | ||
| 114 | #define PC11_PF_UART1_TXD (GPIO_PORTC | GPIO_PF | GPIO_OUT | 11) | ||
| 115 | #define PC12_PF_UART1_RXD (GPIO_PORTC | GPIO_PF | GPIO_IN | 12) | ||
| 116 | #define PC13_PF_SPI1_SPI_RDY (GPIO_PORTC | GPIO_PF | 13) | ||
| 117 | #define PC14_PF_SPI1_SCLK (GPIO_PORTC | GPIO_PF | 14) | ||
| 118 | #define PC15_PF_SPI1_SS (GPIO_PORTC | GPIO_PF | 15) | ||
| 119 | #define PC16_PF_SPI1_MISO (GPIO_PORTC | GPIO_PF | 16) | ||
| 120 | #define PC17_PF_SPI1_MOSI (GPIO_PORTC | GPIO_PF | 17) | ||
| 121 | #define PC24_BIN_UART3_RI (GPIO_PORTC | GPIO_BIN | GPIO_OUT | 24) | ||
| 122 | #define PC25_BIN_UART3_DSR (GPIO_PORTC | GPIO_BIN | GPIO_OUT | 25) | ||
| 123 | #define PC26_AOUT_UART3_DTR (GPIO_PORTC | GPIO_AOUT | GPIO_IN | 26) | ||
| 124 | #define PC27_BIN_UART3_DCD (GPIO_PORTC | GPIO_BIN | GPIO_OUT | 27) | ||
| 125 | #define PC28_BIN_UART3_CTS (GPIO_PORTC | GPIO_BIN | GPIO_OUT | 28) | ||
| 126 | #define PC29_AOUT_UART3_RTS (GPIO_PORTC | GPIO_AOUT | GPIO_IN | 29) | ||
| 127 | #define PC30_BIN_UART3_TX (GPIO_PORTC | GPIO_BIN | 30) | ||
| 128 | #define PC31_AOUT_UART3_RX (GPIO_PORTC | GPIO_AOUT | GPIO_IN | 31) | ||
| 129 | #define PD6_PF_LSCLK (GPIO_PORTD | GPIO_PF | GPIO_OUT | 6) | ||
| 130 | #define PD7_PF_REV (GPIO_PORTD | GPIO_PF | 7) | ||
| 131 | #define PD7_AF_UART2_DTR (GPIO_PORTD | GPIO_AF | GPIO_IN | 7) | ||
| 132 | #define PD7_AIN_SPI2_SCLK (GPIO_PORTD | GPIO_AIN | 7) | ||
| 133 | #define PD8_PF_CLS (GPIO_PORTD | GPIO_PF | 8) | ||
| 134 | #define PD8_AF_UART2_DCD (GPIO_PORTD | GPIO_AF | GPIO_OUT | 8) | ||
| 135 | #define PD8_AIN_SPI2_SS (GPIO_PORTD | GPIO_AIN | 8) | ||
| 136 | #define PD9_PF_PS (GPIO_PORTD | GPIO_PF | 9) | ||
| 137 | #define PD9_AF_UART2_RI (GPIO_PORTD | GPIO_AF | GPIO_OUT | 9) | ||
| 138 | #define PD9_AOUT_SPI2_RXD (GPIO_PORTD | GPIO_AOUT | GPIO_IN | 9) | ||
| 139 | #define PD10_PF_SPL_SPR (GPIO_PORTD | GPIO_PF | GPIO_OUT | 10) | ||
| 140 | #define PD10_AF_UART2_DSR (GPIO_PORTD | GPIO_AF | GPIO_OUT | 10) | ||
| 141 | #define PD10_AIN_SPI2_TXD (GPIO_PORTD | GPIO_AIN | GPIO_OUT | 10) | ||
| 142 | #define PD11_PF_CONTRAST (GPIO_PORTD | GPIO_PF | GPIO_OUT | 11) | ||
| 143 | #define PD12_PF_ACD_OE (GPIO_PORTD | GPIO_PF | GPIO_OUT | 12) | ||
| 144 | #define PD13_PF_LP_HSYNC (GPIO_PORTD | GPIO_PF | GPIO_OUT | 13) | ||
| 145 | #define PD14_PF_FLM_VSYNC (GPIO_PORTD | GPIO_PF | GPIO_OUT | 14) | ||
| 146 | #define PD15_PF_LD0 (GPIO_PORTD | GPIO_PF | GPIO_OUT | 15) | ||
| 147 | #define PD16_PF_LD1 (GPIO_PORTD | GPIO_PF | GPIO_OUT | 16) | ||
| 148 | #define PD17_PF_LD2 (GPIO_PORTD | GPIO_PF | GPIO_OUT | 17) | ||
| 149 | #define PD18_PF_LD3 (GPIO_PORTD | GPIO_PF | GPIO_OUT | 18) | ||
| 150 | #define PD19_PF_LD4 (GPIO_PORTD | GPIO_PF | GPIO_OUT | 19) | ||
| 151 | #define PD20_PF_LD5 (GPIO_PORTD | GPIO_PF | GPIO_OUT | 20) | ||
| 152 | #define PD21_PF_LD6 (GPIO_PORTD | GPIO_PF | GPIO_OUT | 21) | ||
| 153 | #define PD22_PF_LD7 (GPIO_PORTD | GPIO_PF | GPIO_OUT | 22) | ||
| 154 | #define PD23_PF_LD8 (GPIO_PORTD | GPIO_PF | GPIO_OUT | 23) | ||
| 155 | #define PD24_PF_LD9 (GPIO_PORTD | GPIO_PF | GPIO_OUT | 24) | ||
| 156 | #define PD25_PF_LD10 (GPIO_PORTD | GPIO_PF | GPIO_OUT | 25) | ||
| 157 | #define PD26_PF_LD11 (GPIO_PORTD | GPIO_PF | GPIO_OUT | 26) | ||
| 158 | #define PD27_PF_LD12 (GPIO_PORTD | GPIO_PF | GPIO_OUT | 27) | ||
| 159 | #define PD28_PF_LD13 (GPIO_PORTD | GPIO_PF | GPIO_OUT | 28) | ||
| 160 | #define PD29_PF_LD14 (GPIO_PORTD | GPIO_PF | GPIO_OUT | 29) | ||
| 161 | #define PD30_PF_LD15 (GPIO_PORTD | GPIO_PF | GPIO_OUT | 30) | ||
| 162 | #define PD31_PF_TMR2OUT (GPIO_PORTD | GPIO_PF | 31) | ||
| 163 | #define PD31_BIN_SPI2_TXD (GPIO_PORTD | GPIO_BIN | 31) | ||
| 164 | |||
| 165 | |||
| 166 | #endif | ||
diff --git a/arch/arm/plat-mxc/include/mach/iomux-mx21.h b/arch/arm/plat-mxc/include/mach/iomux-mx21.h new file mode 100644 index 000000000000..63aaa972e275 --- /dev/null +++ b/arch/arm/plat-mxc/include/mach/iomux-mx21.h | |||
| @@ -0,0 +1,126 @@ | |||
| 1 | /* | ||
| 2 | * Copyright (C) 2009 by Holger Schurig <hs4233@mail.mn-solutions.de> | ||
| 3 | * | ||
| 4 | * This program is free software; you can redistribute it and/or | ||
| 5 | * modify it under the terms of the GNU General Public License | ||
| 6 | * as published by the Free Software Foundation; either version 2 | ||
| 7 | * of the License, or (at your option) any later version. | ||
| 8 | * This program is distributed in the hope that it will be useful, | ||
| 9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 11 | * GNU General Public License for more details. | ||
| 12 | * | ||
| 13 | * You should have received a copy of the GNU General Public License | ||
| 14 | * along with this program; if not, write to the Free Software | ||
| 15 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, | ||
| 16 | * MA 02110-1301, USA. | ||
| 17 | */ | ||
| 18 | |||
| 19 | #ifndef _MXC_IOMUX_MX21_H | ||
| 20 | #define _MXC_IOMUX_MX21_H | ||
| 21 | |||
| 22 | #ifndef GPIO_PORTA | ||
| 23 | #error Please include mach/iomux.h | ||
| 24 | #endif | ||
| 25 | |||
| 26 | |||
| 27 | /* Primary GPIO pin functions */ | ||
| 28 | |||
| 29 | #define PB22_PF_USBH1_BYP (GPIO_PORTB | GPIO_PF | 22) | ||
| 30 | #define PB25_PF_USBH1_ON (GPIO_PORTB | GPIO_PF | 25) | ||
| 31 | #define PC5_PF_USBOTG_SDA (GPIO_PORTC | GPIO_PF | 5) | ||
| 32 | #define PC6_PF_USBOTG_SCL (GPIO_PORTC | GPIO_PF | 6) | ||
| 33 | #define PC7_PF_USBOTG_ON (GPIO_PORTC | GPIO_PF | 7) | ||
| 34 | #define PC8_PF_USBOTG_FS (GPIO_PORTC | GPIO_PF | 8) | ||
| 35 | #define PC9_PF_USBOTG_OE (GPIO_PORTC | GPIO_PF | 9) | ||
| 36 | #define PC10_PF_USBOTG_TXDM (GPIO_PORTC | GPIO_PF | 10) | ||
| 37 | #define PC11_PF_USBOTG_TXDP (GPIO_PORTC | GPIO_PF | 11) | ||
| 38 | #define PC12_PF_USBOTG_RXDM (GPIO_PORTC | GPIO_PF | 12) | ||
| 39 | #define PC13_PF_USBOTG_RXDP (GPIO_PORTC | GPIO_PF | 13) | ||
| 40 | #define PC16_PF_SAP_FS (GPIO_PORTC | GPIO_PF | 16) | ||
| 41 | #define PC17_PF_SAP_RXD (GPIO_PORTC | GPIO_PF | 17) | ||
| 42 | #define PC18_PF_SAP_TXD (GPIO_PORTC | GPIO_PF | 18) | ||
| 43 | #define PC19_PF_SAP_CLK (GPIO_PORTC | GPIO_PF | 19) | ||
| 44 | #define PE0_PF_TEST_WB2 (GPIO_PORTE | GPIO_PF | 0) | ||
| 45 | #define PE1_PF_TEST_WB1 (GPIO_PORTE | GPIO_PF | 1) | ||
| 46 | #define PE2_PF_TEST_WB0 (GPIO_PORTE | GPIO_PF | 2) | ||
| 47 | #define PF1_PF_NFCE (GPIO_PORTF | GPIO_PF | 1) | ||
| 48 | #define PF3_PF_NFCLE (GPIO_PORTF | GPIO_PF | 3) | ||
| 49 | #define PF7_PF_NFIO0 (GPIO_PORTF | GPIO_PF | 7) | ||
| 50 | #define PF8_PF_NFIO1 (GPIO_PORTF | GPIO_PF | 8) | ||
| 51 | #define PF9_PF_NFIO2 (GPIO_PORTF | GPIO_PF | 9) | ||
| 52 | #define PF10_PF_NFIO3 (GPIO_PORTF | GPIO_PF | 10) | ||
| 53 | #define PF11_PF_NFIO4 (GPIO_PORTF | GPIO_PF | 11) | ||
| 54 | #define PF12_PF_NFIO5 (GPIO_PORTF | GPIO_PF | 12) | ||
| 55 | #define PF13_PF_NFIO6 (GPIO_PORTF | GPIO_PF | 13) | ||
| 56 | #define PF14_PF_NFIO7 (GPIO_PORTF | GPIO_PF | 14) | ||
| 57 | #define PF16_PF_RES (GPIO_PORTF | GPIO_PF | 16) | ||
| 58 | |||
| 59 | /* Alternate GPIO pin functions */ | ||
| 60 | |||
| 61 | #define PA5_AF_BMI_CLK_CS (GPIO_PORTA | GPIO_AF | 5) | ||
| 62 | #define PA6_AF_BMI_D0 (GPIO_PORTA | GPIO_AF | 6) | ||
| 63 | #define PA7_AF_BMI_D1 (GPIO_PORTA | GPIO_AF | 7) | ||
| 64 | #define PA8_AF_BMI_D2 (GPIO_PORTA | GPIO_AF | 8) | ||
| 65 | #define PA9_AF_BMI_D3 (GPIO_PORTA | GPIO_AF | 9) | ||
| 66 | #define PA10_AF_BMI_D4 (GPIO_PORTA | GPIO_AF | 10) | ||
| 67 | #define PA11_AF_BMI_D5 (GPIO_PORTA | GPIO_AF | 11) | ||
| 68 | #define PA12_AF_BMI_D6 (GPIO_PORTA | GPIO_AF | 12) | ||
| 69 | #define PA13_AF_BMI_D7 (GPIO_PORTA | GPIO_AF | 13) | ||
| 70 | #define PA14_AF_BMI_D8 (GPIO_PORTA | GPIO_AF | 14) | ||
| 71 | #define PA15_AF_BMI_D9 (GPIO_PORTA | GPIO_AF | 15) | ||
| 72 | #define PA16_AF_BMI_D10 (GPIO_PORTA | GPIO_AF | 16) | ||
| 73 | #define PA17_AF_BMI_D11 (GPIO_PORTA | GPIO_AF | 17) | ||
| 74 | #define PA18_AF_BMI_D12 (GPIO_PORTA | GPIO_AF | 18) | ||
| 75 | #define PA19_AF_BMI_D13 (GPIO_PORTA | GPIO_AF | 19) | ||
| 76 | #define PA20_AF_BMI_D14 (GPIO_PORTA | GPIO_AF | 20) | ||
| 77 | #define PA21_AF_BMI_D15 (GPIO_PORTA | GPIO_AF | 21) | ||
| 78 | #define PA22_AF_BMI_READ_REQ (GPIO_PORTA | GPIO_AF | 22) | ||
| 79 | #define PA23_AF_BMI_WRITE (GPIO_PORTA | GPIO_AF | 23) | ||
| 80 | #define PA29_AF_BMI_RX_FULL (GPIO_PORTA | GPIO_AF | 29) | ||
| 81 | #define PA30_AF_BMI_READ (GPIO_PORTA | GPIO_AF | 30) | ||
| 82 | |||
| 83 | /* AIN GPIO pin functions */ | ||
| 84 | |||
| 85 | #define PC14_AIN_SYS_CLK (GPIO_PORTC | GPIO_AIN | GPIO_OUT | 14) | ||
| 86 | #define PD21_AIN_USBH2_FS (GPIO_PORTD | GPIO_AIN | GPIO_OUT | 21) | ||
| 87 | #define PD22_AIN_USBH2_OE (GPIO_PORTD | GPIO_AIN | GPIO_OUT | 22) | ||
| 88 | #define PD23_AIN_USBH2_TXDM (GPIO_PORTD | GPIO_AIN | GPIO_OUT | 23) | ||
| 89 | #define PD24_AIN_USBH2_TXDP (GPIO_PORTD | GPIO_AIN | GPIO_OUT | 24) | ||
| 90 | #define PE8_AIN_IR_TXD (GPIO_PORTE | GPIO_AIN | GPIO_OUT | 8) | ||
| 91 | #define PF0_AIN_PC_RST (GPIO_PORTF | GPIO_AIN | GPIO_OUT | 0) | ||
| 92 | #define PF1_AIN_PC_CE1 (GPIO_PORTF | GPIO_AIN | GPIO_OUT | 1) | ||
| 93 | #define PF2_AIN_PC_CE2 (GPIO_PORTF | GPIO_AIN | GPIO_OUT | 2) | ||
| 94 | #define PF3_AIN_PC_POE (GPIO_PORTF | GPIO_AIN | GPIO_OUT | 3) | ||
| 95 | #define PF4_AIN_PC_OE (GPIO_PORTF | GPIO_AIN | GPIO_OUT | 4) | ||
| 96 | #define PF5_AIN_PC_RW (GPIO_PORTF | GPIO_AIN | GPIO_OUT | 5) | ||
| 97 | |||
| 98 | /* BIN GPIO pin functions */ | ||
| 99 | |||
| 100 | #define PC14_BIN_SYS_CLK (GPIO_PORTC | GPIO_BIN | GPIO_OUT | 14) | ||
| 101 | #define PD27_BIN_EXT_DMA_GRANT (GPIO_PORTD | GPIO_BIN | GPIO_OUT | 27) | ||
| 102 | |||
| 103 | /* CIN GPIO pin functions */ | ||
| 104 | |||
| 105 | #define PB26_CIN_USBH1_RXDAT (GPIO_PORTB | GPIO_CIN | GPIO_OUT | 26) | ||
| 106 | |||
| 107 | /* AOUT GPIO pin functions */ | ||
| 108 | |||
| 109 | #define PA29_AOUT_BMI_WAIT (GPIO_PORTA | GPIO_AOUT | GPIO_IN | 29) | ||
| 110 | #define PD19_AOUT_USBH2_RXDM (GPIO_PORTD | GPIO_AOUT | GPIO_IN | 19) | ||
| 111 | #define PD20_AOUT_USBH2_RXDP (GPIO_PORTD | GPIO_AOUT | GPIO_IN | 20) | ||
| 112 | #define PD25_AOUT_EXT_DMAREQ (GPIO_PORTD | GPIO_AOUT | GPIO_IN | 25) | ||
| 113 | #define PD26_AOUT_USBOTG_RXDAT (GPIO_PORTD | GPIO_AOUT | GPIO_IN | 26) | ||
| 114 | #define PE9_AOUT_IR_RXD (GPIO_PORTE | GPIO_AOUT | GPIO_IN | 9) | ||
| 115 | #define PF6_AOUT_PC_BVD2 (GPIO_PORTF | GPIO_AOUT | GPIO_IN | 6) | ||
| 116 | #define PF7_AOUT_PC_BVD1 (GPIO_PORTF | GPIO_AOUT | GPIO_IN | 7) | ||
| 117 | #define PF8_AOUT_PC_VS2 (GPIO_PORTF | GPIO_AOUT | GPIO_IN | 8) | ||
| 118 | #define PF9_AOUT_PC_VS1 (GPIO_PORTF | GPIO_AOUT | GPIO_IN | 9) | ||
| 119 | #define PF10_AOUT_PC_WP (GPIO_PORTF | GPIO_AOUT | GPIO_IN | 10) | ||
| 120 | #define PF11_AOUT_PC_READY (GPIO_PORTF | GPIO_AOUT | GPIO_IN | 11) | ||
| 121 | #define PF12_AOUT_PC_WAIT (GPIO_PORTF | GPIO_AOUT | GPIO_IN | 12) | ||
| 122 | #define PF13_AOUT_PC_CD2 (GPIO_PORTF | GPIO_AOUT | GPIO_IN | 13) | ||
| 123 | #define PF14_AOUT_PC_CD1 (GPIO_PORTF | GPIO_AOUT | GPIO_IN | 14) | ||
| 124 | |||
| 125 | |||
| 126 | #endif | ||
diff --git a/arch/arm/plat-mxc/include/mach/iomux-mx27.h b/arch/arm/plat-mxc/include/mach/iomux-mx27.h new file mode 100644 index 000000000000..5ac158b70f61 --- /dev/null +++ b/arch/arm/plat-mxc/include/mach/iomux-mx27.h | |||
| @@ -0,0 +1,207 @@ | |||
| 1 | /* | ||
| 2 | * Copyright (C) 2008 by Sascha Hauer <kernel@pengutronix.de> | ||
| 3 | * Copyright (C) 2009 by Holger Schurig <hs4233@mail.mn-solutions.de> | ||
| 4 | * | ||
| 5 | * This program is free software; you can redistribute it and/or | ||
| 6 | * modify it under the terms of the GNU General Public License | ||
| 7 | * as published by the Free Software Foundation; either version 2 | ||
| 8 | * of the License, or (at your option) any later version. | ||
| 9 | * This program is distributed in the hope that it will be useful, | ||
| 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 12 | * GNU General Public License for more details. | ||
| 13 | * | ||
| 14 | * You should have received a copy of the GNU General Public License | ||
| 15 | * along with this program; if not, write to the Free Software | ||
| 16 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, | ||
| 17 | * MA 02110-1301, USA. | ||
| 18 | */ | ||
| 19 | |||
| 20 | #ifndef _MXC_IOMUX_MX27_H | ||
| 21 | #define _MXC_IOMUX_MX27_H | ||
| 22 | |||
| 23 | #ifndef GPIO_PORTA | ||
| 24 | #error Please include mach/iomux.h | ||
| 25 | #endif | ||
| 26 | |||
| 27 | |||
| 28 | /* Primary GPIO pin functions */ | ||
| 29 | |||
| 30 | #define PA0_PF_USBH2_CLK (GPIO_PORTA | GPIO_PF | 0) | ||
| 31 | #define PA1_PF_USBH2_DIR (GPIO_PORTA | GPIO_PF | 1) | ||
| 32 | #define PA2_PF_USBH2_DATA7 (GPIO_PORTA | GPIO_PF | 2) | ||
| 33 | #define PA3_PF_USBH2_NXT (GPIO_PORTA | GPIO_PF | 3) | ||
| 34 | #define PA4_PF_USBH2_STP (GPIO_PORTA | GPIO_PF | 4) | ||
| 35 | #define PB22_PF_USBH1_SUSP (GPIO_PORTB | GPIO_PF | 22) | ||
| 36 | #define PB25_PF_USBH1_RCV (GPIO_PORTB | GPIO_PF | 25) | ||
| 37 | #define PC5_PF_I2C2_SDA (GPIO_PORTC | GPIO_PF | GPIO_IN | 5) | ||
| 38 | #define PC6_PF_I2C2_SCL (GPIO_PORTC | GPIO_PF | GPIO_IN | 6) | ||
| 39 | #define PC7_PF_USBOTG_DATA5 (GPIO_PORTC | GPIO_PF | GPIO_OUT | 7) | ||
| 40 | #define PC8_PF_USBOTG_DATA6 (GPIO_PORTC | GPIO_PF | GPIO_OUT | 8) | ||
| 41 | #define PC9_PF_USBOTG_DATA0 (GPIO_PORTC | GPIO_PF | GPIO_OUT | 9) | ||
| 42 | #define PC10_PF_USBOTG_DATA2 (GPIO_PORTC | GPIO_PF | GPIO_OUT | 10) | ||
| 43 | #define PC11_PF_USBOTG_DATA1 (GPIO_PORTC | GPIO_PF | GPIO_OUT | 11) | ||
| 44 | #define PC12_PF_USBOTG_DATA4 (GPIO_PORTC | GPIO_PF | GPIO_OUT | 12) | ||
| 45 | #define PC13_PF_USBOTG_DATA3 (GPIO_PORTC | GPIO_PF | GPIO_OUT | 13) | ||
| 46 | #define PC16_PF_SSI4_FS (GPIO_PORTC | GPIO_PF | GPIO_IN | 16) | ||
| 47 | #define PC17_PF_SSI4_RXD (GPIO_PORTC | GPIO_PF | GPIO_IN | 17) | ||
| 48 | #define PC18_PF_SSI4_TXD (GPIO_PORTC | GPIO_PF | GPIO_IN | 18) | ||
| 49 | #define PC19_PF_SSI4_CLK (GPIO_PORTC | GPIO_PF | GPIO_IN | 19) | ||
| 50 | #define PC25_AF_GPT5_TIN (GPIO_PORTC | GPIO_AF | 25) | ||
| 51 | #define PC27_AF_GPT4_TIN (GPIO_PORTC | GPIO_AF | 27) | ||
| 52 | #define PD0_PF_SD3_CMD (GPIO_PORTD | GPIO_PF | 0) | ||
| 53 | #define PD1_PF_SD3_CLK (GPIO_PORTD | GPIO_PF | 1) | ||
| 54 | #define PD2_PF_ATA_DATA0 (GPIO_PORTD | GPIO_PF | 2) | ||
| 55 | #define PD3_PF_ATA_DATA1 (GPIO_PORTD | GPIO_PF | 3) | ||
| 56 | #define PD4_PF_ATA_DATA2 (GPIO_PORTD | GPIO_PF | 4) | ||
| 57 | #define PD5_PF_ATA_DATA3 (GPIO_PORTD | GPIO_PF | 5) | ||
| 58 | #define PD6_PF_ATA_DATA4 (GPIO_PORTD | GPIO_PF | 6) | ||
| 59 | #define PD7_PF_ATA_DATA5 (GPIO_PORTD | GPIO_PF | 7) | ||
| 60 | #define PD8_PF_ATA_DATA6 (GPIO_PORTD | GPIO_PF | 8) | ||
| 61 | #define PD9_PF_ATA_DATA7 (GPIO_PORTD | GPIO_PF | 9) | ||
| 62 | #define PD10_PF_ATA_DATA8 (GPIO_PORTD | GPIO_PF | 10) | ||
| 63 | #define PD11_PF_ATA_DATA9 (GPIO_PORTD | GPIO_PF | 11) | ||
| 64 | #define PD12_PF_ATA_DATA10 (GPIO_PORTD | GPIO_PF | 12) | ||
| 65 | #define PD13_PF_ATA_DATA11 (GPIO_PORTD | GPIO_PF | 13) | ||
| 66 | #define PD14_PF_ATA_DATA12 (GPIO_PORTD | GPIO_PF | 14) | ||
| 67 | #define PD15_PF_ATA_DATA13 (GPIO_PORTD | GPIO_PF | 15) | ||
| 68 | #define PD16_PF_ATA_DATA14 (GPIO_PORTD | GPIO_PF | 16) | ||
| 69 | #define PE0_PF_USBOTG_NXT (GPIO_PORTE | GPIO_PF | GPIO_OUT | 0) | ||
| 70 | #define PE1_PF_USBOTG_STP (GPIO_PORTE | GPIO_PF | GPIO_OUT | 1) | ||
| 71 | #define PE2_PF_USBOTG_DIR (GPIO_PORTE | GPIO_PF | GPIO_OUT | 2) | ||
| 72 | #define PE24_PF_USBOTG_CLK (GPIO_PORTE | GPIO_PF | GPIO_OUT | 24) | ||
| 73 | #define PE25_PF_USBOTG_DATA7 (GPIO_PORTE | GPIO_PF | GPIO_OUT | 25) | ||
| 74 | #define PF1_PF_NFCLE (GPIO_PORTF | GPIO_PF | 1) | ||
| 75 | #define PF3_PF_NFCE (GPIO_PORTF | GPIO_PF | 3) | ||
| 76 | #define PF7_PF_PC_POE (GPIO_PORTF | GPIO_PF | 7) | ||
| 77 | #define PF8_PF_PC_RW (GPIO_PORTF | GPIO_PF | 8) | ||
| 78 | #define PF9_PF_PC_IOIS16 (GPIO_PORTF | GPIO_PF | 9) | ||
| 79 | #define PF10_PF_PC_RST (GPIO_PORTF | GPIO_PF | 10) | ||
| 80 | #define PF11_PF_PC_BVD2 (GPIO_PORTF | GPIO_PF | 11) | ||
| 81 | #define PF12_PF_PC_BVD1 (GPIO_PORTF | GPIO_PF | 12) | ||
| 82 | #define PF13_PF_PC_VS2 (GPIO_PORTF | GPIO_PF | 13) | ||
| 83 | #define PF14_PF_PC_VS1 (GPIO_PORTF | GPIO_PF | 14) | ||
| 84 | #define PF16_PF_PC_PWRON (GPIO_PORTF | GPIO_PF | 16) | ||
| 85 | #define PF17_PF_PC_READY (GPIO_PORTF | GPIO_PF | 17) | ||
| 86 | #define PF18_PF_PC_WAIT (GPIO_PORTF | GPIO_PF | 18) | ||
| 87 | #define PF19_PF_PC_CD2 (GPIO_PORTF | GPIO_PF | 19) | ||
| 88 | #define PF20_PF_PC_CD1 (GPIO_PORTF | GPIO_PF | 20) | ||
| 89 | #define PF23_PF_ATA_DATA15 (GPIO_PORTF | GPIO_PF | 23) | ||
| 90 | |||
| 91 | /* Alternate GPIO pin functions */ | ||
| 92 | |||
| 93 | #define PB4_AF_MSHC_DATA0 (GPIO_PORTB | GPIO_AF | GPIO_OUT | 4) | ||
| 94 | #define PB5_AF_MSHC_DATA1 (GPIO_PORTB | GPIO_AF | GPIO_OUT | 5) | ||
| 95 | #define PB6_AF_MSHC_DATA2 (GPIO_PORTB | GPIO_AF | GPIO_OUT | 6) | ||
| 96 | #define PB7_AF_MSHC_DATA4 (GPIO_PORTB | GPIO_AF | GPIO_OUT | 7) | ||
| 97 | #define PB8_AF_MSHC_BS (GPIO_PORTB | GPIO_AF | GPIO_OUT | 8) | ||
| 98 | #define PB9_AF_MSHC_SCLK (GPIO_PORTB | GPIO_AF | GPIO_OUT | 9) | ||
| 99 | #define PB10_AF_UART6_TXD (GPIO_PORTB | GPIO_AF | GPIO_OUT | 10) | ||
| 100 | #define PB11_AF_UART6_RXD (GPIO_PORTB | GPIO_AF | GPIO_IN | 11) | ||
| 101 | #define PB12_AF_UART6_CTS (GPIO_PORTB | GPIO_AF | GPIO_OUT | 12) | ||
| 102 | #define PB13_AF_UART6_RTS (GPIO_PORTB | GPIO_AF | GPIO_IN | 13) | ||
| 103 | #define PB18_AF_UART5_TXD (GPIO_PORTB | GPIO_AF | GPIO_OUT | 18) | ||
| 104 | #define PB19_AF_UART5_RXD (GPIO_PORTB | GPIO_AF | GPIO_IN | 19) | ||
| 105 | #define PB20_AF_UART5_CTS (GPIO_PORTB | GPIO_AF | GPIO_OUT | 20) | ||
| 106 | #define PB21_AF_UART5_RTS (GPIO_PORTB | GPIO_AF | GPIO_IN | 21) | ||
| 107 | #define PC8_AF_FEC_MDIO (GPIO_PORTC | GPIO_AF | GPIO_IN | 8) | ||
| 108 | #define PC24_AF_GPT5_TOUT (GPIO_PORTC | GPIO_AF | 24) | ||
| 109 | #define PC26_AF_GPT4_TOUT (GPIO_PORTC | GPIO_AF | 26) | ||
| 110 | #define PD1_AF_ETMTRACE_PKT15 (GPIO_PORTD | GPIO_AF | 1) | ||
| 111 | #define PD6_AF_ETMTRACE_PKT14 (GPIO_PORTD | GPIO_AF | 6) | ||
| 112 | #define PD7_AF_ETMTRACE_PKT13 (GPIO_PORTD | GPIO_AF | 7) | ||
| 113 | #define PD9_AF_ETMTRACE_PKT12 (GPIO_PORTD | GPIO_AF | 9) | ||
| 114 | #define PD2_AF_SD3_D0 (GPIO_PORTD | GPIO_AF | 2) | ||
| 115 | #define PD3_AF_SD3_D1 (GPIO_PORTD | GPIO_AF | 3) | ||
| 116 | #define PD4_AF_SD3_D2 (GPIO_PORTD | GPIO_AF | 4) | ||
| 117 | #define PD5_AF_SD3_D3 (GPIO_PORTD | GPIO_AF | 5) | ||
| 118 | #define PD8_AF_FEC_MDIO (GPIO_PORTD | GPIO_AF | GPIO_IN | 8) | ||
| 119 | #define PD10_AF_ETMTRACE_PKT11 (GPIO_PORTD | GPIO_AF | 10) | ||
| 120 | #define PD11_AF_ETMTRACE_PKT10 (GPIO_PORTD | GPIO_AF | 11) | ||
| 121 | #define PD12_AF_ETMTRACE_PKT9 (GPIO_PORTD | GPIO_AF | 12) | ||
| 122 | #define PD13_AF_ETMTRACE_PKT8 (GPIO_PORTD | GPIO_AF | 13) | ||
| 123 | #define PD14_AF_ETMTRACE_PKT7 (GPIO_PORTD | GPIO_AF | 14) | ||
| 124 | #define PD15_AF_ETMTRACE_PKT6 (GPIO_PORTD | GPIO_AF | 15) | ||
| 125 | #define PD16_AF_ETMTRACE_PKT5 (GPIO_PORTD | GPIO_AF | 16) | ||
| 126 | #define PF1_AF_ETMTRACE_PKT0 (GPIO_PORTF | GPIO_AF | 1) | ||
| 127 | #define PF3_AF_ETMTRACE_PKT2 (GPIO_PORTF | GPIO_AF | 3) | ||
| 128 | #define PF5_AF_ETMPIPESTAT11 (GPIO_PORTF | GPIO_AF | 5) | ||
| 129 | #define PF7_AF_ATA_BUFFER_EN (GPIO_PORTF | GPIO_AF | 7) | ||
| 130 | #define PF8_AF_ATA_IORDY (GPIO_PORTF | GPIO_AF | 8) | ||
| 131 | #define PF9_AF_ATA_INTRQ (GPIO_PORTF | GPIO_AF | 9) | ||
| 132 | #define PF10_AF_ATA_RESET (GPIO_PORTF | GPIO_AF | 10) | ||
| 133 | #define PF11_AF_ATA_DMACK (GPIO_PORTF | GPIO_AF | 11) | ||
| 134 | #define PF12_AF_ATA_DMAREQ (GPIO_PORTF | GPIO_AF | 12) | ||
| 135 | #define PF13_AF_ATA_DA0 (GPIO_PORTF | GPIO_AF | 13) | ||
| 136 | #define PF14_AF_ATA_DA1 (GPIO_PORTF | GPIO_AF | 14) | ||
| 137 | #define PF15_AF_ETMTRACE_SYNC (GPIO_PORTF | GPIO_AF | 15) | ||
| 138 | #define PF16_AF_ATA_DA2 (GPIO_PORTF | GPIO_AF | 16) | ||
| 139 | #define PF17_AF_ATA_CS0 (GPIO_PORTF | GPIO_AF | 17) | ||
| 140 | #define PF18_AF_ATA_CS1 (GPIO_PORTF | GPIO_AF | 18) | ||
| 141 | #define PF19_AF_ATA_DIOW (GPIO_PORTF | GPIO_AF | 19) | ||
| 142 | #define PF20_AF_ATA_DIOR (GPIO_PORTF | GPIO_AF | 20) | ||
| 143 | #define PF22_AF_ETMTRACE_CLK (GPIO_PORTF | GPIO_AF | 22) | ||
| 144 | #define PF23_AF_ETMTRACE_PKT4 (GPIO_PORTF | GPIO_AF | 23) | ||
| 145 | |||
| 146 | /* AIN GPIO pin functions */ | ||
| 147 | |||
| 148 | #define PC14_AIN_SSI1_MCLK (GPIO_PORTC | GPIO_AIN | GPIO_OUT | 14) | ||
| 149 | #define PC15_AIN_GPT6_TOUT (GPIO_PORTC | GPIO_AIN | GPIO_OUT | 15) | ||
| 150 | #define PD0_AIN_FEC_TXD0 (GPIO_PORTD | GPIO_AIN | GPIO_OUT | 0) | ||
| 151 | #define PD1_AIN_FEC_TXD1 (GPIO_PORTD | GPIO_AIN | GPIO_OUT | 1) | ||
| 152 | #define PD2_AIN_FEC_TXD2 (GPIO_PORTD | GPIO_AIN | GPIO_OUT | 2) | ||
| 153 | #define PD3_AIN_FEC_TXD3 (GPIO_PORTD | GPIO_AIN | GPIO_OUT | 3) | ||
| 154 | #define PD9_AIN_FEC_MDC (GPIO_PORTD | GPIO_AIN | GPIO_OUT | 9) | ||
| 155 | #define PD16_AIN_FEC_TX_ER (GPIO_PORTD | GPIO_AIN | GPIO_OUT | 16) | ||
| 156 | #define PD27_AIN_EXT_DMA_GRANT (GPIO_PORTD | GPIO_AIN | GPIO_OUT | 27) | ||
| 157 | #define PF23_AIN_FEC_TX_EN (GPIO_PORTF | GPIO_AIN | GPIO_OUT | 23) | ||
| 158 | |||
| 159 | /* BIN GPIO pin functions */ | ||
| 160 | |||
| 161 | #define PC14_BIN_SSI2_MCLK (GPIO_PORTC | GPIO_BIN | GPIO_OUT | 14) | ||
| 162 | |||
| 163 | /* CIN GPIO pin functions */ | ||
| 164 | |||
| 165 | #define PD2_CIN_SLCDC1_DAT0 (GPIO_PORTD | GPIO_CIN | GPIO_OUT | 2) | ||
| 166 | #define PD3_CIN_SLCDC1_DAT1 (GPIO_PORTD | GPIO_CIN | GPIO_OUT | 3) | ||
| 167 | #define PD4_CIN_SLCDC1_DAT2 (GPIO_PORTD | GPIO_CIN | GPIO_OUT | 4) | ||
| 168 | #define PD5_CIN_SLCDC1_DAT3 (GPIO_PORTD | GPIO_CIN | GPIO_OUT | 5) | ||
| 169 | #define PD6_CIN_SLCDC1_DAT4 (GPIO_PORTD | GPIO_CIN | GPIO_OUT | 6) | ||
| 170 | #define PD7_CIN_SLCDC1_DAT5 (GPIO_PORTD | GPIO_CIN | GPIO_OUT | 7) | ||
| 171 | #define PD8_CIN_SLCDC1_DAT6 (GPIO_PORTD | GPIO_CIN | GPIO_OUT | 8) | ||
| 172 | #define PD9_CIN_SLCDC1_DAT7 (GPIO_PORTD | GPIO_CIN | GPIO_OUT | 9) | ||
| 173 | #define PD10_CIN_SLCDC1_DAT8 (GPIO_PORTD | GPIO_CIN | GPIO_OUT | 10) | ||
| 174 | #define PD11_CIN_SLCDC1_DAT9 (GPIO_PORTD | GPIO_CIN | GPIO_OUT | 11) | ||
| 175 | #define PD12_CIN_SLCDC1_DAT10 (GPIO_PORTD | GPIO_CIN | GPIO_OUT | 12) | ||
| 176 | #define PD13_CIN_SLCDC1_DAT11 (GPIO_PORTD | GPIO_CIN | GPIO_OUT | 13) | ||
| 177 | #define PD14_CIN_SLCDC1_DAT12 (GPIO_PORTD | GPIO_CIN | GPIO_OUT | 14) | ||
| 178 | #define PD15_CIN_SLCDC1_DAT13 (GPIO_PORTD | GPIO_CIN | GPIO_OUT | 15) | ||
| 179 | #define PD16_CIN_SLCDC1_DAT14 (GPIO_PORTD | GPIO_CIN | GPIO_OUT | 16) | ||
| 180 | #define PD23_CIN_SLCDC1_DAT15 (GPIO_PORTD | GPIO_CIN | GPIO_OUT | 23) | ||
| 181 | #define PF27_CIN_EXT_DMA_GRANT (GPIO_PORTF | GPIO_CIN | GPIO_OUT | 27) | ||
| 182 | /* LCDC_TESTx on PBxx omitted, because it's not clear what they do */ | ||
| 183 | |||
| 184 | /* AOUT GPIO pin functions */ | ||
| 185 | |||
| 186 | #define PC14_AOUT_GPT6_TIN (GPIO_PORTC | GPIO_AOUT | GPIO_IN | 14) | ||
| 187 | #define PD4_AOUT_FEC_RX_ER (GPIO_PORTD | GPIO_AOUT | GPIO_IN | 4) | ||
| 188 | #define PD5_AOUT_FEC_RXD1 (GPIO_PORTD | GPIO_AOUT | GPIO_IN | 5) | ||
| 189 | #define PD6_AOUT_FEC_RXD2 (GPIO_PORTD | GPIO_AOUT | GPIO_IN | 6) | ||
| 190 | #define PD7_AOUT_FEC_RXD3 (GPIO_PORTD | GPIO_AOUT | GPIO_IN | 7) | ||
| 191 | #define PD10_AOUT_FEC_CRS (GPIO_PORTD | GPIO_AOUT | GPIO_IN | 10) | ||
| 192 | #define PD11_AOUT_FEC_TX_CLK (GPIO_PORTD | GPIO_AOUT | GPIO_IN | 11) | ||
| 193 | #define PD12_AOUT_FEC_RXD0 (GPIO_PORTD | GPIO_AOUT | GPIO_IN | 12) | ||
| 194 | #define PD13_AOUT_FEC_RX_DV (GPIO_PORTD | GPIO_AOUT | GPIO_IN | 13) | ||
| 195 | #define PD14_AOUT_FEC_RX_CLK (GPIO_PORTD | GPIO_AOUT | GPIO_IN | 14) | ||
| 196 | #define PD15_AOUT_FEC_COL (GPIO_PORTD | GPIO_AOUT | GPIO_IN | 15) | ||
| 197 | |||
| 198 | #define PC17_BOUT_PC_IOIS16 (GPIO_PORTC | GPIO_BOUT | GPIO_IN | 17) | ||
| 199 | #define PC18_BOUT_PC_BVD2 (GPIO_PORTC | GPIO_BOUT | GPIO_IN | 18) | ||
| 200 | #define PC19_BOUT_PC_BVD1 (GPIO_PORTC | GPIO_BOUT | GPIO_IN | 19) | ||
| 201 | #define PC28_BOUT_PC_BVD2 (GPIO_PORTC | GPIO_BOUT | GPIO_IN | 28) | ||
| 202 | #define PC29_BOUT_PC_VS1 (GPIO_PORTC | GPIO_BOUT | GPIO_IN | 29) | ||
| 203 | #define PC30_BOUT_PC_READY (GPIO_PORTC | GPIO_BOUT | GPIO_IN | 30) | ||
| 204 | #define PC31_BOUT_PC_WAIT (GPIO_PORTC | GPIO_BOUT | GPIO_IN | 31) | ||
| 205 | |||
| 206 | |||
| 207 | #endif /* _MXC_GPIO_MX1_MX2_H */ | ||
diff --git a/arch/arm/plat-mxc/include/mach/iomux-mx2x.h b/arch/arm/plat-mxc/include/mach/iomux-mx2x.h new file mode 100644 index 000000000000..fb5ae638e79f --- /dev/null +++ b/arch/arm/plat-mxc/include/mach/iomux-mx2x.h | |||
| @@ -0,0 +1,237 @@ | |||
| 1 | /* | ||
| 2 | * Copyright (C) 2008 by Sascha Hauer <kernel@pengutronix.de> | ||
| 3 | * Copyright (C) 2009 by Holger Schurig <hs4233@mail.mn-solutions.de> | ||
| 4 | * | ||
| 5 | * This program is free software; you can redistribute it and/or | ||
| 6 | * modify it under the terms of the GNU General Public License | ||
| 7 | * as published by the Free Software Foundation; either version 2 | ||
| 8 | * of the License, or (at your option) any later version. | ||
| 9 | * This program is distributed in the hope that it will be useful, | ||
| 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 12 | * GNU General Public License for more details. | ||
| 13 | * | ||
| 14 | * You should have received a copy of the GNU General Public License | ||
| 15 | * along with this program; if not, write to the Free Software | ||
| 16 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, | ||
| 17 | * MA 02110-1301, USA. | ||
| 18 | */ | ||
| 19 | |||
| 20 | #ifndef _MXC_IOMUX_MX2x_H | ||
| 21 | #define _MXC_IOMUX_MX2x_H | ||
| 22 | |||
| 23 | #ifndef GPIO_PORTA | ||
| 24 | #error Please include mach/iomux.h | ||
| 25 | #endif | ||
| 26 | |||
| 27 | |||
| 28 | /* Primary GPIO pin functions */ | ||
| 29 | |||
| 30 | #define PA5_PF_LSCLK (GPIO_PORTA | GPIO_PF | GPIO_OUT | 5) | ||
| 31 | #define PA6_PF_LD0 (GPIO_PORTA | GPIO_PF | GPIO_OUT | 6) | ||
| 32 | #define PA7_PF_LD1 (GPIO_PORTA | GPIO_PF | GPIO_OUT | 7) | ||
| 33 | #define PA8_PF_LD2 (GPIO_PORTA | GPIO_PF | GPIO_OUT | 8) | ||
| 34 | #define PA9_PF_LD3 (GPIO_PORTA | GPIO_PF | GPIO_OUT | 9) | ||
| 35 | #define PA10_PF_LD4 (GPIO_PORTA | GPIO_PF | GPIO_OUT | 10) | ||
| 36 | #define PA11_PF_LD5 (GPIO_PORTA | GPIO_PF | GPIO_OUT | 11) | ||
| 37 | #define PA12_PF_LD6 (GPIO_PORTA | GPIO_PF | GPIO_OUT | 12) | ||
| 38 | #define PA13_PF_LD7 (GPIO_PORTA | GPIO_PF | GPIO_OUT | 13) | ||
| 39 | #define PA14_PF_LD8 (GPIO_PORTA | GPIO_PF | GPIO_OUT | 14) | ||
| 40 | #define PA15_PF_LD9 (GPIO_PORTA | GPIO_PF | GPIO_OUT | 15) | ||
| 41 | #define PA16_PF_LD10 (GPIO_PORTA | GPIO_PF | GPIO_OUT | 16) | ||
| 42 | #define PA17_PF_LD11 (GPIO_PORTA | GPIO_PF | GPIO_OUT | 17) | ||
| 43 | #define PA18_PF_LD12 (GPIO_PORTA | GPIO_PF | GPIO_OUT | 18) | ||
| 44 | #define PA19_PF_LD13 (GPIO_PORTA | GPIO_PF | GPIO_OUT | 19) | ||
| 45 | #define PA20_PF_LD14 (GPIO_PORTA | GPIO_PF | GPIO_OUT | 20) | ||
| 46 | #define PA21_PF_LD15 (GPIO_PORTA | GPIO_PF | GPIO_OUT | 21) | ||
| 47 | #define PA22_PF_LD16 (GPIO_PORTA | GPIO_PF | GPIO_OUT | 22) | ||
| 48 | #define PA23_PF_LD17 (GPIO_PORTA | GPIO_PF | GPIO_OUT | 23) | ||
| 49 | #define PA24_PF_REV (GPIO_PORTA | GPIO_PF | GPIO_OUT | 24) | ||
| 50 | #define PA25_PF_CLS (GPIO_PORTA | GPIO_PF | GPIO_OUT | 25) | ||
| 51 | #define PA26_PF_PS (GPIO_PORTA | GPIO_PF | GPIO_OUT | 26) | ||
| 52 | #define PA27_PF_SPL_SPR (GPIO_PORTA | GPIO_PF | GPIO_OUT | 27) | ||
| 53 | #define PA28_PF_HSYNC (GPIO_PORTA | GPIO_PF | GPIO_OUT | 28) | ||
| 54 | #define PA29_PF_VSYNC (GPIO_PORTA | GPIO_PF | GPIO_OUT | 29) | ||
| 55 | #define PA30_PF_CONTRAST (GPIO_PORTA | GPIO_PF | GPIO_OUT | 30) | ||
| 56 | #define PA31_PF_OE_ACD (GPIO_PORTA | GPIO_PF | GPIO_OUT | 31) | ||
| 57 | #define PB4_PF_SD2_D0 (GPIO_PORTB | GPIO_PF | 4) | ||
| 58 | #define PB5_PF_SD2_D1 (GPIO_PORTB | GPIO_PF | 5) | ||
| 59 | #define PB6_PF_SD2_D2 (GPIO_PORTB | GPIO_PF | 6) | ||
| 60 | #define PB7_PF_SD2_D3 (GPIO_PORTB | GPIO_PF | 7) | ||
| 61 | #define PB8_PF_SD2_CMD (GPIO_PORTB | GPIO_PF | 8) | ||
| 62 | #define PB9_PF_SD2_CLK (GPIO_PORTB | GPIO_PF | 9) | ||
| 63 | #define PB10_PF_CSI_D0 (GPIO_PORTB | GPIO_PF | GPIO_OUT | 10) | ||
| 64 | #define PB11_PF_CSI_D1 (GPIO_PORTB | GPIO_PF | GPIO_OUT | 11) | ||
| 65 | #define PB12_PF_CSI_D2 (GPIO_PORTB | GPIO_PF | GPIO_OUT | 12) | ||
| 66 | #define PB13_PF_CSI_D3 (GPIO_PORTB | GPIO_PF | GPIO_OUT | 13) | ||
| 67 | #define PB14_PF_CSI_D4 (GPIO_PORTB | GPIO_PF | GPIO_OUT | 14) | ||
| 68 | #define PB15_PF_CSI_MCLK (GPIO_PORTB | GPIO_PF | GPIO_OUT | 15) | ||
| 69 | #define PB16_PF_CSI_PIXCLK (GPIO_PORTB | GPIO_PF | GPIO_OUT | 16) | ||
| 70 | #define PB17_PF_CSI_D5 (GPIO_PORTB | GPIO_PF | GPIO_OUT | 17) | ||
| 71 | #define PB18_PF_CSI_D6 (GPIO_PORTB | GPIO_PF | GPIO_OUT | 18) | ||
| 72 | #define PB19_PF_CSI_D7 (GPIO_PORTB | GPIO_PF | GPIO_OUT | 19) | ||
| 73 | #define PB20_PF_CSI_VSYNC (GPIO_PORTB | GPIO_PF | GPIO_OUT | 20) | ||
| 74 | #define PB21_PF_CSI_HSYNC (GPIO_PORTB | GPIO_PF | GPIO_OUT | 21) | ||
| 75 | #define PB23_PF_USB_PWR (GPIO_PORTB | GPIO_PF | 23) | ||
| 76 | #define PB24_PF_USB_OC (GPIO_PORTB | GPIO_PF | 24) | ||
| 77 | #define PB26_PF_USBH1_FS (GPIO_PORTB | GPIO_PF | 26) | ||
| 78 | #define PB27_PF_USBH1_OE (GPIO_PORTB | GPIO_PF | 27) | ||
| 79 | #define PB28_PF_USBH1_TXDM (GPIO_PORTB | GPIO_PF | 28) | ||
| 80 | #define PB29_PF_USBH1_TXDP (GPIO_PORTB | GPIO_PF | 29) | ||
| 81 | #define PB30_PF_USBH1_RXDM (GPIO_PORTB | GPIO_PF | 30) | ||
| 82 | #define PB31_PF_USBH1_RXDP (GPIO_PORTB | GPIO_PF | 31) | ||
| 83 | #define PC14_PF_TOUT (GPIO_PORTC | GPIO_PF | 14) | ||
| 84 | #define PC15_PF_TIN (GPIO_PORTC | GPIO_PF | 15) | ||
| 85 | #define PC20_PF_SSI1_FS (GPIO_PORTC | GPIO_PF | GPIO_IN | 20) | ||
| 86 | #define PC21_PF_SSI1_RXD (GPIO_PORTC | GPIO_PF | GPIO_IN | 21) | ||
| 87 | #define PC22_PF_SSI1_TXD (GPIO_PORTC | GPIO_PF | GPIO_IN | 22) | ||
| 88 | #define PC23_PF_SSI1_CLK (GPIO_PORTC | GPIO_PF | GPIO_IN | 23) | ||
| 89 | #define PC24_PF_SSI2_FS (GPIO_PORTC | GPIO_PF | GPIO_IN | 24) | ||
| 90 | #define PC25_PF_SSI2_RXD (GPIO_PORTC | GPIO_PF | GPIO_IN | 25) | ||
| 91 | #define PC26_PF_SSI2_TXD (GPIO_PORTC | GPIO_PF | GPIO_IN | 26) | ||
| 92 | #define PC27_PF_SSI2_CLK (GPIO_PORTC | GPIO_PF | GPIO_IN | 27) | ||
| 93 | #define PC28_PF_SSI3_FS (GPIO_PORTC | GPIO_PF | GPIO_IN | 28) | ||
| 94 | #define PC29_PF_SSI3_RXD (GPIO_PORTC | GPIO_PF | GPIO_IN | 29) | ||
| 95 | #define PC30_PF_SSI3_TXD (GPIO_PORTC | GPIO_PF | GPIO_IN | 30) | ||
| 96 | #define PC31_PF_SSI3_CLK (GPIO_PORTC | GPIO_PF | GPIO_IN | 31) | ||
| 97 | #define PD17_PF_I2C_DATA (GPIO_PORTD | GPIO_PF | GPIO_OUT | 17) | ||
| 98 | #define PD18_PF_I2C_CLK (GPIO_PORTD | GPIO_PF | GPIO_OUT | 18) | ||
| 99 | #define PD19_PF_CSPI2_SS2 (GPIO_PORTD | GPIO_PF | 19) | ||
| 100 | #define PD20_PF_CSPI2_SS1 (GPIO_PORTD | GPIO_PF | 20) | ||
| 101 | #define PD21_PF_CSPI2_SS0 (GPIO_PORTD | GPIO_PF | 21) | ||
| 102 | #define PD22_PF_CSPI2_SCLK (GPIO_PORTD | GPIO_PF | 22) | ||
| 103 | #define PD23_PF_CSPI2_MISO (GPIO_PORTD | GPIO_PF | 23) | ||
| 104 | #define PD24_PF_CSPI2_MOSI (GPIO_PORTD | GPIO_PF | 24) | ||
| 105 | #define PD25_PF_CSPI1_RDY (GPIO_PORTD | GPIO_PF | GPIO_OUT | 25) | ||
| 106 | #define PD26_PF_CSPI1_SS2 (GPIO_PORTD | GPIO_PF | GPIO_OUT | 26) | ||
| 107 | #define PD27_PF_CSPI1_SS1 (GPIO_PORTD | GPIO_PF | GPIO_OUT | 27) | ||
| 108 | #define PD28_PF_CSPI1_SS0 (GPIO_PORTD | GPIO_PF | GPIO_OUT | 28) | ||
| 109 | #define PD29_PF_CSPI1_SCLK (GPIO_PORTD | GPIO_PF | GPIO_OUT | 29) | ||
| 110 | #define PD30_PF_CSPI1_MISO (GPIO_PORTD | GPIO_PF | GPIO_IN | 30) | ||
| 111 | #define PD31_PF_CSPI1_MOSI (GPIO_PORTD | GPIO_PF | GPIO_OUT | 31) | ||
| 112 | #define PE3_PF_UART2_CTS (GPIO_PORTE | GPIO_PF | GPIO_OUT | 3) | ||
| 113 | #define PE4_PF_UART2_RTS (GPIO_PORTE | GPIO_PF | GPIO_IN | 4) | ||
| 114 | #define PE5_PF_PWMO (GPIO_PORTE | GPIO_PF | 5) | ||
| 115 | #define PE6_PF_UART2_TXD (GPIO_PORTE | GPIO_PF | GPIO_OUT | 6) | ||
| 116 | #define PE7_PF_UART2_RXD (GPIO_PORTE | GPIO_PF | GPIO_IN | 7) | ||
| 117 | #define PE8_PF_UART3_TXD (GPIO_PORTE | GPIO_PF | GPIO_OUT | 8) | ||
| 118 | #define PE9_PF_UART3_RXD (GPIO_PORTE | GPIO_PF | GPIO_IN | 9) | ||
| 119 | #define PE10_PF_UART3_CTS (GPIO_PORTE | GPIO_PF | GPIO_OUT | 10) | ||
| 120 | #define PE11_PF_UART3_RTS (GPIO_PORTE | GPIO_PF | GPIO_IN | 11) | ||
| 121 | #define PE12_PF_UART1_TXD (GPIO_PORTE | GPIO_PF | GPIO_OUT | 12) | ||
| 122 | #define PE13_PF_UART1_RXD (GPIO_PORTE | GPIO_PF | GPIO_IN | 13) | ||
| 123 | #define PE14_PF_UART1_CTS (GPIO_PORTE | GPIO_PF | GPIO_OUT | 14) | ||
| 124 | #define PE15_PF_UART1_RTS (GPIO_PORTE | GPIO_PF | GPIO_IN | 15) | ||
| 125 | #define PE16_PF_RTCK (GPIO_PORTE | GPIO_PF | GPIO_OUT | 16) | ||
| 126 | #define PE17_PF_RESET_OUT (GPIO_PORTE | GPIO_PF | 17) | ||
| 127 | #define PE18_PF_SD1_D0 (GPIO_PORTE | GPIO_PF | 18) | ||
| 128 | #define PE19_PF_SD1_D1 (GPIO_PORTE | GPIO_PF | 19) | ||
| 129 | #define PE20_PF_SD1_D2 (GPIO_PORTE | GPIO_PF | 20) | ||
| 130 | #define PE21_PF_SD1_D3 (GPIO_PORTE | GPIO_PF | 21) | ||
| 131 | #define PE22_PF_SD1_CMD (GPIO_PORTE | GPIO_PF | 22) | ||
| 132 | #define PE23_PF_SD1_CLK (GPIO_PORTE | GPIO_PF | 23) | ||
| 133 | #define PF0_PF_NRFB (GPIO_PORTF | GPIO_PF | 0) | ||
| 134 | #define PF2_PF_NFWP (GPIO_PORTF | GPIO_PF | 2) | ||
| 135 | #define PF4_PF_NFALE (GPIO_PORTF | GPIO_PF | 4) | ||
| 136 | #define PF5_PF_NFRE (GPIO_PORTF | GPIO_PF | 5) | ||
| 137 | #define PF6_PF_NFWE (GPIO_PORTF | GPIO_PF | 6) | ||
| 138 | #define PF15_PF_CLKO (GPIO_PORTF | GPIO_PF | 15) | ||
| 139 | #define PF21_PF_CS4 (GPIO_PORTF | GPIO_PF | 21) | ||
| 140 | #define PF22_PF_CS5 (GPIO_PORTF | GPIO_PF | 22) | ||
| 141 | |||
| 142 | /* Alternate GPIO pin functions */ | ||
| 143 | |||
| 144 | #define PB26_AF_UART4_RTS (GPIO_PORTB | GPIO_AF | GPIO_IN | 26) | ||
| 145 | #define PB28_AF_UART4_TXD (GPIO_PORTB | GPIO_AF | GPIO_OUT | 28) | ||
| 146 | #define PB29_AF_UART4_CTS (GPIO_PORTB | GPIO_AF | GPIO_OUT | 29) | ||
| 147 | #define PB31_AF_UART4_RXD (GPIO_PORTB | GPIO_AF | GPIO_IN | 31) | ||
| 148 | #define PC28_AF_SLCDC2_D0 (GPIO_PORTC | GPIO_AF | 28) | ||
| 149 | #define PC29_AF_SLCDC2_RS (GPIO_PORTC | GPIO_AF | 29) | ||
| 150 | #define PC30_AF_SLCDC2_CS (GPIO_PORTC | GPIO_AF | 30) | ||
| 151 | #define PC31_AF_SLCDC2_CLK (GPIO_PORTC | GPIO_AF | 31) | ||
| 152 | #define PD19_AF_USBH2_DATA4 (GPIO_PORTD | GPIO_AF | 19) | ||
| 153 | #define PD20_AF_USBH2_DATA3 (GPIO_PORTD | GPIO_AF | 20) | ||
| 154 | #define PD21_AF_USBH2_DATA6 (GPIO_PORTD | GPIO_AF | 21) | ||
| 155 | #define PD22_AF_USBH2_DATA0 (GPIO_PORTD | GPIO_AF | 22) | ||
| 156 | #define PD23_AF_USBH2_DATA2 (GPIO_PORTD | GPIO_AF | 23) | ||
| 157 | #define PD24_AF_USBH2_DATA1 (GPIO_PORTD | GPIO_AF | 24) | ||
| 158 | #define PD26_AF_USBH2_DATA5 (GPIO_PORTD | GPIO_AF | 26) | ||
| 159 | #define PE0_AF_KP_COL6 (GPIO_PORTE | GPIO_AF | 0) | ||
| 160 | #define PE1_AF_KP_ROW6 (GPIO_PORTE | GPIO_AF | 1) | ||
| 161 | #define PE2_AF_KP_ROW7 (GPIO_PORTE | GPIO_AF | 2) | ||
| 162 | #define PE3_AF_KP_COL7 (GPIO_PORTE | GPIO_AF | 3) | ||
| 163 | #define PE4_AF_KP_ROW7 (GPIO_PORTE | GPIO_AF | 4) | ||
| 164 | #define PE6_AF_KP_COL6 (GPIO_PORTE | GPIO_AF | 6) | ||
| 165 | #define PE7_AF_KP_ROW6 (GPIO_PORTE | GPIO_AF | 7) | ||
| 166 | #define PE16_AF_OWIRE (GPIO_PORTE | GPIO_AF | 16) | ||
| 167 | #define PE18_AF_CSPI3_MISO (GPIO_PORTE | GPIO_AF | GPIO_IN | 18) | ||
| 168 | #define PE21_AF_CSPI3_SS (GPIO_PORTE | GPIO_AF | GPIO_OUT | 21) | ||
| 169 | #define PE22_AF_CSPI3_MOSI (GPIO_PORTE | GPIO_AF | GPIO_OUT | 22) | ||
| 170 | #define PE23_AF_CSPI3_SCLK (GPIO_PORTE | GPIO_AF | GPIO_OUT | 23) | ||
| 171 | |||
| 172 | /* AIN GPIO pin functions */ | ||
| 173 | |||
| 174 | #define PA6_AIN_SLCDC1_DAT0 (GPIO_PORTA | GPIO_AIN | GPIO_OUT | 6) | ||
| 175 | #define PA7_AIN_SLCDC1_DAT1 (GPIO_PORTA | GPIO_AIN | GPIO_OUT | 7) | ||
| 176 | #define PA8_AIN_SLCDC1_DAT2 (GPIO_PORTA | GPIO_AIN | GPIO_OUT | 8) | ||
| 177 | #define PA0_AIN_SLCDC1_DAT3 (GPIO_PORTA | GPIO_AIN | GPIO_OUT | 0) | ||
| 178 | #define PA11_AIN_SLCDC1_DAT5 (GPIO_PORTA | GPIO_AIN | GPIO_OUT | 11) | ||
| 179 | #define PA13_AIN_SLCDC1_DAT7 (GPIO_PORTA | GPIO_AIN | GPIO_OUT | 13) | ||
| 180 | #define PA15_AIN_SLCDC1_DAT9 (GPIO_PORTA | GPIO_AIN | GPIO_OUT | 15) | ||
| 181 | #define PA17_AIN_SLCDC1_DAT11 (GPIO_PORTA | GPIO_AIN | GPIO_OUT | 17) | ||
| 182 | #define PA19_AIN_SLCDC1_DAT13 (GPIO_PORTA | GPIO_AIN | GPIO_OUT | 19) | ||
| 183 | #define PA21_AIN_SLCDC1_DAT15 (GPIO_PORTA | GPIO_AIN | GPIO_OUT | 21) | ||
| 184 | #define PA22_AIN_EXT_DMAGRANT (GPIO_PORTA | GPIO_AIN | GPIO_OUT | 22) | ||
| 185 | #define PA24_AIN_SLCDC1_D0 (GPIO_PORTA | GPIO_AIN | GPIO_OUT | 24) | ||
| 186 | #define PA25_AIN_SLCDC1_RS (GPIO_PORTA | GPIO_AIN | GPIO_OUT | 25) | ||
| 187 | #define PA26_AIN_SLCDC1_CS (GPIO_PORTA | GPIO_AIN | GPIO_OUT | 26) | ||
| 188 | #define PA27_AIN_SLCDC1_CLK (GPIO_PORTA | GPIO_AIN | GPIO_OUT | 27) | ||
| 189 | #define PB6_AIN_SLCDC1_D0 (GPIO_PORTB | GPIO_AIN | GPIO_OUT | 6) | ||
| 190 | #define PB7_AIN_SLCDC1_RS (GPIO_PORTB | GPIO_AIN | GPIO_OUT | 7) | ||
| 191 | #define PB8_AIN_SLCDC1_CS (GPIO_PORTB | GPIO_AIN | GPIO_OUT | 8) | ||
| 192 | #define PB9_AIN_SLCDC1_CLK (GPIO_PORTB | GPIO_AIN | GPIO_OUT | 9) | ||
| 193 | #define PB25_AIN_SLCDC1_DAT0 (GPIO_PORTB | GPIO_AIN | GPIO_OUT | 25) | ||
| 194 | #define PB26_AIN_SLCDC1_DAT1 (GPIO_PORTB | GPIO_AIN | GPIO_OUT | 26) | ||
| 195 | #define PB27_AIN_SLCDC1_DAT2 (GPIO_PORTB | GPIO_AIN | GPIO_OUT | 27) | ||
| 196 | #define PB28_AIN_SLCDC1_DAT3 (GPIO_PORTB | GPIO_AIN | GPIO_OUT | 28) | ||
| 197 | #define PB29_AIN_SLCDC1_DAT4 (GPIO_PORTB | GPIO_AIN | GPIO_OUT | 29) | ||
| 198 | #define PB30_AIN_SLCDC1_DAT5 (GPIO_PORTB | GPIO_AIN | GPIO_OUT | 30) | ||
| 199 | #define PB31_AIN_SLCDC1_DAT6 (GPIO_PORTB | GPIO_AIN | GPIO_OUT | 31) | ||
| 200 | #define PC5_AIN_SLCDC1_DAT7 (GPIO_PORTC | GPIO_AIN | GPIO_OUT | 5) | ||
| 201 | #define PC6_AIN_SLCDC1_DAT8 (GPIO_PORTC | GPIO_AIN | GPIO_OUT | 6) | ||
| 202 | #define PC7_AIN_SLCDC1_DAT9 (GPIO_PORTC | GPIO_AIN | GPIO_OUT | 7) | ||
| 203 | #define PC8_AIN_SLCDC1_DAT10 (GPIO_PORTC | GPIO_AIN | GPIO_OUT | 8) | ||
| 204 | #define PC9_AIN_SLCDC1_DAT11 (GPIO_PORTC | GPIO_AIN | GPIO_OUT | 9) | ||
| 205 | #define PC10_AIN_SLCDC1_DAT12 (GPIO_PORTC | GPIO_AIN | GPIO_OUT | 10) | ||
| 206 | #define PC11_AIN_SLCDC1_DAT13 (GPIO_PORTC | GPIO_AIN | GPIO_OUT | 11) | ||
| 207 | #define PC12_AIN_SLCDC1_DAT14 (GPIO_PORTC | GPIO_AIN | GPIO_OUT | 12) | ||
| 208 | #define PC13_AIN_SLCDC1_DAT15 (GPIO_PORTC | GPIO_AIN | GPIO_OUT | 13) | ||
| 209 | #define PE5_AIN_PC_SPKOUT (GPIO_PORTE | GPIO_AIN | GPIO_OUT | 5) | ||
| 210 | |||
| 211 | /* BIN GPIO pin functions */ | ||
| 212 | |||
| 213 | #define PE5_BIN_TOUT2 (GPIO_PORTE | GPIO_BIN | GPIO_OUT | 5) | ||
| 214 | |||
| 215 | /* CIN GPIO pin functions */ | ||
| 216 | |||
| 217 | #define PA14_CIN_SLCDC1_DAT0 (GPIO_PORTA | GPIO_CIN | GPIO_OUT | 14) | ||
| 218 | #define PA15_CIN_SLCDC1_DAT1 (GPIO_PORTA | GPIO_CIN | GPIO_OUT | 15) | ||
| 219 | #define PA16_CIN_SLCDC1_DAT2 (GPIO_PORTA | GPIO_CIN | GPIO_OUT | 16) | ||
| 220 | #define PA17_CIN_SLCDC1_DAT3 (GPIO_PORTA | GPIO_CIN | GPIO_OUT | 17) | ||
| 221 | #define PA18_CIN_SLCDC1_DAT4 (GPIO_PORTA | GPIO_CIN | GPIO_OUT | 18) | ||
| 222 | #define PA19_CIN_SLCDC1_DAT5 (GPIO_PORTA | GPIO_CIN | GPIO_OUT | 19) | ||
| 223 | #define PA20_CIN_SLCDC1_DAT6 (GPIO_PORTA | GPIO_CIN | GPIO_OUT | 20) | ||
| 224 | #define PA21_CIN_SLCDC1_DAT7 (GPIO_PORTA | GPIO_CIN | GPIO_OUT | 21) | ||
| 225 | #define PB30_CIN_UART4_CTS (GPIO_PORTB | GPIO_CIN | GPIO_OUT | 30) | ||
| 226 | #define PE5_CIN_TOUT3 (GPIO_PORTE | GPIO_CIN | GPIO_OUT | 5) | ||
| 227 | |||
| 228 | /* AOUT GPIO pin functions */ | ||
| 229 | |||
| 230 | #define PB29_AOUT_UART4_RXD (GPIO_PORTB | GPIO_AOUT | GPIO_IN | 29) | ||
| 231 | #define PB31_AOUT_UART4_RTS (GPIO_PORTB | GPIO_AOUT | GPIO_IN | 31) | ||
| 232 | #define PC8_AOUT_USBOTG_TXR_INT (GPIO_PORTC | GPIO_AOUT | GPIO_IN | 8) | ||
| 233 | #define PC15_AOUT_WKGD (GPIO_PORTC | GPIO_AOUT | GPIO_IN | 15) | ||
| 234 | #define PF21_AOUT_DTACK (GPIO_PORTF | GPIO_AOUT | GPIO_IN | 21) | ||
| 235 | |||
| 236 | |||
| 237 | #endif | ||
diff --git a/arch/arm/plat-mxc/include/mach/iomux.h b/arch/arm/plat-mxc/include/mach/iomux.h new file mode 100644 index 000000000000..171f8adc1109 --- /dev/null +++ b/arch/arm/plat-mxc/include/mach/iomux.h | |||
| @@ -0,0 +1,127 @@ | |||
| 1 | /* | ||
| 2 | * Copyright (C) 2008 by Sascha Hauer <kernel@pengutronix.de> | ||
| 3 | * Copyright (C) 2009 by Holger Schurig <hs4233@mail.mn-solutions.de> | ||
| 4 | * | ||
| 5 | * This program is free software; you can redistribute it and/or | ||
| 6 | * modify it under the terms of the GNU General Public License | ||
| 7 | * as published by the Free Software Foundation; either version 2 | ||
| 8 | * of the License, or (at your option) any later version. | ||
| 9 | * This program is distributed in the hope that it will be useful, | ||
| 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 12 | * GNU General Public License for more details. | ||
| 13 | * | ||
| 14 | * You should have received a copy of the GNU General Public License | ||
| 15 | * along with this program; if not, write to the Free Software | ||
| 16 | * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, | ||
| 17 | * MA 02110-1301, USA. | ||
| 18 | */ | ||
| 19 | |||
| 20 | #ifndef _MXC_IOMUX_H | ||
| 21 | #define _MXC_IOMUX_H | ||
| 22 | |||
| 23 | /* | ||
| 24 | * GPIO Module and I/O Multiplexer | ||
| 25 | * x = 0..3 for reg_A, reg_B, reg_C, reg_D | ||
| 26 | */ | ||
| 27 | #define VA_GPIO_BASE IO_ADDRESS(GPIO_BASE_ADDR) | ||
| 28 | #define MXC_DDIR(x) (0x00 + ((x) << 8)) | ||
| 29 | #define MXC_OCR1(x) (0x04 + ((x) << 8)) | ||
| 30 | #define MXC_OCR2(x) (0x08 + ((x) << 8)) | ||
| 31 | #define MXC_ICONFA1(x) (0x0c + ((x) << 8)) | ||
| 32 | #define MXC_ICONFA2(x) (0x10 + ((x) << 8)) | ||
| 33 | #define MXC_ICONFB1(x) (0x14 + ((x) << 8)) | ||
| 34 | #define MXC_ICONFB2(x) (0x18 + ((x) << 8)) | ||
| 35 | #define MXC_DR(x) (0x1c + ((x) << 8)) | ||
| 36 | #define MXC_GIUS(x) (0x20 + ((x) << 8)) | ||
| 37 | #define MXC_SSR(x) (0x24 + ((x) << 8)) | ||
| 38 | #define MXC_ICR1(x) (0x28 + ((x) << 8)) | ||
| 39 | #define MXC_ICR2(x) (0x2c + ((x) << 8)) | ||
| 40 | #define MXC_IMR(x) (0x30 + ((x) << 8)) | ||
| 41 | #define MXC_ISR(x) (0x34 + ((x) << 8)) | ||
| 42 | #define MXC_GPR(x) (0x38 + ((x) << 8)) | ||
| 43 | #define MXC_SWR(x) (0x3c + ((x) << 8)) | ||
| 44 | #define MXC_PUEN(x) (0x40 + ((x) << 8)) | ||
| 45 | |||
| 46 | #ifdef CONFIG_ARCH_MX1 | ||
| 47 | # define GPIO_PORT_MAX 3 | ||
| 48 | #endif | ||
| 49 | #ifdef CONFIG_ARCH_MX2 | ||
| 50 | # define GPIO_PORT_MAX 5 | ||
| 51 | #endif | ||
| 52 | |||
| 53 | #ifndef GPIO_PORT_MAX | ||
| 54 | # error "GPIO config port count unknown!" | ||
| 55 | #endif | ||
| 56 | |||
| 57 | #define GPIO_PIN_MASK 0x1f | ||
| 58 | |||
| 59 | #define GPIO_PORT_SHIFT 5 | ||
| 60 | #define GPIO_PORT_MASK (0x7 << GPIO_PORT_SHIFT) | ||
| 61 | |||
| 62 | #define GPIO_PORTA (0 << GPIO_PORT_SHIFT) | ||
| 63 | #define GPIO_PORTB (1 << GPIO_PORT_SHIFT) | ||
| 64 | #define GPIO_PORTC (2 << GPIO_PORT_SHIFT) | ||
| 65 | #define GPIO_PORTD (3 << GPIO_PORT_SHIFT) | ||
| 66 | #define GPIO_PORTE (4 << GPIO_PORT_SHIFT) | ||
| 67 | #define GPIO_PORTF (5 << GPIO_PORT_SHIFT) | ||
| 68 | |||
| 69 | #define GPIO_OUT (1 << 8) | ||
| 70 | #define GPIO_IN (0 << 8) | ||
| 71 | #define GPIO_PUEN (1 << 9) | ||
| 72 | |||
| 73 | #define GPIO_PF (1 << 10) | ||
| 74 | #define GPIO_AF (1 << 11) | ||
| 75 | |||
| 76 | #define GPIO_OCR_SHIFT 12 | ||
| 77 | #define GPIO_OCR_MASK (3 << GPIO_OCR_SHIFT) | ||
| 78 | #define GPIO_AIN (0 << GPIO_OCR_SHIFT) | ||
| 79 | #define GPIO_BIN (1 << GPIO_OCR_SHIFT) | ||
| 80 | #define GPIO_CIN (2 << GPIO_OCR_SHIFT) | ||
| 81 | #define GPIO_GPIO (3 << GPIO_OCR_SHIFT) | ||
| 82 | |||
| 83 | #define GPIO_AOUT_SHIFT 14 | ||
| 84 | #define GPIO_AOUT_MASK (3 << GPIO_AOUT_SHIFT) | ||
| 85 | #define GPIO_AOUT (0 << GPIO_AOUT_SHIFT) | ||
| 86 | #define GPIO_AOUT_ISR (1 << GPIO_AOUT_SHIFT) | ||
| 87 | #define GPIO_AOUT_0 (2 << GPIO_AOUT_SHIFT) | ||
| 88 | #define GPIO_AOUT_1 (3 << GPIO_AOUT_SHIFT) | ||
| 89 | |||
| 90 | #define GPIO_BOUT_SHIFT 16 | ||
| 91 | #define GPIO_BOUT_MASK (3 << GPIO_BOUT_SHIFT) | ||
| 92 | #define GPIO_BOUT (0 << GPIO_BOUT_SHIFT) | ||
| 93 | #define GPIO_BOUT_ISR (1 << GPIO_BOUT_SHIFT) | ||
| 94 | #define GPIO_BOUT_0 (2 << GPIO_BOUT_SHIFT) | ||
| 95 | #define GPIO_BOUT_1 (3 << GPIO_BOUT_SHIFT) | ||
| 96 | |||
| 97 | |||
| 98 | #ifdef CONFIG_ARCH_MX1 | ||
| 99 | #include <mach/iomux-mx1.h> | ||
| 100 | #endif | ||
| 101 | #ifdef CONFIG_ARCH_MX2 | ||
| 102 | #include <mach/iomux-mx2x.h> | ||
| 103 | #ifdef CONFIG_MACH_MX21 | ||
| 104 | #include <mach/iomux-mx21.h> | ||
| 105 | #endif | ||
| 106 | #ifdef CONFIG_MACH_MX27 | ||
| 107 | #include <mach/iomux-mx27.h> | ||
| 108 | #endif | ||
| 109 | #endif | ||
| 110 | |||
| 111 | |||
| 112 | /* decode irq number to use with IMR(x), ISR(x) and friends */ | ||
| 113 | #define IRQ_TO_REG(irq) ((irq - MXC_INTERNAL_IRQS) >> 5) | ||
| 114 | |||
| 115 | #define IRQ_GPIOA(x) (MXC_GPIO_IRQ_START + x) | ||
| 116 | #define IRQ_GPIOB(x) (IRQ_GPIOA(32) + x) | ||
| 117 | #define IRQ_GPIOC(x) (IRQ_GPIOB(32) + x) | ||
| 118 | #define IRQ_GPIOD(x) (IRQ_GPIOC(32) + x) | ||
| 119 | #define IRQ_GPIOE(x) (IRQ_GPIOD(32) + x) | ||
| 120 | |||
| 121 | |||
| 122 | extern void mxc_gpio_mode(int gpio_mode); | ||
| 123 | extern int mxc_gpio_setup_multiple_pins(const int *pin_list, unsigned count, | ||
| 124 | const char *label); | ||
| 125 | extern void mxc_gpio_release_multiple_pins(const int *pin_list, int count); | ||
| 126 | |||
| 127 | #endif | ||
diff --git a/arch/arm/plat-mxc/iomux-mx1-mx2.c b/arch/arm/plat-mxc/iomux-mx1-mx2.c index df6f18395686..a37163ce280b 100644 --- a/arch/arm/plat-mxc/iomux-mx1-mx2.c +++ b/arch/arm/plat-mxc/iomux-mx1-mx2.c | |||
| @@ -32,7 +32,7 @@ | |||
| 32 | 32 | ||
| 33 | #include <mach/hardware.h> | 33 | #include <mach/hardware.h> |
| 34 | #include <asm/mach/map.h> | 34 | #include <asm/mach/map.h> |
| 35 | #include <mach/iomux-mx1-mx2.h> | 35 | #include <mach/iomux.h> |
| 36 | 36 | ||
| 37 | void mxc_gpio_mode(int gpio_mode) | 37 | void mxc_gpio_mode(int gpio_mode) |
| 38 | { | 38 | { |
