aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-orion5x/common.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/mach-orion5x/common.c')
-rw-r--r--arch/arm/mach-orion5x/common.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/arch/arm/mach-orion5x/common.c b/arch/arm/mach-orion5x/common.c
index 1a1df24f419e..68cc3efae567 100644
--- a/arch/arm/mach-orion5x/common.c
+++ b/arch/arm/mach-orion5x/common.c
@@ -220,14 +220,17 @@ static struct platform_device orion5x_switch_device = {
220 220
221void __init orion5x_eth_switch_init(struct dsa_platform_data *d, int irq) 221void __init orion5x_eth_switch_init(struct dsa_platform_data *d, int irq)
222{ 222{
223 int i;
224
223 if (irq != NO_IRQ) { 225 if (irq != NO_IRQ) {
224 orion5x_switch_resources[0].start = irq; 226 orion5x_switch_resources[0].start = irq;
225 orion5x_switch_resources[0].end = irq; 227 orion5x_switch_resources[0].end = irq;
226 orion5x_switch_device.num_resources = 1; 228 orion5x_switch_device.num_resources = 1;
227 } 229 }
228 230
229 d->mii_bus = &orion5x_eth_shared.dev;
230 d->netdev = &orion5x_eth.dev; 231 d->netdev = &orion5x_eth.dev;
232 for (i = 0; i < d->nr_chips; i++)
233 d->chip[i].mii_bus = &orion5x_eth_shared.dev;
231 orion5x_switch_device.dev.platform_data = d; 234 orion5x_switch_device.dev.platform_data = d;
232 235
233 platform_device_register(&orion5x_switch_device); 236 platform_device_register(&orion5x_switch_device);