aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-ixp4xx/common.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/mach-ixp4xx/common.c')
-rw-r--r--arch/arm/mach-ixp4xx/common.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/arch/arm/mach-ixp4xx/common.c b/arch/arm/mach-ixp4xx/common.c
index 9f33cb21e7f3..6b393691d0e8 100644
--- a/arch/arm/mach-ixp4xx/common.c
+++ b/arch/arm/mach-ixp4xx/common.c
@@ -332,11 +332,27 @@ static struct platform_device *ixp46x_devices[] __initdata = {
332 &ixp46x_i2c_controller 332 &ixp46x_i2c_controller
333}; 333};
334 334
335unsigned long ixp4xx_exp_bus_size;
336
335void __init ixp4xx_sys_init(void) 337void __init ixp4xx_sys_init(void)
336{ 338{
339 ixp4xx_exp_bus_size = SZ_16M;
340
337 if (cpu_is_ixp46x()) { 341 if (cpu_is_ixp46x()) {
342 int region;
343
338 platform_add_devices(ixp46x_devices, 344 platform_add_devices(ixp46x_devices,
339 ARRAY_SIZE(ixp46x_devices)); 345 ARRAY_SIZE(ixp46x_devices));
346
347 for (region = 0; region < 7; region++) {
348 if((*(IXP4XX_EXP_REG(0x4 * region)) & 0x200)) {
349 ixp4xx_exp_bus_size = SZ_32M;
350 break;
351 }
352 }
340 } 353 }
354
355 printk("IXP4xx: Using %uMiB expansion bus window size\n",
356 ixp4xx_exp_bus_size >> 20);
341} 357}
342 358