aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-orion5x
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/mach-orion5x')
-rw-r--r--arch/arm/mach-orion5x/common.c36
-rw-r--r--arch/arm/mach-orion5x/common.h17
-rw-r--r--arch/arm/mach-orion5x/d2net-setup.c6
-rw-r--r--arch/arm/mach-orion5x/db88f5281-setup.c24
-rw-r--r--arch/arm/mach-orion5x/dns323-setup.c6
-rw-r--r--arch/arm/mach-orion5x/edmini_v2-setup.c6
-rw-r--r--arch/arm/mach-orion5x/kurobox_pro-setup.c12
-rw-r--r--arch/arm/mach-orion5x/ls-chl-setup.c6
-rw-r--r--arch/arm/mach-orion5x/ls_hgl-setup.c6
-rw-r--r--arch/arm/mach-orion5x/lsmini-setup.c6
-rw-r--r--arch/arm/mach-orion5x/mss2-setup.c6
-rw-r--r--arch/arm/mach-orion5x/mv2120-setup.c6
-rw-r--r--arch/arm/mach-orion5x/net2big-setup.c6
-rw-r--r--arch/arm/mach-orion5x/pci.c9
-rw-r--r--arch/arm/mach-orion5x/rd88f5181l-fxo-setup.c6
-rw-r--r--arch/arm/mach-orion5x/rd88f5181l-ge-setup.c6
-rw-r--r--arch/arm/mach-orion5x/rd88f5182-setup.c13
-rw-r--r--arch/arm/mach-orion5x/terastation_pro2-setup.c6
-rw-r--r--arch/arm/mach-orion5x/ts209-setup.c6
-rw-r--r--arch/arm/mach-orion5x/ts409-setup.c6
-rw-r--r--arch/arm/mach-orion5x/wnr854t-setup.c6
-rw-r--r--arch/arm/mach-orion5x/wrt350n-v2-setup.c6
22 files changed, 137 insertions, 70 deletions
diff --git a/arch/arm/mach-orion5x/common.c b/arch/arm/mach-orion5x/common.c
index b41599f98a8e..91a5852b44f3 100644
--- a/arch/arm/mach-orion5x/common.c
+++ b/arch/arm/mach-orion5x/common.c
@@ -174,8 +174,10 @@ void __init orion5x_xor_init(void)
174 ****************************************************************************/ 174 ****************************************************************************/
175static void __init orion5x_crypto_init(void) 175static void __init orion5x_crypto_init(void)
176{ 176{
177 mvebu_mbus_add_window("sram", ORION5X_SRAM_PHYS_BASE, 177 mvebu_mbus_add_window_by_id(ORION_MBUS_SRAM_TARGET,
178 ORION5X_SRAM_SIZE); 178 ORION_MBUS_SRAM_ATTR,
179 ORION5X_SRAM_PHYS_BASE,
180 ORION5X_SRAM_SIZE);
179 orion_crypto_init(ORION5X_CRYPTO_PHYS_BASE, ORION5X_SRAM_PHYS_BASE, 181 orion_crypto_init(ORION5X_CRYPTO_PHYS_BASE, ORION5X_SRAM_PHYS_BASE,
180 SZ_8K, IRQ_ORION5X_CESA); 182 SZ_8K, IRQ_ORION5X_CESA);
181} 183}
@@ -222,22 +224,24 @@ void orion5x_setup_wins(void)
222 * The PCIe windows will no longer be statically allocated 224 * The PCIe windows will no longer be statically allocated
223 * here once Orion5x is migrated to the pci-mvebu driver. 225 * here once Orion5x is migrated to the pci-mvebu driver.
224 */ 226 */
225 mvebu_mbus_add_window_remap_flags("pcie0.0", ORION5X_PCIE_IO_PHYS_BASE, 227 mvebu_mbus_add_window_remap_by_id(ORION_MBUS_PCIE_IO_TARGET,
228 ORION_MBUS_PCIE_IO_ATTR,
229 ORION5X_PCIE_IO_PHYS_BASE,
226 ORION5X_PCIE_IO_SIZE, 230 ORION5X_PCIE_IO_SIZE,
227 ORION5X_PCIE_IO_BUS_BASE, 231 ORION5X_PCIE_IO_BUS_BASE);
228 MVEBU_MBUS_PCI_IO); 232 mvebu_mbus_add_window_by_id(ORION_MBUS_PCIE_MEM_TARGET,
229 mvebu_mbus_add_window_remap_flags("pcie0.0", ORION5X_PCIE_MEM_PHYS_BASE, 233 ORION_MBUS_PCIE_MEM_ATTR,
230 ORION5X_PCIE_MEM_SIZE, 234 ORION5X_PCIE_MEM_PHYS_BASE,
231 MVEBU_MBUS_NO_REMAP, 235 ORION5X_PCIE_MEM_SIZE);
232 MVEBU_MBUS_PCI_MEM); 236 mvebu_mbus_add_window_remap_by_id(ORION_MBUS_PCI_IO_TARGET,
233 mvebu_mbus_add_window_remap_flags("pci0.0", ORION5X_PCI_IO_PHYS_BASE, 237 ORION_MBUS_PCI_IO_ATTR,
238 ORION5X_PCI_IO_PHYS_BASE,
234 ORION5X_PCI_IO_SIZE, 239 ORION5X_PCI_IO_SIZE,
235 ORION5X_PCI_IO_BUS_BASE, 240 ORION5X_PCI_IO_BUS_BASE);
236 MVEBU_MBUS_PCI_IO); 241 mvebu_mbus_add_window_by_id(ORION_MBUS_PCI_MEM_TARGET,
237 mvebu_mbus_add_window_remap_flags("pci0.0", ORION5X_PCI_MEM_PHYS_BASE, 242 ORION_MBUS_PCI_MEM_ATTR,
238 ORION5X_PCI_MEM_SIZE, 243 ORION5X_PCI_MEM_PHYS_BASE,
239 MVEBU_MBUS_NO_REMAP, 244 ORION5X_PCI_MEM_SIZE);
240 MVEBU_MBUS_PCI_MEM);
241} 245}
242 246
243int orion5x_tclk; 247int orion5x_tclk;
diff --git a/arch/arm/mach-orion5x/common.h b/arch/arm/mach-orion5x/common.h
index a909afb384fb..f565f9944af2 100644
--- a/arch/arm/mach-orion5x/common.h
+++ b/arch/arm/mach-orion5x/common.h
@@ -7,6 +7,23 @@ struct dsa_platform_data;
7struct mv643xx_eth_platform_data; 7struct mv643xx_eth_platform_data;
8struct mv_sata_platform_data; 8struct mv_sata_platform_data;
9 9
10#define ORION_MBUS_PCIE_MEM_TARGET 0x04
11#define ORION_MBUS_PCIE_MEM_ATTR 0x59
12#define ORION_MBUS_PCIE_IO_TARGET 0x04
13#define ORION_MBUS_PCIE_IO_ATTR 0x51
14#define ORION_MBUS_PCIE_WA_TARGET 0x04
15#define ORION_MBUS_PCIE_WA_ATTR 0x79
16#define ORION_MBUS_PCI_MEM_TARGET 0x03
17#define ORION_MBUS_PCI_MEM_ATTR 0x59
18#define ORION_MBUS_PCI_IO_TARGET 0x03
19#define ORION_MBUS_PCI_IO_ATTR 0x51
20#define ORION_MBUS_DEVBUS_BOOT_TARGET 0x01
21#define ORION_MBUS_DEVBUS_BOOT_ATTR 0x0f
22#define ORION_MBUS_DEVBUS_TARGET(cs) 0x01
23#define ORION_MBUS_DEVBUS_ATTR(cs) (~(1 << cs))
24#define ORION_MBUS_SRAM_TARGET 0x00
25#define ORION_MBUS_SRAM_ATTR 0x00
26
10/* 27/*
11 * Basic Orion init functions used early by machine-setup. 28 * Basic Orion init functions used early by machine-setup.
12 */ 29 */
diff --git a/arch/arm/mach-orion5x/d2net-setup.c b/arch/arm/mach-orion5x/d2net-setup.c
index 16c88bbabc98..8f68b745c1d5 100644
--- a/arch/arm/mach-orion5x/d2net-setup.c
+++ b/arch/arm/mach-orion5x/d2net-setup.c
@@ -317,8 +317,10 @@ static void __init d2net_init(void)
317 d2net_sata_power_init(); 317 d2net_sata_power_init();
318 orion5x_sata_init(&d2net_sata_data); 318 orion5x_sata_init(&d2net_sata_data);
319 319
320 mvebu_mbus_add_window("devbus-boot", D2NET_NOR_BOOT_BASE, 320 mvebu_mbus_add_window_by_id(ORION_MBUS_DEVBUS_BOOT_TARGET,
321 D2NET_NOR_BOOT_SIZE); 321 ORION_MBUS_DEVBUS_BOOT_ATTR,
322 D2NET_NOR_BOOT_BASE,
323 D2NET_NOR_BOOT_SIZE);
322 platform_device_register(&d2net_nor_flash); 324 platform_device_register(&d2net_nor_flash);
323 325
324 platform_device_register(&d2net_gpio_buttons); 326 platform_device_register(&d2net_gpio_buttons);
diff --git a/arch/arm/mach-orion5x/db88f5281-setup.c b/arch/arm/mach-orion5x/db88f5281-setup.c
index 4e1263da38bb..4b2aefd1d961 100644
--- a/arch/arm/mach-orion5x/db88f5281-setup.c
+++ b/arch/arm/mach-orion5x/db88f5281-setup.c
@@ -340,19 +340,27 @@ static void __init db88f5281_init(void)
340 orion5x_uart0_init(); 340 orion5x_uart0_init();
341 orion5x_uart1_init(); 341 orion5x_uart1_init();
342 342
343 mvebu_mbus_add_window("devbus-boot", DB88F5281_NOR_BOOT_BASE, 343 mvebu_mbus_add_window_by_id(ORION_MBUS_DEVBUS_BOOT_TARGET,
344 DB88F5281_NOR_BOOT_SIZE); 344 ORION_MBUS_DEVBUS_BOOT_ATTR,
345 DB88F5281_NOR_BOOT_BASE,
346 DB88F5281_NOR_BOOT_SIZE);
345 platform_device_register(&db88f5281_boot_flash); 347 platform_device_register(&db88f5281_boot_flash);
346 348
347 mvebu_mbus_add_window("devbus-cs0", DB88F5281_7SEG_BASE, 349 mvebu_mbus_add_window_by_id(ORION_MBUS_DEVBUS_TARGET(0),
348 DB88F5281_7SEG_SIZE); 350 ORION_MBUS_DEVBUS_ATTR(0),
351 DB88F5281_7SEG_BASE,
352 DB88F5281_7SEG_SIZE);
349 353
350 mvebu_mbus_add_window("devbus-cs1", DB88F5281_NOR_BASE, 354 mvebu_mbus_add_window_by_id(ORION_MBUS_DEVBUS_TARGET(1),
351 DB88F5281_NOR_SIZE); 355 ORION_MBUS_DEVBUS_ATTR(1),
356 DB88F5281_NOR_BASE,
357 DB88F5281_NOR_SIZE);
352 platform_device_register(&db88f5281_nor_flash); 358 platform_device_register(&db88f5281_nor_flash);
353 359
354 mvebu_mbus_add_window("devbus-cs2", DB88F5281_NAND_BASE, 360 mvebu_mbus_add_window_by_id(ORION_MBUS_DEVBUS_TARGET(2),
355 DB88F5281_NAND_SIZE); 361 ORION_MBUS_DEVBUS_ATTR(2),
362 DB88F5281_NAND_BASE,
363 DB88F5281_NAND_SIZE);
356 platform_device_register(&db88f5281_nand_flash); 364 platform_device_register(&db88f5281_nand_flash);
357 365
358 i2c_register_board_info(0, &db88f5281_i2c_rtc, 1); 366 i2c_register_board_info(0, &db88f5281_i2c_rtc, 1);
diff --git a/arch/arm/mach-orion5x/dns323-setup.c b/arch/arm/mach-orion5x/dns323-setup.c
index 9e6baf581ed3..70974732cbf0 100644
--- a/arch/arm/mach-orion5x/dns323-setup.c
+++ b/arch/arm/mach-orion5x/dns323-setup.c
@@ -611,8 +611,10 @@ static void __init dns323_init(void)
611 /* setup flash mapping 611 /* setup flash mapping
612 * CS3 holds a 8 MB Spansion S29GL064M90TFIR4 612 * CS3 holds a 8 MB Spansion S29GL064M90TFIR4
613 */ 613 */
614 mvebu_mbus_add_window("devbus-boot", DNS323_NOR_BOOT_BASE, 614 mvebu_mbus_add_window_by_id(ORION_MBUS_DEVBUS_BOOT_TARGET,
615 DNS323_NOR_BOOT_SIZE); 615 ORION_MBUS_DEVBUS_BOOT_ATTR,
616 DNS323_NOR_BOOT_BASE,
617 DNS323_NOR_BOOT_SIZE);
616 platform_device_register(&dns323_nor_flash); 618 platform_device_register(&dns323_nor_flash);
617 619
618 /* Sort out LEDs, Buttons and i2c devices */ 620 /* Sort out LEDs, Buttons and i2c devices */
diff --git a/arch/arm/mach-orion5x/edmini_v2-setup.c b/arch/arm/mach-orion5x/edmini_v2-setup.c
index 147615510dd0..0fc33c56cbb7 100644
--- a/arch/arm/mach-orion5x/edmini_v2-setup.c
+++ b/arch/arm/mach-orion5x/edmini_v2-setup.c
@@ -154,8 +154,10 @@ void __init edmini_v2_init(void)
154 orion5x_ehci0_init(); 154 orion5x_ehci0_init();
155 orion5x_eth_init(&edmini_v2_eth_data); 155 orion5x_eth_init(&edmini_v2_eth_data);
156 156
157 mvebu_mbus_add_window("devbus-boot", EDMINI_V2_NOR_BOOT_BASE, 157 mvebu_mbus_add_window_by_id(ORION_MBUS_DEVBUS_BOOT_TARGET,
158 EDMINI_V2_NOR_BOOT_SIZE); 158 ORION_MBUS_DEVBUS_BOOT_ATTR,
159 EDMINI_V2_NOR_BOOT_BASE,
160 EDMINI_V2_NOR_BOOT_SIZE);
159 platform_device_register(&edmini_v2_nor_flash); 161 platform_device_register(&edmini_v2_nor_flash);
160 162
161 pr_notice("edmini_v2: USB device port, flash write and power-off " 163 pr_notice("edmini_v2: USB device port, flash write and power-off "
diff --git a/arch/arm/mach-orion5x/kurobox_pro-setup.c b/arch/arm/mach-orion5x/kurobox_pro-setup.c
index aae10e4a917c..fe6a48a325e8 100644
--- a/arch/arm/mach-orion5x/kurobox_pro-setup.c
+++ b/arch/arm/mach-orion5x/kurobox_pro-setup.c
@@ -359,13 +359,17 @@ static void __init kurobox_pro_init(void)
359 orion5x_uart1_init(); 359 orion5x_uart1_init();
360 orion5x_xor_init(); 360 orion5x_xor_init();
361 361
362 mvebu_mbus_add_window("devbus-boot", KUROBOX_PRO_NOR_BOOT_BASE, 362 mvebu_mbus_add_window_by_id(ORION_MBUS_DEVBUS_BOOT_TARGET,
363 KUROBOX_PRO_NOR_BOOT_SIZE); 363 ORION_MBUS_DEVBUS_BOOT_ATTR,
364 KUROBOX_PRO_NOR_BOOT_BASE,
365 KUROBOX_PRO_NOR_BOOT_SIZE);
364 platform_device_register(&kurobox_pro_nor_flash); 366 platform_device_register(&kurobox_pro_nor_flash);
365 367
366 if (machine_is_kurobox_pro()) { 368 if (machine_is_kurobox_pro()) {
367 mvebu_mbus_add_window("devbus-cs0", KUROBOX_PRO_NAND_BASE, 369 mvebu_mbus_add_window_by_id(ORION_MBUS_DEVBUS_TARGET(0),
368 KUROBOX_PRO_NAND_SIZE); 370 ORION_MBUS_DEVBUS_ATTR(0),
371 KUROBOX_PRO_NAND_BASE,
372 KUROBOX_PRO_NAND_SIZE);
369 platform_device_register(&kurobox_pro_nand_flash); 373 platform_device_register(&kurobox_pro_nand_flash);
370 } 374 }
371 375
diff --git a/arch/arm/mach-orion5x/ls-chl-setup.c b/arch/arm/mach-orion5x/ls-chl-setup.c
index 6234977b5aea..028ea038d404 100644
--- a/arch/arm/mach-orion5x/ls-chl-setup.c
+++ b/arch/arm/mach-orion5x/ls-chl-setup.c
@@ -294,8 +294,10 @@ static void __init lschl_init(void)
294 orion5x_uart0_init(); 294 orion5x_uart0_init();
295 orion5x_xor_init(); 295 orion5x_xor_init();
296 296
297 mvebu_mbus_add_window("devbus-boot", LSCHL_NOR_BOOT_BASE, 297 mvebu_mbus_add_window_by_id(ORION_MBUS_DEVBUS_BOOT_TARGET,
298 LSCHL_NOR_BOOT_SIZE); 298 ORION_MBUS_DEVBUS_BOOT_ATTR,
299 LSCHL_NOR_BOOT_BASE,
300 LSCHL_NOR_BOOT_SIZE);
299 platform_device_register(&lschl_nor_flash); 301 platform_device_register(&lschl_nor_flash);
300 302
301 platform_device_register(&lschl_leds); 303 platform_device_register(&lschl_leds);
diff --git a/arch/arm/mach-orion5x/ls_hgl-setup.c b/arch/arm/mach-orion5x/ls_hgl-setup.c
index fe04c4b64569..32b7129b767d 100644
--- a/arch/arm/mach-orion5x/ls_hgl-setup.c
+++ b/arch/arm/mach-orion5x/ls_hgl-setup.c
@@ -243,8 +243,10 @@ static void __init ls_hgl_init(void)
243 orion5x_uart0_init(); 243 orion5x_uart0_init();
244 orion5x_xor_init(); 244 orion5x_xor_init();
245 245
246 mvebu_mbus_add_window("devbus-boot", LS_HGL_NOR_BOOT_BASE, 246 mvebu_mbus_add_window_by_id(ORION_MBUS_DEVBUS_BOOT_TARGET,
247 LS_HGL_NOR_BOOT_SIZE); 247 ORION_MBUS_DEVBUS_BOOT_ATTR,
248 LS_HGL_NOR_BOOT_BASE,
249 LS_HGL_NOR_BOOT_SIZE);
248 platform_device_register(&ls_hgl_nor_flash); 250 platform_device_register(&ls_hgl_nor_flash);
249 251
250 platform_device_register(&ls_hgl_button_device); 252 platform_device_register(&ls_hgl_button_device);
diff --git a/arch/arm/mach-orion5x/lsmini-setup.c b/arch/arm/mach-orion5x/lsmini-setup.c
index ca4dbe973daf..a6493e76f96d 100644
--- a/arch/arm/mach-orion5x/lsmini-setup.c
+++ b/arch/arm/mach-orion5x/lsmini-setup.c
@@ -244,8 +244,10 @@ static void __init lsmini_init(void)
244 orion5x_uart0_init(); 244 orion5x_uart0_init();
245 orion5x_xor_init(); 245 orion5x_xor_init();
246 246
247 mvebu_mbus_add_window("devbus-boot", LSMINI_NOR_BOOT_BASE, 247 mvebu_mbus_add_window_by_id(ORION_MBUS_DEVBUS_BOOT_TARGET,
248 LSMINI_NOR_BOOT_SIZE); 248 ORION_MBUS_DEVBUS_BOOT_ATTR,
249 LSMINI_NOR_BOOT_BASE,
250 LSMINI_NOR_BOOT_SIZE);
249 platform_device_register(&lsmini_nor_flash); 251 platform_device_register(&lsmini_nor_flash);
250 252
251 platform_device_register(&lsmini_button_device); 253 platform_device_register(&lsmini_button_device);
diff --git a/arch/arm/mach-orion5x/mss2-setup.c b/arch/arm/mach-orion5x/mss2-setup.c
index 827acbafc9dc..e105130ba51c 100644
--- a/arch/arm/mach-orion5x/mss2-setup.c
+++ b/arch/arm/mach-orion5x/mss2-setup.c
@@ -241,8 +241,10 @@ static void __init mss2_init(void)
241 orion5x_uart0_init(); 241 orion5x_uart0_init();
242 orion5x_xor_init(); 242 orion5x_xor_init();
243 243
244 mvebu_mbus_add_window("devbus-boot", MSS2_NOR_BOOT_BASE, 244 mvebu_mbus_add_window_by_id(ORION_MBUS_DEVBUS_BOOT_TARGET,
245 MSS2_NOR_BOOT_SIZE); 245 ORION_MBUS_DEVBUS_BOOT_ATTR,
246 MSS2_NOR_BOOT_BASE,
247 MSS2_NOR_BOOT_SIZE);
246 platform_device_register(&mss2_nor_flash); 248 platform_device_register(&mss2_nor_flash);
247 249
248 platform_device_register(&mss2_button_device); 250 platform_device_register(&mss2_button_device);
diff --git a/arch/arm/mach-orion5x/mv2120-setup.c b/arch/arm/mach-orion5x/mv2120-setup.c
index 92600ae2b4b6..e032f01da49e 100644
--- a/arch/arm/mach-orion5x/mv2120-setup.c
+++ b/arch/arm/mach-orion5x/mv2120-setup.c
@@ -204,8 +204,10 @@ static void __init mv2120_init(void)
204 orion5x_uart0_init(); 204 orion5x_uart0_init();
205 orion5x_xor_init(); 205 orion5x_xor_init();
206 206
207 mvebu_mbus_add_window("devbus-boot", MV2120_NOR_BOOT_BASE, 207 mvebu_mbus_add_window_by_id(ORION_MBUS_DEVBUS_BOOT_TARGET,
208 MV2120_NOR_BOOT_SIZE); 208 ORION_MBUS_DEVBUS_BOOT_ATTR,
209 MV2120_NOR_BOOT_BASE,
210 MV2120_NOR_BOOT_SIZE);
209 platform_device_register(&mv2120_nor_flash); 211 platform_device_register(&mv2120_nor_flash);
210 212
211 platform_device_register(&mv2120_button_device); 213 platform_device_register(&mv2120_button_device);
diff --git a/arch/arm/mach-orion5x/net2big-setup.c b/arch/arm/mach-orion5x/net2big-setup.c
index dd0641a0d074..ba73dc7ffb9e 100644
--- a/arch/arm/mach-orion5x/net2big-setup.c
+++ b/arch/arm/mach-orion5x/net2big-setup.c
@@ -397,8 +397,10 @@ static void __init net2big_init(void)
397 net2big_sata_power_init(); 397 net2big_sata_power_init();
398 orion5x_sata_init(&net2big_sata_data); 398 orion5x_sata_init(&net2big_sata_data);
399 399
400 mvebu_mbus_add_window("devbus-boot", NET2BIG_NOR_BOOT_BASE, 400 mvebu_mbus_add_window_by_id(ORION_MBUS_DEVBUS_BOOT_TARGET,
401 NET2BIG_NOR_BOOT_SIZE); 401 ORION_MBUS_DEVBUS_BOOT_ATTR,
402 NET2BIG_NOR_BOOT_BASE,
403 NET2BIG_NOR_BOOT_SIZE);
402 platform_device_register(&net2big_nor_flash); 404 platform_device_register(&net2big_nor_flash);
403 405
404 platform_device_register(&net2big_gpio_buttons); 406 platform_device_register(&net2big_gpio_buttons);
diff --git a/arch/arm/mach-orion5x/pci.c b/arch/arm/mach-orion5x/pci.c
index 503368023bb1..7fab67053030 100644
--- a/arch/arm/mach-orion5x/pci.c
+++ b/arch/arm/mach-orion5x/pci.c
@@ -157,11 +157,10 @@ static int __init pcie_setup(struct pci_sys_data *sys)
157 if (dev == MV88F5181_DEV_ID || dev == MV88F5182_DEV_ID) { 157 if (dev == MV88F5181_DEV_ID || dev == MV88F5182_DEV_ID) {
158 printk(KERN_NOTICE "Applying Orion-1/Orion-NAS PCIe config " 158 printk(KERN_NOTICE "Applying Orion-1/Orion-NAS PCIe config "
159 "read transaction workaround\n"); 159 "read transaction workaround\n");
160 mvebu_mbus_add_window_remap_flags("pcie0.0", 160 mvebu_mbus_add_window_by_id(ORION_MBUS_PCIE_WA_TARGET,
161 ORION5X_PCIE_WA_PHYS_BASE, 161 ORION_MBUS_PCIE_WA_ATTR,
162 ORION5X_PCIE_WA_SIZE, 162 ORION5X_PCIE_WA_PHYS_BASE,
163 MVEBU_MBUS_NO_REMAP, 163 ORION5X_PCIE_WA_SIZE);
164 MVEBU_MBUS_PCI_WA);
165 pcie_ops.read = pcie_rd_conf_wa; 164 pcie_ops.read = pcie_rd_conf_wa;
166 } 165 }
167 166
diff --git a/arch/arm/mach-orion5x/rd88f5181l-fxo-setup.c b/arch/arm/mach-orion5x/rd88f5181l-fxo-setup.c
index 1c4498bf650a..213b3e143c57 100644
--- a/arch/arm/mach-orion5x/rd88f5181l-fxo-setup.c
+++ b/arch/arm/mach-orion5x/rd88f5181l-fxo-setup.c
@@ -123,8 +123,10 @@ static void __init rd88f5181l_fxo_init(void)
123 orion5x_eth_switch_init(&rd88f5181l_fxo_switch_plat_data, NO_IRQ); 123 orion5x_eth_switch_init(&rd88f5181l_fxo_switch_plat_data, NO_IRQ);
124 orion5x_uart0_init(); 124 orion5x_uart0_init();
125 125
126 mvebu_mbus_add_window("devbus-boot", RD88F5181L_FXO_NOR_BOOT_BASE, 126 mvebu_mbus_add_window_by_id(ORION_MBUS_DEVBUS_BOOT_TARGET,
127 RD88F5181L_FXO_NOR_BOOT_SIZE); 127 ORION_MBUS_DEVBUS_BOOT_ATTR,
128 RD88F5181L_FXO_NOR_BOOT_BASE,
129 RD88F5181L_FXO_NOR_BOOT_SIZE);
128 platform_device_register(&rd88f5181l_fxo_nor_boot_flash); 130 platform_device_register(&rd88f5181l_fxo_nor_boot_flash);
129} 131}
130 132
diff --git a/arch/arm/mach-orion5x/rd88f5181l-ge-setup.c b/arch/arm/mach-orion5x/rd88f5181l-ge-setup.c
index adabe34c4fc6..594800e1d691 100644
--- a/arch/arm/mach-orion5x/rd88f5181l-ge-setup.c
+++ b/arch/arm/mach-orion5x/rd88f5181l-ge-setup.c
@@ -130,8 +130,10 @@ static void __init rd88f5181l_ge_init(void)
130 orion5x_i2c_init(); 130 orion5x_i2c_init();
131 orion5x_uart0_init(); 131 orion5x_uart0_init();
132 132
133 mvebu_mbus_add_window("devbus-boot", RD88F5181L_GE_NOR_BOOT_BASE, 133 mvebu_mbus_add_window_by_id(ORION_MBUS_DEVBUS_BOOT_TARGET,
134 RD88F5181L_GE_NOR_BOOT_SIZE); 134 ORION_MBUS_DEVBUS_BOOT_ATTR,
135 RD88F5181L_GE_NOR_BOOT_BASE,
136 RD88F5181L_GE_NOR_BOOT_SIZE);
135 platform_device_register(&rd88f5181l_ge_nor_boot_flash); 137 platform_device_register(&rd88f5181l_ge_nor_boot_flash);
136 138
137 i2c_register_board_info(0, &rd88f5181l_ge_i2c_rtc, 1); 139 i2c_register_board_info(0, &rd88f5181l_ge_i2c_rtc, 1);
diff --git a/arch/arm/mach-orion5x/rd88f5182-setup.c b/arch/arm/mach-orion5x/rd88f5182-setup.c
index 66e77ec91532..b1cf68493ffc 100644
--- a/arch/arm/mach-orion5x/rd88f5182-setup.c
+++ b/arch/arm/mach-orion5x/rd88f5182-setup.c
@@ -264,11 +264,14 @@ static void __init rd88f5182_init(void)
264 orion5x_uart0_init(); 264 orion5x_uart0_init();
265 orion5x_xor_init(); 265 orion5x_xor_init();
266 266
267 mvebu_mbus_add_window("devbus-boot", RD88F5182_NOR_BOOT_BASE, 267 mvebu_mbus_add_window_by_id(ORION_MBUS_DEVBUS_BOOT_TARGET,
268 RD88F5182_NOR_BOOT_SIZE); 268 ORION_MBUS_DEVBUS_BOOT_ATTR,
269 269 RD88F5182_NOR_BOOT_BASE,
270 mvebu_mbus_add_window("devbus-cs1", RD88F5182_NOR_BASE, 270 RD88F5182_NOR_BOOT_SIZE);
271 RD88F5182_NOR_SIZE); 271 mvebu_mbus_add_window_by_id(ORION_MBUS_DEVBUS_TARGET(1),
272 ORION_MBUS_DEVBUS_ATTR(1),
273 RD88F5182_NOR_BASE,
274 RD88F5182_NOR_SIZE);
272 platform_device_register(&rd88f5182_nor_flash); 275 platform_device_register(&rd88f5182_nor_flash);
273 platform_device_register(&rd88f5182_gpio_leds); 276 platform_device_register(&rd88f5182_gpio_leds);
274 277
diff --git a/arch/arm/mach-orion5x/terastation_pro2-setup.c b/arch/arm/mach-orion5x/terastation_pro2-setup.c
index a0bfa53e7556..7e9064844698 100644
--- a/arch/arm/mach-orion5x/terastation_pro2-setup.c
+++ b/arch/arm/mach-orion5x/terastation_pro2-setup.c
@@ -329,8 +329,10 @@ static void __init tsp2_init(void)
329 /* 329 /*
330 * Configure peripherals. 330 * Configure peripherals.
331 */ 331 */
332 mvebu_mbus_add_window("devbus-boot", TSP2_NOR_BOOT_BASE, 332 mvebu_mbus_add_window_by_id(ORION_MBUS_DEVBUS_BOOT_TARGET,
333 TSP2_NOR_BOOT_SIZE); 333 ORION_MBUS_DEVBUS_BOOT_ATTR,
334 TSP2_NOR_BOOT_BASE,
335 TSP2_NOR_BOOT_SIZE);
334 platform_device_register(&tsp2_nor_flash); 336 platform_device_register(&tsp2_nor_flash);
335 337
336 orion5x_ehci0_init(); 338 orion5x_ehci0_init();
diff --git a/arch/arm/mach-orion5x/ts209-setup.c b/arch/arm/mach-orion5x/ts209-setup.c
index 80174f0f168e..e90c0618fdad 100644
--- a/arch/arm/mach-orion5x/ts209-setup.c
+++ b/arch/arm/mach-orion5x/ts209-setup.c
@@ -286,8 +286,10 @@ static void __init qnap_ts209_init(void)
286 /* 286 /*
287 * Configure peripherals. 287 * Configure peripherals.
288 */ 288 */
289 mvebu_mbus_add_window("devbus-boot", QNAP_TS209_NOR_BOOT_BASE, 289 mvebu_mbus_add_window_by_id(ORION_MBUS_DEVBUS_BOOT_TARGET,
290 QNAP_TS209_NOR_BOOT_SIZE); 290 ORION_MBUS_DEVBUS_BOOT_ATTR,
291 QNAP_TS209_NOR_BOOT_BASE,
292 QNAP_TS209_NOR_BOOT_SIZE);
291 platform_device_register(&qnap_ts209_nor_flash); 293 platform_device_register(&qnap_ts209_nor_flash);
292 294
293 orion5x_ehci0_init(); 295 orion5x_ehci0_init();
diff --git a/arch/arm/mach-orion5x/ts409-setup.c b/arch/arm/mach-orion5x/ts409-setup.c
index 92592790d6da..5c079d312015 100644
--- a/arch/arm/mach-orion5x/ts409-setup.c
+++ b/arch/arm/mach-orion5x/ts409-setup.c
@@ -277,8 +277,10 @@ static void __init qnap_ts409_init(void)
277 /* 277 /*
278 * Configure peripherals. 278 * Configure peripherals.
279 */ 279 */
280 mvebu_mbus_add_window("devbus-boot", QNAP_TS409_NOR_BOOT_BASE, 280 mvebu_mbus_add_window_by_id(ORION_MBUS_DEVBUS_BOOT_TARGET,
281 QNAP_TS409_NOR_BOOT_SIZE); 281 ORION_MBUS_DEVBUS_BOOT_ATTR,
282 QNAP_TS409_NOR_BOOT_BASE,
283 QNAP_TS409_NOR_BOOT_SIZE);
282 platform_device_register(&qnap_ts409_nor_flash); 284 platform_device_register(&qnap_ts409_nor_flash);
283 285
284 orion5x_ehci0_init(); 286 orion5x_ehci0_init();
diff --git a/arch/arm/mach-orion5x/wnr854t-setup.c b/arch/arm/mach-orion5x/wnr854t-setup.c
index 6b84863c018d..80a56ee245b3 100644
--- a/arch/arm/mach-orion5x/wnr854t-setup.c
+++ b/arch/arm/mach-orion5x/wnr854t-setup.c
@@ -127,8 +127,10 @@ static void __init wnr854t_init(void)
127 orion5x_eth_switch_init(&wnr854t_switch_plat_data, NO_IRQ); 127 orion5x_eth_switch_init(&wnr854t_switch_plat_data, NO_IRQ);
128 orion5x_uart0_init(); 128 orion5x_uart0_init();
129 129
130 mvebu_mbus_add_window("devbus-boot", WNR854T_NOR_BOOT_BASE, 130 mvebu_mbus_add_window_by_id(ORION_MBUS_DEVBUS_BOOT_TARGET,
131 WNR854T_NOR_BOOT_SIZE); 131 ORION_MBUS_DEVBUS_BOOT_ATTR,
132 WNR854T_NOR_BOOT_BASE,
133 WNR854T_NOR_BOOT_SIZE);
132 platform_device_register(&wnr854t_nor_flash); 134 platform_device_register(&wnr854t_nor_flash);
133} 135}
134 136
diff --git a/arch/arm/mach-orion5x/wrt350n-v2-setup.c b/arch/arm/mach-orion5x/wrt350n-v2-setup.c
index fae684bc54f2..670e30dc0d1b 100644
--- a/arch/arm/mach-orion5x/wrt350n-v2-setup.c
+++ b/arch/arm/mach-orion5x/wrt350n-v2-setup.c
@@ -213,8 +213,10 @@ static void __init wrt350n_v2_init(void)
213 orion5x_eth_switch_init(&wrt350n_v2_switch_plat_data, NO_IRQ); 213 orion5x_eth_switch_init(&wrt350n_v2_switch_plat_data, NO_IRQ);
214 orion5x_uart0_init(); 214 orion5x_uart0_init();
215 215
216 mvebu_mbus_add_window("devbus-boot", WRT350N_V2_NOR_BOOT_BASE, 216 mvebu_mbus_add_window_by_id(ORION_MBUS_DEVBUS_BOOT_TARGET,
217 WRT350N_V2_NOR_BOOT_SIZE); 217 ORION_MBUS_DEVBUS_BOOT_ATTR,
218 WRT350N_V2_NOR_BOOT_BASE,
219 WRT350N_V2_NOR_BOOT_SIZE);
218 platform_device_register(&wrt350n_v2_nor_flash); 220 platform_device_register(&wrt350n_v2_nor_flash);
219 platform_device_register(&wrt350n_v2_leds); 221 platform_device_register(&wrt350n_v2_leds);
220 platform_device_register(&wrt350n_v2_button_device); 222 platform_device_register(&wrt350n_v2_button_device);