diff options
author | Sascha Hauer <s.hauer@pengutronix.de> | 2009-06-23 06:12:00 -0400 |
---|---|---|
committer | Sascha Hauer <s.hauer@pengutronix.de> | 2009-08-07 06:10:55 -0400 |
commit | 3f4f54b4f0052e9838f6bb98535746464d0c01c3 (patch) | |
tree | 19833e9587f205745cafc7052389104f05b9a4cd /arch/arm/mach-mx3 | |
parent | bf50bcc242db7f8d2fb6bc099c1693149d9fb5d5 (diff) |
mx3: Codingstyle: Let the compiler count arrays
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Diffstat (limited to 'arch/arm/mach-mx3')
-rw-r--r-- | arch/arm/mach-mx3/devices.c | 25 | ||||
-rw-r--r-- | arch/arm/mach-mx3/mx31lite.c | 5 | ||||
-rw-r--r-- | arch/arm/mach-mx3/pcm037.c | 5 | ||||
-rw-r--r-- | arch/arm/mach-mx3/qong.c | 5 |
4 files changed, 16 insertions, 24 deletions
diff --git a/arch/arm/mach-mx3/devices.c b/arch/arm/mach-mx3/devices.c index 9e87e08fb121..7a5c2ef52a48 100644 --- a/arch/arm/mach-mx3/devices.c +++ b/arch/arm/mach-mx3/devices.c | |||
@@ -129,19 +129,17 @@ struct platform_device mxc_uart_device4 = { | |||
129 | 129 | ||
130 | /* GPIO port description */ | 130 | /* GPIO port description */ |
131 | static struct mxc_gpio_port imx_gpio_ports[] = { | 131 | static struct mxc_gpio_port imx_gpio_ports[] = { |
132 | [0] = { | 132 | { |
133 | .chip.label = "gpio-0", | 133 | .chip.label = "gpio-0", |
134 | .base = IO_ADDRESS(GPIO1_BASE_ADDR), | 134 | .base = IO_ADDRESS(GPIO1_BASE_ADDR), |
135 | .irq = MXC_INT_GPIO1, | 135 | .irq = MXC_INT_GPIO1, |
136 | .virtual_irq_start = MXC_GPIO_IRQ_START, | 136 | .virtual_irq_start = MXC_GPIO_IRQ_START, |
137 | }, | 137 | }, { |
138 | [1] = { | ||
139 | .chip.label = "gpio-1", | 138 | .chip.label = "gpio-1", |
140 | .base = IO_ADDRESS(GPIO2_BASE_ADDR), | 139 | .base = IO_ADDRESS(GPIO2_BASE_ADDR), |
141 | .irq = MXC_INT_GPIO2, | 140 | .irq = MXC_INT_GPIO2, |
142 | .virtual_irq_start = MXC_GPIO_IRQ_START + 32, | 141 | .virtual_irq_start = MXC_GPIO_IRQ_START + 32, |
143 | }, | 142 | }, { |
144 | [2] = { | ||
145 | .chip.label = "gpio-2", | 143 | .chip.label = "gpio-2", |
146 | .base = IO_ADDRESS(GPIO3_BASE_ADDR), | 144 | .base = IO_ADDRESS(GPIO3_BASE_ADDR), |
147 | .irq = MXC_INT_GPIO3, | 145 | .irq = MXC_INT_GPIO3, |
@@ -173,11 +171,11 @@ static struct resource mxc_nand_resources[] = { | |||
173 | { | 171 | { |
174 | .start = 0, /* runtime dependent */ | 172 | .start = 0, /* runtime dependent */ |
175 | .end = 0, | 173 | .end = 0, |
176 | .flags = IORESOURCE_MEM | 174 | .flags = IORESOURCE_MEM, |
177 | }, { | 175 | }, { |
178 | .start = MXC_INT_NANDFC, | 176 | .start = MXC_INT_NANDFC, |
179 | .end = MXC_INT_NANDFC, | 177 | .end = MXC_INT_NANDFC, |
180 | .flags = IORESOURCE_IRQ | 178 | .flags = IORESOURCE_IRQ, |
181 | }, | 179 | }, |
182 | }; | 180 | }; |
183 | 181 | ||
@@ -193,8 +191,7 @@ static struct resource mxc_i2c0_resources[] = { | |||
193 | .start = I2C_BASE_ADDR, | 191 | .start = I2C_BASE_ADDR, |
194 | .end = I2C_BASE_ADDR + SZ_4K - 1, | 192 | .end = I2C_BASE_ADDR + SZ_4K - 1, |
195 | .flags = IORESOURCE_MEM, | 193 | .flags = IORESOURCE_MEM, |
196 | }, | 194 | }, { |
197 | { | ||
198 | .start = MXC_INT_I2C, | 195 | .start = MXC_INT_I2C, |
199 | .end = MXC_INT_I2C, | 196 | .end = MXC_INT_I2C, |
200 | .flags = IORESOURCE_IRQ, | 197 | .flags = IORESOURCE_IRQ, |
@@ -213,8 +210,7 @@ static struct resource mxc_i2c1_resources[] = { | |||
213 | .start = I2C2_BASE_ADDR, | 210 | .start = I2C2_BASE_ADDR, |
214 | .end = I2C2_BASE_ADDR + SZ_4K - 1, | 211 | .end = I2C2_BASE_ADDR + SZ_4K - 1, |
215 | .flags = IORESOURCE_MEM, | 212 | .flags = IORESOURCE_MEM, |
216 | }, | 213 | }, { |
217 | { | ||
218 | .start = MXC_INT_I2C2, | 214 | .start = MXC_INT_I2C2, |
219 | .end = MXC_INT_I2C2, | 215 | .end = MXC_INT_I2C2, |
220 | .flags = IORESOURCE_IRQ, | 216 | .flags = IORESOURCE_IRQ, |
@@ -233,8 +229,7 @@ static struct resource mxc_i2c2_resources[] = { | |||
233 | .start = I2C3_BASE_ADDR, | 229 | .start = I2C3_BASE_ADDR, |
234 | .end = I2C3_BASE_ADDR + SZ_4K - 1, | 230 | .end = I2C3_BASE_ADDR + SZ_4K - 1, |
235 | .flags = IORESOURCE_MEM, | 231 | .flags = IORESOURCE_MEM, |
236 | }, | 232 | }, { |
237 | { | ||
238 | .start = MXC_INT_I2C3, | 233 | .start = MXC_INT_I2C3, |
239 | .end = MXC_INT_I2C3, | 234 | .end = MXC_INT_I2C3, |
240 | .flags = IORESOURCE_IRQ, | 235 | .flags = IORESOURCE_IRQ, |
@@ -400,11 +395,11 @@ static struct resource mxc_fec_resources[] = { | |||
400 | { | 395 | { |
401 | .start = MXC_FEC_BASE_ADDR, | 396 | .start = MXC_FEC_BASE_ADDR, |
402 | .end = MXC_FEC_BASE_ADDR + 0xfff, | 397 | .end = MXC_FEC_BASE_ADDR + 0xfff, |
403 | .flags = IORESOURCE_MEM | 398 | .flags = IORESOURCE_MEM, |
404 | }, { | 399 | }, { |
405 | .start = MXC_INT_FEC, | 400 | .start = MXC_INT_FEC, |
406 | .end = MXC_INT_FEC, | 401 | .end = MXC_INT_FEC, |
407 | .flags = IORESOURCE_IRQ | 402 | .flags = IORESOURCE_IRQ, |
408 | }, | 403 | }, |
409 | }; | 404 | }; |
410 | 405 | ||
diff --git a/arch/arm/mach-mx3/mx31lite.c b/arch/arm/mach-mx3/mx31lite.c index b1c0afc40cf2..a8d57decdfdb 100644 --- a/arch/arm/mach-mx3/mx31lite.c +++ b/arch/arm/mach-mx3/mx31lite.c | |||
@@ -71,12 +71,11 @@ static struct smsc911x_platform_config smsc911x_config = { | |||
71 | }; | 71 | }; |
72 | 72 | ||
73 | static struct resource smsc911x_resources[] = { | 73 | static struct resource smsc911x_resources[] = { |
74 | [0] = { | 74 | { |
75 | .start = CS4_BASE_ADDR, | 75 | .start = CS4_BASE_ADDR, |
76 | .end = CS4_BASE_ADDR + 0x100, | 76 | .end = CS4_BASE_ADDR + 0x100, |
77 | .flags = IORESOURCE_MEM, | 77 | .flags = IORESOURCE_MEM, |
78 | }, | 78 | }, { |
79 | [1] = { | ||
80 | .start = IOMUX_TO_IRQ(MX31_PIN_SFS6), | 79 | .start = IOMUX_TO_IRQ(MX31_PIN_SFS6), |
81 | .end = IOMUX_TO_IRQ(MX31_PIN_SFS6), | 80 | .end = IOMUX_TO_IRQ(MX31_PIN_SFS6), |
82 | .flags = IORESOURCE_IRQ, | 81 | .flags = IORESOURCE_IRQ, |
diff --git a/arch/arm/mach-mx3/pcm037.c b/arch/arm/mach-mx3/pcm037.c index d8472206de90..c755c06b75d1 100644 --- a/arch/arm/mach-mx3/pcm037.c +++ b/arch/arm/mach-mx3/pcm037.c | |||
@@ -244,12 +244,11 @@ static struct imxuart_platform_data uart_pdata = { | |||
244 | }; | 244 | }; |
245 | 245 | ||
246 | static struct resource smsc911x_resources[] = { | 246 | static struct resource smsc911x_resources[] = { |
247 | [0] = { | 247 | { |
248 | .start = CS1_BASE_ADDR + 0x300, | 248 | .start = CS1_BASE_ADDR + 0x300, |
249 | .end = CS1_BASE_ADDR + 0x300 + SZ_64K - 1, | 249 | .end = CS1_BASE_ADDR + 0x300 + SZ_64K - 1, |
250 | .flags = IORESOURCE_MEM, | 250 | .flags = IORESOURCE_MEM, |
251 | }, | 251 | }, { |
252 | [1] = { | ||
253 | .start = IOMUX_TO_IRQ(MX31_PIN_GPIO3_1), | 252 | .start = IOMUX_TO_IRQ(MX31_PIN_GPIO3_1), |
254 | .end = IOMUX_TO_IRQ(MX31_PIN_GPIO3_1), | 253 | .end = IOMUX_TO_IRQ(MX31_PIN_GPIO3_1), |
255 | .flags = IORESOURCE_IRQ | IORESOURCE_IRQ_LOWLEVEL, | 254 | .flags = IORESOURCE_IRQ | IORESOURCE_IRQ_LOWLEVEL, |
diff --git a/arch/arm/mach-mx3/qong.c b/arch/arm/mach-mx3/qong.c index 0bca4d914abc..044511f1b9a9 100644 --- a/arch/arm/mach-mx3/qong.c +++ b/arch/arm/mach-mx3/qong.c | |||
@@ -81,13 +81,12 @@ static inline void mxc_init_imx_uart(void) | |||
81 | } | 81 | } |
82 | 82 | ||
83 | static struct resource dnet_resources[] = { | 83 | static struct resource dnet_resources[] = { |
84 | [0] = { | 84 | { |
85 | .name = "dnet-memory", | 85 | .name = "dnet-memory", |
86 | .start = QONG_DNET_BASEADDR, | 86 | .start = QONG_DNET_BASEADDR, |
87 | .end = QONG_DNET_BASEADDR + QONG_DNET_SIZE - 1, | 87 | .end = QONG_DNET_BASEADDR + QONG_DNET_SIZE - 1, |
88 | .flags = IORESOURCE_MEM, | 88 | .flags = IORESOURCE_MEM, |
89 | }, | 89 | }, { |
90 | [1] = { | ||
91 | .start = QONG_FPGA_IRQ, | 90 | .start = QONG_FPGA_IRQ, |
92 | .end = QONG_FPGA_IRQ, | 91 | .end = QONG_FPGA_IRQ, |
93 | .flags = IORESOURCE_IRQ, | 92 | .flags = IORESOURCE_IRQ, |