aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLennert Buytenhek <buytenh@wantstofly.org>2008-05-10 10:30:01 -0400
committerLennert Buytenhek <buytenh@marvell.com>2008-06-22 16:44:39 -0400
commite7068ad337a991fba627148a4a57939fdc1e6a2d (patch)
tree6fcfe2a48ffe83b8ccb9539333ee6c2b60d779d7
parentf91a8dcc25398c5d708056de081d6cebf3f2023e (diff)
[ARM] Orion: fix various whitespace and coding style issues
More cosmetic cleanup: - Replace 8-space indents by proper tab indents. - In structure initialisers, use a trailing comma for every member. - Collapse "},\n{" in structure initialiers to "}, {". Signed-off-by: Lennert Buytenhek <buytenh@marvell.com> Acked-by: Russell King <linux@arm.linux.org.uk>
-rw-r--r--arch/arm/mach-orion5x/common.c91
-rw-r--r--arch/arm/mach-orion5x/db88f5281-setup.c13
-rw-r--r--arch/arm/mach-orion5x/dns323-setup.c33
-rw-r--r--arch/arm/mach-orion5x/kurobox_pro-setup.c8
-rw-r--r--arch/arm/mach-orion5x/pci.c14
-rw-r--r--arch/arm/mach-orion5x/rd88f5182-setup.c3
-rw-r--r--arch/arm/mach-orion5x/ts209-setup.c103
-rw-r--r--arch/arm/mm/proc-feroceon.S8
8 files changed, 132 insertions, 141 deletions
diff --git a/arch/arm/mach-orion5x/common.c b/arch/arm/mach-orion5x/common.c
index 4f13fd037f04..fa4be3cb1549 100644
--- a/arch/arm/mach-orion5x/common.c
+++ b/arch/arm/mach-orion5x/common.c
@@ -39,25 +39,22 @@ static struct map_desc orion5x_io_desc[] __initdata = {
39 .virtual = ORION5X_REGS_VIRT_BASE, 39 .virtual = ORION5X_REGS_VIRT_BASE,
40 .pfn = __phys_to_pfn(ORION5X_REGS_PHYS_BASE), 40 .pfn = __phys_to_pfn(ORION5X_REGS_PHYS_BASE),
41 .length = ORION5X_REGS_SIZE, 41 .length = ORION5X_REGS_SIZE,
42 .type = MT_DEVICE 42 .type = MT_DEVICE,
43 }, 43 }, {
44 {
45 .virtual = ORION5X_PCIE_IO_VIRT_BASE, 44 .virtual = ORION5X_PCIE_IO_VIRT_BASE,
46 .pfn = __phys_to_pfn(ORION5X_PCIE_IO_PHYS_BASE), 45 .pfn = __phys_to_pfn(ORION5X_PCIE_IO_PHYS_BASE),
47 .length = ORION5X_PCIE_IO_SIZE, 46 .length = ORION5X_PCIE_IO_SIZE,
48 .type = MT_DEVICE 47 .type = MT_DEVICE,
49 }, 48 }, {
50 {
51 .virtual = ORION5X_PCI_IO_VIRT_BASE, 49 .virtual = ORION5X_PCI_IO_VIRT_BASE,
52 .pfn = __phys_to_pfn(ORION5X_PCI_IO_PHYS_BASE), 50 .pfn = __phys_to_pfn(ORION5X_PCI_IO_PHYS_BASE),
53 .length = ORION5X_PCI_IO_SIZE, 51 .length = ORION5X_PCI_IO_SIZE,
54 .type = MT_DEVICE 52 .type = MT_DEVICE,
55 }, 53 }, {
56 {
57 .virtual = ORION5X_PCIE_WA_VIRT_BASE, 54 .virtual = ORION5X_PCIE_WA_VIRT_BASE,
58 .pfn = __phys_to_pfn(ORION5X_PCIE_WA_PHYS_BASE), 55 .pfn = __phys_to_pfn(ORION5X_PCIE_WA_PHYS_BASE),
59 .length = ORION5X_PCIE_WA_SIZE, 56 .length = ORION5X_PCIE_WA_SIZE,
60 .type = MT_DEVICE 57 .type = MT_DEVICE,
61 }, 58 },
62}; 59};
63 60
@@ -75,18 +72,15 @@ static struct resource orion5x_uart_resources[] = {
75 .start = UART0_PHYS_BASE, 72 .start = UART0_PHYS_BASE,
76 .end = UART0_PHYS_BASE + 0xff, 73 .end = UART0_PHYS_BASE + 0xff,
77 .flags = IORESOURCE_MEM, 74 .flags = IORESOURCE_MEM,
78 }, 75 }, {
79 {
80 .start = IRQ_ORION5X_UART0, 76 .start = IRQ_ORION5X_UART0,
81 .end = IRQ_ORION5X_UART0, 77 .end = IRQ_ORION5X_UART0,
82 .flags = IORESOURCE_IRQ, 78 .flags = IORESOURCE_IRQ,
83 }, 79 }, {
84 {
85 .start = UART1_PHYS_BASE, 80 .start = UART1_PHYS_BASE,
86 .end = UART1_PHYS_BASE + 0xff, 81 .end = UART1_PHYS_BASE + 0xff,
87 .flags = IORESOURCE_MEM, 82 .flags = IORESOURCE_MEM,
88 }, 83 }, {
89 {
90 .start = IRQ_ORION5X_UART1, 84 .start = IRQ_ORION5X_UART1,
91 .end = IRQ_ORION5X_UART1, 85 .end = IRQ_ORION5X_UART1,
92 .flags = IORESOURCE_IRQ, 86 .flags = IORESOURCE_IRQ,
@@ -102,8 +96,7 @@ static struct plat_serial8250_port orion5x_uart_data[] = {
102 .iotype = UPIO_MEM, 96 .iotype = UPIO_MEM,
103 .regshift = 2, 97 .regshift = 2,
104 .uartclk = ORION5X_TCLK, 98 .uartclk = ORION5X_TCLK,
105 }, 99 }, {
106 {
107 .mapbase = UART1_PHYS_BASE, 100 .mapbase = UART1_PHYS_BASE,
108 .membase = (char *)UART1_VIRT_BASE, 101 .membase = (char *)UART1_VIRT_BASE,
109 .irq = IRQ_ORION5X_UART1, 102 .irq = IRQ_ORION5X_UART1,
@@ -111,8 +104,8 @@ static struct plat_serial8250_port orion5x_uart_data[] = {
111 .iotype = UPIO_MEM, 104 .iotype = UPIO_MEM,
112 .regshift = 2, 105 .regshift = 2,
113 .uartclk = ORION5X_TCLK, 106 .uartclk = ORION5X_TCLK,
107 }, {
114 }, 108 },
115 { },
116}; 109};
117 110
118static struct platform_device orion5x_uart = { 111static struct platform_device orion5x_uart = {
@@ -134,8 +127,7 @@ static struct resource orion5x_ehci0_resources[] = {
134 .start = ORION5X_USB0_PHYS_BASE, 127 .start = ORION5X_USB0_PHYS_BASE,
135 .end = ORION5X_USB0_PHYS_BASE + SZ_4K - 1, 128 .end = ORION5X_USB0_PHYS_BASE + SZ_4K - 1,
136 .flags = IORESOURCE_MEM, 129 .flags = IORESOURCE_MEM,
137 }, 130 }, {
138 {
139 .start = IRQ_ORION5X_USB0_CTRL, 131 .start = IRQ_ORION5X_USB0_CTRL,
140 .end = IRQ_ORION5X_USB0_CTRL, 132 .end = IRQ_ORION5X_USB0_CTRL,
141 .flags = IORESOURCE_IRQ, 133 .flags = IORESOURCE_IRQ,
@@ -147,8 +139,7 @@ static struct resource orion5x_ehci1_resources[] = {
147 .start = ORION5X_USB1_PHYS_BASE, 139 .start = ORION5X_USB1_PHYS_BASE,
148 .end = ORION5X_USB1_PHYS_BASE + SZ_4K - 1, 140 .end = ORION5X_USB1_PHYS_BASE + SZ_4K - 1,
149 .flags = IORESOURCE_MEM, 141 .flags = IORESOURCE_MEM,
150 }, 142 }, {
151 {
152 .start = IRQ_ORION5X_USB1_CTRL, 143 .start = IRQ_ORION5X_USB1_CTRL,
153 .end = IRQ_ORION5X_USB1_CTRL, 144 .end = IRQ_ORION5X_USB1_CTRL,
154 .flags = IORESOURCE_IRQ, 145 .flags = IORESOURCE_IRQ,
@@ -219,7 +210,7 @@ static struct resource orion5x_eth_resources[] = {
219 .start = IRQ_ORION5X_ETH_SUM, 210 .start = IRQ_ORION5X_ETH_SUM,
220 .end = IRQ_ORION5X_ETH_SUM, 211 .end = IRQ_ORION5X_ETH_SUM,
221 .flags = IORESOURCE_IRQ, 212 .flags = IORESOURCE_IRQ,
222 } 213 },
223}; 214};
224 215
225static struct platform_device orion5x_eth = { 216static struct platform_device orion5x_eth = {
@@ -251,16 +242,15 @@ static struct mv64xxx_i2c_pdata orion5x_i2c_pdata = {
251 242
252static struct resource orion5x_i2c_resources[] = { 243static struct resource orion5x_i2c_resources[] = {
253 { 244 {
254 .name = "i2c base", 245 .name = "i2c base",
255 .start = I2C_PHYS_BASE, 246 .start = I2C_PHYS_BASE,
256 .end = I2C_PHYS_BASE + 0x20 -1, 247 .end = I2C_PHYS_BASE + 0x20 -1,
257 .flags = IORESOURCE_MEM, 248 .flags = IORESOURCE_MEM,
258 }, 249 }, {
259 { 250 .name = "i2c irq",
260 .name = "i2c irq", 251 .start = IRQ_ORION5X_I2C,
261 .start = IRQ_ORION5X_I2C, 252 .end = IRQ_ORION5X_I2C,
262 .end = IRQ_ORION5X_I2C, 253 .flags = IORESOURCE_IRQ,
263 .flags = IORESOURCE_IRQ,
264 }, 254 },
265}; 255};
266 256
@@ -270,7 +260,7 @@ static struct platform_device orion5x_i2c = {
270 .num_resources = ARRAY_SIZE(orion5x_i2c_resources), 260 .num_resources = ARRAY_SIZE(orion5x_i2c_resources),
271 .resource = orion5x_i2c_resources, 261 .resource = orion5x_i2c_resources,
272 .dev = { 262 .dev = {
273 .platform_data = &orion5x_i2c_pdata, 263 .platform_data = &orion5x_i2c_pdata,
274 }, 264 },
275}; 265};
276 266
@@ -278,28 +268,27 @@ static struct platform_device orion5x_i2c = {
278 * Sata port 268 * Sata port
279 ****************************************************************************/ 269 ****************************************************************************/
280static struct resource orion5x_sata_resources[] = { 270static struct resource orion5x_sata_resources[] = {
281 {
282 .name = "sata base",
283 .start = ORION5X_SATA_PHYS_BASE,
284 .end = ORION5X_SATA_PHYS_BASE + 0x5000 - 1,
285 .flags = IORESOURCE_MEM,
286 },
287 { 271 {
288 .name = "sata irq", 272 .name = "sata base",
289 .start = IRQ_ORION5X_SATA, 273 .start = ORION5X_SATA_PHYS_BASE,
290 .end = IRQ_ORION5X_SATA, 274 .end = ORION5X_SATA_PHYS_BASE + 0x5000 - 1,
291 .flags = IORESOURCE_IRQ, 275 .flags = IORESOURCE_MEM,
292 }, 276 }, {
277 .name = "sata irq",
278 .start = IRQ_ORION5X_SATA,
279 .end = IRQ_ORION5X_SATA,
280 .flags = IORESOURCE_IRQ,
281 },
293}; 282};
294 283
295static struct platform_device orion5x_sata = { 284static struct platform_device orion5x_sata = {
296 .name = "sata_mv", 285 .name = "sata_mv",
297 .id = 0, 286 .id = 0,
298 .dev = { 287 .dev = {
299 .coherent_dma_mask = 0xffffffff, 288 .coherent_dma_mask = 0xffffffff,
300 }, 289 },
301 .num_resources = ARRAY_SIZE(orion5x_sata_resources), 290 .num_resources = ARRAY_SIZE(orion5x_sata_resources),
302 .resource = orion5x_sata_resources, 291 .resource = orion5x_sata_resources,
303}; 292};
304 293
305void __init orion5x_sata_init(struct mv_sata_platform_data *sata_data) 294void __init orion5x_sata_init(struct mv_sata_platform_data *sata_data)
@@ -319,7 +308,7 @@ static void orion5x_timer_init(void)
319} 308}
320 309
321struct sys_timer orion5x_timer = { 310struct sys_timer orion5x_timer = {
322 .init = orion5x_timer_init, 311 .init = orion5x_timer_init,
323}; 312};
324 313
325/***************************************************************************** 314/*****************************************************************************
diff --git a/arch/arm/mach-orion5x/db88f5281-setup.c b/arch/arm/mach-orion5x/db88f5281-setup.c
index 44c64342dacb..4ee695028254 100644
--- a/arch/arm/mach-orion5x/db88f5281-setup.c
+++ b/arch/arm/mach-orion5x/db88f5281-setup.c
@@ -86,7 +86,7 @@ static struct platform_device db88f5281_boot_flash = {
86 .name = "physmap-flash", 86 .name = "physmap-flash",
87 .id = 0, 87 .id = 0,
88 .dev = { 88 .dev = {
89 .platform_data = &db88f5281_boot_flash_data, 89 .platform_data = &db88f5281_boot_flash_data,
90 }, 90 },
91 .num_resources = 1, 91 .num_resources = 1,
92 .resource = &db88f5281_boot_flash_resource, 92 .resource = &db88f5281_boot_flash_resource,
@@ -110,7 +110,7 @@ static struct platform_device db88f5281_nor_flash = {
110 .name = "physmap-flash", 110 .name = "physmap-flash",
111 .id = 1, 111 .id = 1,
112 .dev = { 112 .dev = {
113 .platform_data = &db88f5281_nor_flash_data, 113 .platform_data = &db88f5281_nor_flash_data,
114 }, 114 },
115 .num_resources = 1, 115 .num_resources = 1,
116 .resource = &db88f5281_nor_flash_resource, 116 .resource = &db88f5281_nor_flash_resource,
@@ -125,18 +125,15 @@ static struct mtd_partition db88f5281_nand_parts[] = {
125 .name = "kernel", 125 .name = "kernel",
126 .offset = 0, 126 .offset = 0,
127 .size = SZ_2M, 127 .size = SZ_2M,
128 }, 128 }, {
129 {
130 .name = "root", 129 .name = "root",
131 .offset = SZ_2M, 130 .offset = SZ_2M,
132 .size = (SZ_16M - SZ_2M), 131 .size = (SZ_16M - SZ_2M),
133 }, 132 }, {
134 {
135 .name = "user", 133 .name = "user",
136 .offset = SZ_16M, 134 .offset = SZ_16M,
137 .size = SZ_8M, 135 .size = SZ_8M,
138 }, 136 }, {
139 {
140 .name = "recovery", 137 .name = "recovery",
141 .offset = (SZ_16M + SZ_8M), 138 .offset = (SZ_16M + SZ_8M),
142 .size = SZ_8M, 139 .size = SZ_8M,
diff --git a/arch/arm/mach-orion5x/dns323-setup.c b/arch/arm/mach-orion5x/dns323-setup.c
index 27ce967ab9e5..ec53f866ed11 100644
--- a/arch/arm/mach-orion5x/dns323-setup.c
+++ b/arch/arm/mach-orion5x/dns323-setup.c
@@ -119,7 +119,7 @@ static struct mtd_partition dns323_partitions[] = {
119 .name = "u-boot", 119 .name = "u-boot",
120 .size = 0x00030000, 120 .size = 0x00030000,
121 .offset = 0x007d0000, 121 .offset = 0x007d0000,
122 } 122 },
123}; 123};
124 124
125static struct physmap_flash_data dns323_nor_flash_data = { 125static struct physmap_flash_data dns323_nor_flash_data = {
@@ -137,7 +137,9 @@ static struct resource dns323_nor_flash_resource = {
137static struct platform_device dns323_nor_flash = { 137static struct platform_device dns323_nor_flash = {
138 .name = "physmap-flash", 138 .name = "physmap-flash",
139 .id = 0, 139 .id = 0,
140 .dev = { .platform_data = &dns323_nor_flash_data, }, 140 .dev = {
141 .platform_data = &dns323_nor_flash_data,
142 },
141 .resource = &dns323_nor_flash_resource, 143 .resource = &dns323_nor_flash_resource,
142 .num_resources = 1, 144 .num_resources = 1,
143}; 145};
@@ -170,7 +172,9 @@ static struct gpio_led_platform_data dns323_led_data = {
170static struct platform_device dns323_gpio_leds = { 172static struct platform_device dns323_gpio_leds = {
171 .name = "leds-gpio", 173 .name = "leds-gpio",
172 .id = -1, 174 .id = -1,
173 .dev = { .platform_data = &dns323_led_data, }, 175 .dev = {
176 .platform_data = &dns323_led_data,
177 },
174}; 178};
175 179
176/**************************************************************************** 180/****************************************************************************
@@ -183,25 +187,26 @@ static struct gpio_keys_button dns323_buttons[] = {
183 .gpio = DNS323_GPIO_KEY_RESET, 187 .gpio = DNS323_GPIO_KEY_RESET,
184 .desc = "Reset Button", 188 .desc = "Reset Button",
185 .active_low = 1, 189 .active_low = 1,
186 }, 190 }, {
187 {
188 .code = KEY_POWER, 191 .code = KEY_POWER,
189 .gpio = DNS323_GPIO_KEY_POWER, 192 .gpio = DNS323_GPIO_KEY_POWER,
190 .desc = "Power Button", 193 .desc = "Power Button",
191 .active_low = 1, 194 .active_low = 1,
192 } 195 },
193}; 196};
194 197
195static struct gpio_keys_platform_data dns323_button_data = { 198static struct gpio_keys_platform_data dns323_button_data = {
196 .buttons = dns323_buttons, 199 .buttons = dns323_buttons,
197 .nbuttons = ARRAY_SIZE(dns323_buttons), 200 .nbuttons = ARRAY_SIZE(dns323_buttons),
198}; 201};
199 202
200static struct platform_device dns323_button_device = { 203static struct platform_device dns323_button_device = {
201 .name = "gpio-keys", 204 .name = "gpio-keys",
202 .id = -1, 205 .id = -1,
203 .num_resources = 0, 206 .num_resources = 0,
204 .dev = { .platform_data = &dns323_button_data, }, 207 .dev = {
208 .platform_data = &dns323_button_data,
209 },
205}; 210};
206 211
207/**************************************************************************** 212/****************************************************************************
@@ -225,17 +230,15 @@ static struct platform_device *dns323_plat_devices[] __initdata = {
225static struct i2c_board_info __initdata dns323_i2c_devices[] = { 230static struct i2c_board_info __initdata dns323_i2c_devices[] = {
226 { 231 {
227 I2C_BOARD_INFO("g760a", 0x3e), 232 I2C_BOARD_INFO("g760a", 0x3e),
228 },
229#if 0 233#if 0
230 /* this entry requires the new-style driver model lm75 driver, 234 /* this entry requires the new-style driver model lm75 driver,
231 * for the meantime "insmod lm75.ko force_lm75=0,0x48" is needed */ 235 * for the meantime "insmod lm75.ko force_lm75=0,0x48" is needed */
232 { 236 }, {
233 I2C_BOARD_INFO("g751", 0x48), 237 I2C_BOARD_INFO("g751", 0x48),
234 },
235#endif 238#endif
236 { 239 }, {
237 I2C_BOARD_INFO("m41t80", 0x68), 240 I2C_BOARD_INFO("m41t80", 0x68),
238 } 241 },
239}; 242};
240 243
241/* DNS-323 specific power off method */ 244/* DNS-323 specific power off method */
@@ -292,8 +295,8 @@ static void __init dns323_init(void)
292 orion5x_gpio_set_valid_pins(0x07f6); 295 orion5x_gpio_set_valid_pins(0x07f6);
293 296
294 /* register dns323 specific power-off method */ 297 /* register dns323 specific power-off method */
295 if ((gpio_request(DNS323_GPIO_POWER_OFF, "POWEROFF") != 0) 298 if (gpio_request(DNS323_GPIO_POWER_OFF, "POWEROFF") != 0 ||
296 || (gpio_direction_output(DNS323_GPIO_POWER_OFF, 0) != 0)) 299 gpio_direction_output(DNS323_GPIO_POWER_OFF, 0) != 0)
297 pr_err("DNS323: failed to setup power-off GPIO\n"); 300 pr_err("DNS323: failed to setup power-off GPIO\n");
298 301
299 pm_power_off = dns323_power_off; 302 pm_power_off = dns323_power_off;
diff --git a/arch/arm/mach-orion5x/kurobox_pro-setup.c b/arch/arm/mach-orion5x/kurobox_pro-setup.c
index f5074b877b7f..60fcbf1e5d72 100644
--- a/arch/arm/mach-orion5x/kurobox_pro-setup.c
+++ b/arch/arm/mach-orion5x/kurobox_pro-setup.c
@@ -53,13 +53,11 @@ static struct mtd_partition kurobox_pro_nand_parts[] = {
53 .name = "uImage", 53 .name = "uImage",
54 .offset = 0, 54 .offset = 0,
55 .size = SZ_4M, 55 .size = SZ_4M,
56 }, 56 }, {
57 {
58 .name = "rootfs", 57 .name = "rootfs",
59 .offset = SZ_4M, 58 .offset = SZ_4M,
60 .size = SZ_64M, 59 .size = SZ_64M,
61 }, 60 }, {
62 {
63 .name = "extra", 61 .name = "extra",
64 .offset = SZ_4M + SZ_64M, 62 .offset = SZ_4M + SZ_64M,
65 .size = SZ_256M - (SZ_4M + SZ_64M), 63 .size = SZ_256M - (SZ_4M + SZ_64M),
@@ -175,7 +173,7 @@ static struct i2c_board_info __initdata kurobox_pro_i2c_rtc = {
175 * SATA 173 * SATA
176 ****************************************************************************/ 174 ****************************************************************************/
177static struct mv_sata_platform_data kurobox_pro_sata_data = { 175static struct mv_sata_platform_data kurobox_pro_sata_data = {
178 .n_ports = 2, 176 .n_ports = 2,
179}; 177};
180 178
181/***************************************************************************** 179/*****************************************************************************
diff --git a/arch/arm/mach-orion5x/pci.c b/arch/arm/mach-orion5x/pci.c
index 9d5d39fa19c3..1bbfe24607b0 100644
--- a/arch/arm/mach-orion5x/pci.c
+++ b/arch/arm/mach-orion5x/pci.c
@@ -240,13 +240,13 @@ static int __init pcie_setup(struct pci_sys_data *sys)
240 * PCI Address Decode Windows registers 240 * PCI Address Decode Windows registers
241 */ 241 */
242#define PCI_BAR_SIZE_DDR_CS(n) (((n) == 0) ? ORION5X_PCI_REG(0xc08) : \ 242#define PCI_BAR_SIZE_DDR_CS(n) (((n) == 0) ? ORION5X_PCI_REG(0xc08) : \
243 ((n) == 1) ? ORION5X_PCI_REG(0xd08) : \ 243 ((n) == 1) ? ORION5X_PCI_REG(0xd08) : \
244 ((n) == 2) ? ORION5X_PCI_REG(0xc0c) : \ 244 ((n) == 2) ? ORION5X_PCI_REG(0xc0c) : \
245 ((n) == 3) ? ORION5X_PCI_REG(0xd0c) : 0) 245 ((n) == 3) ? ORION5X_PCI_REG(0xd0c) : 0)
246#define PCI_BAR_REMAP_DDR_CS(n) (((n) ==0) ? ORION5X_PCI_REG(0xc48) : \ 246#define PCI_BAR_REMAP_DDR_CS(n) (((n) == 0) ? ORION5X_PCI_REG(0xc48) : \
247 ((n) == 1) ? ORION5X_PCI_REG(0xd48) : \ 247 ((n) == 1) ? ORION5X_PCI_REG(0xd48) : \
248 ((n) == 2) ? ORION5X_PCI_REG(0xc4c) : \ 248 ((n) == 2) ? ORION5X_PCI_REG(0xc4c) : \
249 ((n) == 3) ? ORION5X_PCI_REG(0xd4c) : 0) 249 ((n) == 3) ? ORION5X_PCI_REG(0xd4c) : 0)
250#define PCI_BAR_ENABLE ORION5X_PCI_REG(0xc3c) 250#define PCI_BAR_ENABLE ORION5X_PCI_REG(0xc3c)
251#define PCI_ADDR_DECODE_CTRL ORION5X_PCI_REG(0xd3c) 251#define PCI_ADDR_DECODE_CTRL ORION5X_PCI_REG(0xd3c)
252 252
diff --git a/arch/arm/mach-orion5x/rd88f5182-setup.c b/arch/arm/mach-orion5x/rd88f5182-setup.c
index 81abc1003aae..62fd99fc664a 100644
--- a/arch/arm/mach-orion5x/rd88f5182-setup.c
+++ b/arch/arm/mach-orion5x/rd88f5182-setup.c
@@ -125,6 +125,7 @@ static int __init rd88f5182_dbgled_init(void)
125 125
126 leds_event = rd88f5182_dbgled_event; 126 leds_event = rd88f5182_dbgled_event;
127 } 127 }
128
128 return 0; 129 return 0;
129} 130}
130 131
@@ -234,7 +235,7 @@ static struct i2c_board_info __initdata rd88f5182_i2c_rtc = {
234 * Sata 235 * Sata
235 ****************************************************************************/ 236 ****************************************************************************/
236static struct mv_sata_platform_data rd88f5182_sata_data = { 237static struct mv_sata_platform_data rd88f5182_sata_data = {
237 .n_ports = 2, 238 .n_ports = 2,
238}; 239};
239 240
240/***************************************************************************** 241/*****************************************************************************
diff --git a/arch/arm/mach-orion5x/ts209-setup.c b/arch/arm/mach-orion5x/ts209-setup.c
index 9afb41ee6e07..5374b6edb9a1 100644
--- a/arch/arm/mach-orion5x/ts209-setup.c
+++ b/arch/arm/mach-orion5x/ts209-setup.c
@@ -47,52 +47,54 @@
47 ***************************************************************************/ 47 ***************************************************************************/
48static struct mtd_partition qnap_ts209_partitions[] = { 48static struct mtd_partition qnap_ts209_partitions[] = {
49 { 49 {
50 .name = "U-Boot", 50 .name = "U-Boot",
51 .size = 0x00080000, 51 .size = 0x00080000,
52 .offset = 0x00780000, 52 .offset = 0x00780000,
53 .mask_flags = MTD_WRITEABLE, 53 .mask_flags = MTD_WRITEABLE,
54 }, { 54 }, {
55 .name = "Kernel", 55 .name = "Kernel",
56 .size = 0x00200000, 56 .size = 0x00200000,
57 .offset = 0, 57 .offset = 0,
58 }, { 58 }, {
59 .name = "RootFS1", 59 .name = "RootFS1",
60 .size = 0x00400000, 60 .size = 0x00400000,
61 .offset = 0x00200000, 61 .offset = 0x00200000,
62 }, { 62 }, {
63 .name = "RootFS2", 63 .name = "RootFS2",
64 .size = 0x00100000, 64 .size = 0x00100000,
65 .offset = 0x00600000, 65 .offset = 0x00600000,
66 }, { 66 }, {
67 .name = "U-Boot Config", 67 .name = "U-Boot Config",
68 .size = 0x00020000, 68 .size = 0x00020000,
69 .offset = 0x00760000, 69 .offset = 0x00760000,
70 }, { 70 }, {
71 .name = "NAS Config", 71 .name = "NAS Config",
72 .size = 0x00060000, 72 .size = 0x00060000,
73 .offset = 0x00700000, 73 .offset = 0x00700000,
74 .mask_flags = MTD_WRITEABLE, 74 .mask_flags = MTD_WRITEABLE,
75 } 75 },
76}; 76};
77 77
78static struct physmap_flash_data qnap_ts209_nor_flash_data = { 78static struct physmap_flash_data qnap_ts209_nor_flash_data = {
79 .width = 1, 79 .width = 1,
80 .parts = qnap_ts209_partitions, 80 .parts = qnap_ts209_partitions,
81 .nr_parts = ARRAY_SIZE(qnap_ts209_partitions) 81 .nr_parts = ARRAY_SIZE(qnap_ts209_partitions)
82}; 82};
83 83
84static struct resource qnap_ts209_nor_flash_resource = { 84static struct resource qnap_ts209_nor_flash_resource = {
85 .flags = IORESOURCE_MEM, 85 .flags = IORESOURCE_MEM,
86 .start = QNAP_TS209_NOR_BOOT_BASE, 86 .start = QNAP_TS209_NOR_BOOT_BASE,
87 .end = QNAP_TS209_NOR_BOOT_BASE + QNAP_TS209_NOR_BOOT_SIZE - 1, 87 .end = QNAP_TS209_NOR_BOOT_BASE + QNAP_TS209_NOR_BOOT_SIZE - 1,
88}; 88};
89 89
90static struct platform_device qnap_ts209_nor_flash = { 90static struct platform_device qnap_ts209_nor_flash = {
91 .name = "physmap-flash", 91 .name = "physmap-flash",
92 .id = 0, 92 .id = 0,
93 .dev = { .platform_data = &qnap_ts209_nor_flash_data, }, 93 .dev = {
94 .resource = &qnap_ts209_nor_flash_resource, 94 .platform_data = &qnap_ts209_nor_flash_data,
95 .num_resources = 1, 95 },
96 .resource = &qnap_ts209_nor_flash_resource,
97 .num_resources = 1,
96}; 98};
97 99
98/***************************************************************************** 100/*****************************************************************************
@@ -164,12 +166,12 @@ static int __init qnap_ts209_pci_map_irq(struct pci_dev *dev, u8 slot, u8 pin)
164} 166}
165 167
166static struct hw_pci qnap_ts209_pci __initdata = { 168static struct hw_pci qnap_ts209_pci __initdata = {
167 .nr_controllers = 2, 169 .nr_controllers = 2,
168 .preinit = qnap_ts209_pci_preinit, 170 .preinit = qnap_ts209_pci_preinit,
169 .swizzle = pci_std_swizzle, 171 .swizzle = pci_std_swizzle,
170 .setup = orion5x_pci_sys_setup, 172 .setup = orion5x_pci_sys_setup,
171 .scan = orion5x_pci_sys_scan_bus, 173 .scan = orion5x_pci_sys_scan_bus,
172 .map_irq = qnap_ts209_pci_map_irq, 174 .map_irq = qnap_ts209_pci_map_irq,
173}; 175};
174 176
175static int __init qnap_ts209_pci_init(void) 177static int __init qnap_ts209_pci_init(void)
@@ -187,8 +189,8 @@ subsys_initcall(qnap_ts209_pci_init);
187 ****************************************************************************/ 189 ****************************************************************************/
188 190
189static struct mv643xx_eth_platform_data qnap_ts209_eth_data = { 191static struct mv643xx_eth_platform_data qnap_ts209_eth_data = {
190 .phy_addr = 8, 192 .phy_addr = 8,
191 .force_phy_addr = 1, 193 .force_phy_addr = 1,
192}; 194};
193 195
194static int __init parse_hex_nibble(char n) 196static int __init parse_hex_nibble(char n)
@@ -280,7 +282,7 @@ static void __init ts209_find_mac_addr(void)
280 282
281static struct i2c_board_info __initdata qnap_ts209_i2c_rtc = { 283static struct i2c_board_info __initdata qnap_ts209_i2c_rtc = {
282 I2C_BOARD_INFO("s35390a", 0x30), 284 I2C_BOARD_INFO("s35390a", 0x30),
283 .irq = 0, 285 .irq = 0,
284}; 286};
285 287
286/**************************************************************************** 288/****************************************************************************
@@ -297,32 +299,33 @@ static struct gpio_keys_button qnap_ts209_buttons[] = {
297 .gpio = QNAP_TS209_GPIO_KEY_MEDIA, 299 .gpio = QNAP_TS209_GPIO_KEY_MEDIA,
298 .desc = "USB Copy Button", 300 .desc = "USB Copy Button",
299 .active_low = 1, 301 .active_low = 1,
300 }, 302 }, {
301 {
302 .code = KEY_POWER, 303 .code = KEY_POWER,
303 .gpio = QNAP_TS209_GPIO_KEY_RESET, 304 .gpio = QNAP_TS209_GPIO_KEY_RESET,
304 .desc = "Reset Button", 305 .desc = "Reset Button",
305 .active_low = 1, 306 .active_low = 1,
306 } 307 },
307}; 308};
308 309
309static struct gpio_keys_platform_data qnap_ts209_button_data = { 310static struct gpio_keys_platform_data qnap_ts209_button_data = {
310 .buttons = qnap_ts209_buttons, 311 .buttons = qnap_ts209_buttons,
311 .nbuttons = ARRAY_SIZE(qnap_ts209_buttons), 312 .nbuttons = ARRAY_SIZE(qnap_ts209_buttons),
312}; 313};
313 314
314static struct platform_device qnap_ts209_button_device = { 315static struct platform_device qnap_ts209_button_device = {
315 .name = "gpio-keys", 316 .name = "gpio-keys",
316 .id = -1, 317 .id = -1,
317 .num_resources = 0, 318 .num_resources = 0,
318 .dev = { .platform_data = &qnap_ts209_button_data, }, 319 .dev = {
320 .platform_data = &qnap_ts209_button_data,
321 },
319}; 322};
320 323
321/***************************************************************************** 324/*****************************************************************************
322 * SATA 325 * SATA
323 ****************************************************************************/ 326 ****************************************************************************/
324static struct mv_sata_platform_data qnap_ts209_sata_data = { 327static struct mv_sata_platform_data qnap_ts209_sata_data = {
325 .n_ports = 2, 328 .n_ports = 2,
326}; 329};
327 330
328/***************************************************************************** 331/*****************************************************************************
@@ -339,7 +342,7 @@ static struct platform_device *qnap_ts209_devices[] __initdata = {
339 * QNAP TS-[12]09 specific power off method via UART1-attached PIC 342 * QNAP TS-[12]09 specific power off method via UART1-attached PIC
340 */ 343 */
341 344
342#define UART1_REG(x) (UART1_VIRT_BASE + ((UART_##x) << 2)) 345#define UART1_REG(x) (UART1_VIRT_BASE + ((UART_##x) << 2))
343 346
344static void qnap_ts209_power_off(void) 347static void qnap_ts209_power_off(void)
345{ 348{
@@ -372,7 +375,7 @@ static void __init qnap_ts209_init(void)
372 * Setup flash mapping 375 * Setup flash mapping
373 */ 376 */
374 orion5x_setup_dev_boot_win(QNAP_TS209_NOR_BOOT_BASE, 377 orion5x_setup_dev_boot_win(QNAP_TS209_NOR_BOOT_BASE,
375 QNAP_TS209_NOR_BOOT_SIZE); 378 QNAP_TS209_NOR_BOOT_SIZE);
376 379
377 /* 380 /*
378 * Open a special address decode windows for the PCIe WA. 381 * Open a special address decode windows for the PCIe WA.
@@ -432,7 +435,7 @@ static void __init qnap_ts209_init(void)
432} 435}
433 436
434MACHINE_START(TS209, "QNAP TS-109/TS-209") 437MACHINE_START(TS209, "QNAP TS-109/TS-209")
435 /* Maintainer: Byron Bradley <byron.bbradley@gmail.com> */ 438 /* Maintainer: Byron Bradley <byron.bbradley@gmail.com> */
436 .phys_io = ORION5X_REGS_PHYS_BASE, 439 .phys_io = ORION5X_REGS_PHYS_BASE,
437 .io_pg_offst = ((ORION5X_REGS_VIRT_BASE) >> 18) & 0xFFFC, 440 .io_pg_offst = ((ORION5X_REGS_VIRT_BASE) >> 18) & 0xFFFC,
438 .boot_params = 0x00000100, 441 .boot_params = 0x00000100,
diff --git a/arch/arm/mm/proc-feroceon.S b/arch/arm/mm/proc-feroceon.S
index a02c1712b52d..4bedbd838f8f 100644
--- a/arch/arm/mm/proc-feroceon.S
+++ b/arch/arm/mm/proc-feroceon.S
@@ -423,13 +423,13 @@ cpu_feroceon_name:
423__feroceon_old_id_proc_info: 423__feroceon_old_id_proc_info:
424 .long 0x41069260 424 .long 0x41069260
425 .long 0xfffffff0 425 .long 0xfffffff0
426 .long PMD_TYPE_SECT | \ 426 .long PMD_TYPE_SECT | \
427 PMD_SECT_BUFFERABLE | \ 427 PMD_SECT_BUFFERABLE | \
428 PMD_SECT_CACHEABLE | \ 428 PMD_SECT_CACHEABLE | \
429 PMD_BIT4 | \ 429 PMD_BIT4 | \
430 PMD_SECT_AP_WRITE | \ 430 PMD_SECT_AP_WRITE | \
431 PMD_SECT_AP_READ 431 PMD_SECT_AP_READ
432 .long PMD_TYPE_SECT | \ 432 .long PMD_TYPE_SECT | \
433 PMD_BIT4 | \ 433 PMD_BIT4 | \
434 PMD_SECT_AP_WRITE | \ 434 PMD_SECT_AP_WRITE | \
435 PMD_SECT_AP_READ 435 PMD_SECT_AP_READ
@@ -449,13 +449,13 @@ __feroceon_old_id_proc_info:
449__feroceon_proc_info: 449__feroceon_proc_info:
450 .long 0x56055310 450 .long 0x56055310
451 .long 0xfffffff0 451 .long 0xfffffff0
452 .long PMD_TYPE_SECT | \ 452 .long PMD_TYPE_SECT | \
453 PMD_SECT_BUFFERABLE | \ 453 PMD_SECT_BUFFERABLE | \
454 PMD_SECT_CACHEABLE | \ 454 PMD_SECT_CACHEABLE | \
455 PMD_BIT4 | \ 455 PMD_BIT4 | \
456 PMD_SECT_AP_WRITE | \ 456 PMD_SECT_AP_WRITE | \
457 PMD_SECT_AP_READ 457 PMD_SECT_AP_READ
458 .long PMD_TYPE_SECT | \ 458 .long PMD_TYPE_SECT | \
459 PMD_BIT4 | \ 459 PMD_BIT4 | \
460 PMD_SECT_AP_WRITE | \ 460 PMD_SECT_AP_WRITE | \
461 PMD_SECT_AP_READ 461 PMD_SECT_AP_READ