diff options
author | Eric Miao <eric.y.miao@gmail.com> | 2010-01-03 22:25:10 -0500 |
---|---|---|
committer | Eric Miao <eric.y.miao@gmail.com> | 2010-03-01 18:40:46 -0500 |
commit | 07bae6c3215e060d5e3742b6f2932de0787f0782 (patch) | |
tree | 14da3baae784f58f6116acd16361ff15dc499b8b /arch/arm | |
parent | 669cb51c6abf77e10cbeb6f483c96abc492206ac (diff) |
[ARM] pxa: simplify the LCD pin configuration for pxa25x platforms
There are only limited possible LCD pin configurations for pxa25x
platforms, simplify this by macro.
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
Diffstat (limited to 'arch/arm')
-rw-r--r-- | arch/arm/mach-pxa/cm-x255.c | 21 | ||||
-rw-r--r-- | arch/arm/mach-pxa/idp.c | 20 | ||||
-rw-r--r-- | arch/arm/mach-pxa/include/mach/mfp-pxa25x.h | 32 | ||||
-rw-r--r-- | arch/arm/mach-pxa/lubbock.c | 20 | ||||
-rw-r--r-- | arch/arm/mach-pxa/palmtc.c | 21 | ||||
-rw-r--r-- | arch/arm/mach-pxa/palmte2.c | 21 | ||||
-rw-r--r-- | arch/arm/mach-pxa/poodle.c | 21 |
7 files changed, 38 insertions, 118 deletions
diff --git a/arch/arm/mach-pxa/cm-x255.c b/arch/arm/mach-pxa/cm-x255.c index 253fd76142d6..f1a7703d771b 100644 --- a/arch/arm/mach-pxa/cm-x255.c +++ b/arch/arm/mach-pxa/cm-x255.c | |||
@@ -50,26 +50,7 @@ static unsigned long cmx255_pin_config[] = { | |||
50 | GPIO47_STUART_TXD, | 50 | GPIO47_STUART_TXD, |
51 | 51 | ||
52 | /* LCD */ | 52 | /* LCD */ |
53 | GPIO58_LCD_LDD_0, | 53 | GPIOxx_LCD_TFT_16BPP, |
54 | GPIO59_LCD_LDD_1, | ||
55 | GPIO60_LCD_LDD_2, | ||
56 | GPIO61_LCD_LDD_3, | ||
57 | GPIO62_LCD_LDD_4, | ||
58 | GPIO63_LCD_LDD_5, | ||
59 | GPIO64_LCD_LDD_6, | ||
60 | GPIO65_LCD_LDD_7, | ||
61 | GPIO66_LCD_LDD_8, | ||
62 | GPIO67_LCD_LDD_9, | ||
63 | GPIO68_LCD_LDD_10, | ||
64 | GPIO69_LCD_LDD_11, | ||
65 | GPIO70_LCD_LDD_12, | ||
66 | GPIO71_LCD_LDD_13, | ||
67 | GPIO72_LCD_LDD_14, | ||
68 | GPIO73_LCD_LDD_15, | ||
69 | GPIO74_LCD_FCLK, | ||
70 | GPIO75_LCD_LCLK, | ||
71 | GPIO76_LCD_PCLK, | ||
72 | GPIO77_LCD_BIAS, | ||
73 | 54 | ||
74 | /* SSP1 */ | 55 | /* SSP1 */ |
75 | GPIO23_SSP1_SCLK, | 56 | GPIO23_SSP1_SCLK, |
diff --git a/arch/arm/mach-pxa/idp.c b/arch/arm/mach-pxa/idp.c index 5c9e11d74f49..bc78c4dc0c66 100644 --- a/arch/arm/mach-pxa/idp.c +++ b/arch/arm/mach-pxa/idp.c | |||
@@ -47,25 +47,7 @@ | |||
47 | 47 | ||
48 | static unsigned long idp_pin_config[] __initdata = { | 48 | static unsigned long idp_pin_config[] __initdata = { |
49 | /* LCD */ | 49 | /* LCD */ |
50 | GPIO58_LCD_LDD_0, | 50 | GPIOxx_LCD_DSTN_16BPP, |
51 | GPIO59_LCD_LDD_1, | ||
52 | GPIO60_LCD_LDD_2, | ||
53 | GPIO61_LCD_LDD_3, | ||
54 | GPIO62_LCD_LDD_4, | ||
55 | GPIO63_LCD_LDD_5, | ||
56 | GPIO64_LCD_LDD_6, | ||
57 | GPIO65_LCD_LDD_7, | ||
58 | GPIO66_LCD_LDD_8, | ||
59 | GPIO67_LCD_LDD_9, | ||
60 | GPIO68_LCD_LDD_10, | ||
61 | GPIO69_LCD_LDD_11, | ||
62 | GPIO70_LCD_LDD_12, | ||
63 | GPIO71_LCD_LDD_13, | ||
64 | GPIO72_LCD_LDD_14, | ||
65 | GPIO73_LCD_LDD_15, | ||
66 | GPIO74_LCD_FCLK, | ||
67 | GPIO75_LCD_LCLK, | ||
68 | GPIO76_LCD_PCLK, | ||
69 | 51 | ||
70 | /* BTUART */ | 52 | /* BTUART */ |
71 | GPIO42_BTUART_RXD, | 53 | GPIO42_BTUART_RXD, |
diff --git a/arch/arm/mach-pxa/include/mach/mfp-pxa25x.h b/arch/arm/mach-pxa/include/mach/mfp-pxa25x.h index 9c787855cf24..cafadc33dfd8 100644 --- a/arch/arm/mach-pxa/include/mach/mfp-pxa25x.h +++ b/arch/arm/mach-pxa/include/mach/mfp-pxa25x.h | |||
@@ -190,4 +190,36 @@ | |||
190 | #define GPIO89_AC97_nRESET MFP_CFG_OUT(GPIO89, AF0, DRIVE_HIGH) | 190 | #define GPIO89_AC97_nRESET MFP_CFG_OUT(GPIO89, AF0, DRIVE_HIGH) |
191 | #endif /* CONFIG_CPU_PXA26x */ | 191 | #endif /* CONFIG_CPU_PXA26x */ |
192 | 192 | ||
193 | /* commonly used pin configurations */ | ||
194 | #define GPIOxx_LCD_16BPP \ | ||
195 | GPIO58_LCD_LDD_0, \ | ||
196 | GPIO59_LCD_LDD_1, \ | ||
197 | GPIO60_LCD_LDD_2, \ | ||
198 | GPIO61_LCD_LDD_3, \ | ||
199 | GPIO62_LCD_LDD_4, \ | ||
200 | GPIO63_LCD_LDD_5, \ | ||
201 | GPIO64_LCD_LDD_6, \ | ||
202 | GPIO65_LCD_LDD_7, \ | ||
203 | GPIO66_LCD_LDD_8, \ | ||
204 | GPIO67_LCD_LDD_9, \ | ||
205 | GPIO68_LCD_LDD_10, \ | ||
206 | GPIO69_LCD_LDD_11, \ | ||
207 | GPIO70_LCD_LDD_12, \ | ||
208 | GPIO71_LCD_LDD_13, \ | ||
209 | GPIO72_LCD_LDD_14, \ | ||
210 | GPIO73_LCD_LDD_15 | ||
211 | |||
212 | #define GPIOxx_LCD_DSTN_16BPP \ | ||
213 | GPIOxx_LCD_16BPP, \ | ||
214 | GPIO74_LCD_FCLK, \ | ||
215 | GPIO75_LCD_LCLK, \ | ||
216 | GPIO76_LCD_PCLK | ||
217 | |||
218 | #define GPIOxx_LCD_TFT_16BPP \ | ||
219 | GPIOxx_LCD_16BPP, \ | ||
220 | GPIO74_LCD_FCLK, \ | ||
221 | GPIO75_LCD_LCLK, \ | ||
222 | GPIO76_LCD_PCLK, \ | ||
223 | GPIO77_LCD_BIAS | ||
224 | |||
193 | #endif /* __ASM_ARCH_MFP_PXA25X_H */ | 225 | #endif /* __ASM_ARCH_MFP_PXA25X_H */ |
diff --git a/arch/arm/mach-pxa/lubbock.c b/arch/arm/mach-pxa/lubbock.c index d9982b16f8c0..56ae54ef44f3 100644 --- a/arch/arm/mach-pxa/lubbock.c +++ b/arch/arm/mach-pxa/lubbock.c | |||
@@ -67,25 +67,7 @@ static unsigned long lubbock_pin_config[] __initdata = { | |||
67 | GPIO26_SSP1_RXD, | 67 | GPIO26_SSP1_RXD, |
68 | 68 | ||
69 | /* LCD - 16bpp DSTN */ | 69 | /* LCD - 16bpp DSTN */ |
70 | GPIO58_LCD_LDD_0, | 70 | GPIOxx_LCD_DSTN_16BPP, |
71 | GPIO59_LCD_LDD_1, | ||
72 | GPIO60_LCD_LDD_2, | ||
73 | GPIO61_LCD_LDD_3, | ||
74 | GPIO62_LCD_LDD_4, | ||
75 | GPIO63_LCD_LDD_5, | ||
76 | GPIO64_LCD_LDD_6, | ||
77 | GPIO65_LCD_LDD_7, | ||
78 | GPIO66_LCD_LDD_8, | ||
79 | GPIO67_LCD_LDD_9, | ||
80 | GPIO68_LCD_LDD_10, | ||
81 | GPIO69_LCD_LDD_11, | ||
82 | GPIO70_LCD_LDD_12, | ||
83 | GPIO71_LCD_LDD_13, | ||
84 | GPIO72_LCD_LDD_14, | ||
85 | GPIO73_LCD_LDD_15, | ||
86 | GPIO74_LCD_FCLK, | ||
87 | GPIO75_LCD_LCLK, | ||
88 | GPIO76_LCD_PCLK, | ||
89 | 71 | ||
90 | /* BTUART */ | 72 | /* BTUART */ |
91 | GPIO42_BTUART_RXD, | 73 | GPIO42_BTUART_RXD, |
diff --git a/arch/arm/mach-pxa/palmtc.c b/arch/arm/mach-pxa/palmtc.c index b992f07ece21..717d7a638675 100644 --- a/arch/arm/mach-pxa/palmtc.c +++ b/arch/arm/mach-pxa/palmtc.c | |||
@@ -84,26 +84,7 @@ static unsigned long palmtc_pin_config[] __initdata = { | |||
84 | GPIO36_GPIO, /* pullup */ | 84 | GPIO36_GPIO, /* pullup */ |
85 | 85 | ||
86 | /* LCD */ | 86 | /* LCD */ |
87 | GPIO58_LCD_LDD_0, | 87 | GPIOxx_LCD_TFT_16BPP, |
88 | GPIO59_LCD_LDD_1, | ||
89 | GPIO60_LCD_LDD_2, | ||
90 | GPIO61_LCD_LDD_3, | ||
91 | GPIO62_LCD_LDD_4, | ||
92 | GPIO63_LCD_LDD_5, | ||
93 | GPIO64_LCD_LDD_6, | ||
94 | GPIO65_LCD_LDD_7, | ||
95 | GPIO66_LCD_LDD_8, | ||
96 | GPIO67_LCD_LDD_9, | ||
97 | GPIO68_LCD_LDD_10, | ||
98 | GPIO69_LCD_LDD_11, | ||
99 | GPIO70_LCD_LDD_12, | ||
100 | GPIO71_LCD_LDD_13, | ||
101 | GPIO72_LCD_LDD_14, | ||
102 | GPIO73_LCD_LDD_15, | ||
103 | GPIO74_LCD_FCLK, | ||
104 | GPIO75_LCD_LCLK, | ||
105 | GPIO76_LCD_PCLK, | ||
106 | GPIO77_LCD_BIAS, | ||
107 | 88 | ||
108 | /* MATRIX KEYPAD */ | 89 | /* MATRIX KEYPAD */ |
109 | GPIO0_GPIO | WAKEUP_ON_EDGE_BOTH, /* in 0 */ | 90 | GPIO0_GPIO | WAKEUP_ON_EDGE_BOTH, /* in 0 */ |
diff --git a/arch/arm/mach-pxa/palmte2.c b/arch/arm/mach-pxa/palmte2.c index dc728d6ab94e..3d284ff1a64e 100644 --- a/arch/arm/mach-pxa/palmte2.c +++ b/arch/arm/mach-pxa/palmte2.c | |||
@@ -73,26 +73,7 @@ static unsigned long palmte2_pin_config[] __initdata = { | |||
73 | GPIO47_FICP_TXD, | 73 | GPIO47_FICP_TXD, |
74 | 74 | ||
75 | /* LCD */ | 75 | /* LCD */ |
76 | GPIO58_LCD_LDD_0, | 76 | GPIOxx_LCD_TFT_16BPP, |
77 | GPIO59_LCD_LDD_1, | ||
78 | GPIO60_LCD_LDD_2, | ||
79 | GPIO61_LCD_LDD_3, | ||
80 | GPIO62_LCD_LDD_4, | ||
81 | GPIO63_LCD_LDD_5, | ||
82 | GPIO64_LCD_LDD_6, | ||
83 | GPIO65_LCD_LDD_7, | ||
84 | GPIO66_LCD_LDD_8, | ||
85 | GPIO67_LCD_LDD_9, | ||
86 | GPIO68_LCD_LDD_10, | ||
87 | GPIO69_LCD_LDD_11, | ||
88 | GPIO70_LCD_LDD_12, | ||
89 | GPIO71_LCD_LDD_13, | ||
90 | GPIO72_LCD_LDD_14, | ||
91 | GPIO73_LCD_LDD_15, | ||
92 | GPIO74_LCD_FCLK, | ||
93 | GPIO75_LCD_LCLK, | ||
94 | GPIO76_LCD_PCLK, | ||
95 | GPIO77_LCD_BIAS, | ||
96 | 77 | ||
97 | /* GPIO KEYS */ | 78 | /* GPIO KEYS */ |
98 | GPIO5_GPIO, /* notes */ | 79 | GPIO5_GPIO, /* notes */ |
diff --git a/arch/arm/mach-pxa/poodle.c b/arch/arm/mach-pxa/poodle.c index c2b938a4d5c9..1b9d7450ae21 100644 --- a/arch/arm/mach-pxa/poodle.c +++ b/arch/arm/mach-pxa/poodle.c | |||
@@ -91,26 +91,7 @@ static unsigned long poodle_pin_config[] __initdata = { | |||
91 | GPIO35_FFUART_CTS, | 91 | GPIO35_FFUART_CTS, |
92 | 92 | ||
93 | /* LCD */ | 93 | /* LCD */ |
94 | GPIO58_LCD_LDD_0, | 94 | GPIOxx_LCD_TFT_16BPP, |
95 | GPIO59_LCD_LDD_1, | ||
96 | GPIO60_LCD_LDD_2, | ||
97 | GPIO61_LCD_LDD_3, | ||
98 | GPIO62_LCD_LDD_4, | ||
99 | GPIO63_LCD_LDD_5, | ||
100 | GPIO64_LCD_LDD_6, | ||
101 | GPIO65_LCD_LDD_7, | ||
102 | GPIO66_LCD_LDD_8, | ||
103 | GPIO67_LCD_LDD_9, | ||
104 | GPIO68_LCD_LDD_10, | ||
105 | GPIO69_LCD_LDD_11, | ||
106 | GPIO70_LCD_LDD_12, | ||
107 | GPIO71_LCD_LDD_13, | ||
108 | GPIO72_LCD_LDD_14, | ||
109 | GPIO73_LCD_LDD_15, | ||
110 | GPIO74_LCD_FCLK, | ||
111 | GPIO75_LCD_LCLK, | ||
112 | GPIO76_LCD_PCLK, | ||
113 | GPIO77_LCD_BIAS, | ||
114 | 95 | ||
115 | /* PC Card */ | 96 | /* PC Card */ |
116 | GPIO48_nPOE, | 97 | GPIO48_nPOE, |