diff options
author | Max Filippov <jcmvbkbc@gmail.com> | 2013-11-10 07:05:46 -0500 |
---|---|---|
committer | Chris Zankel <chris@zankel.net> | 2014-01-14 13:19:49 -0500 |
commit | 358b181003dbb30985331a77e753e1b05c05d87d (patch) | |
tree | 5fb9a3e49561b4ed3f7b1f3f948ff522bcf0ce08 /arch/xtensa | |
parent | 8c8ad85f1f3ee1c2096a6b7b0892cabe4a956e31 (diff) |
xtensa: ISS: init network interface name before the probe
Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
Signed-off-by: Chris Zankel <chris@zankel.net>
Diffstat (limited to 'arch/xtensa')
-rw-r--r-- | arch/xtensa/platforms/iss/network.c | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/arch/xtensa/platforms/iss/network.c b/arch/xtensa/platforms/iss/network.c index 0c7c1d4141db..3718cff3909a 100644 --- a/arch/xtensa/platforms/iss/network.c +++ b/arch/xtensa/platforms/iss/network.c | |||
@@ -545,6 +545,13 @@ static int iss_net_configure(int index, char *init) | |||
545 | }; | 545 | }; |
546 | 546 | ||
547 | /* | 547 | /* |
548 | * If this name ends up conflicting with an existing registered | ||
549 | * netdevice, that is OK, register_netdev{,ice}() will notice this | ||
550 | * and fail. | ||
551 | */ | ||
552 | snprintf(dev->name, sizeof(dev->name), "eth%d", index); | ||
553 | |||
554 | /* | ||
548 | * Try all transport protocols. | 555 | * Try all transport protocols. |
549 | * Note: more protocols can be added by adding '&& !X_init(lp, eth)'. | 556 | * Note: more protocols can be added by adding '&& !X_init(lp, eth)'. |
550 | */ | 557 | */ |
@@ -575,13 +582,6 @@ static int iss_net_configure(int index, char *init) | |||
575 | platform_device_register(&lp->pdev); | 582 | platform_device_register(&lp->pdev); |
576 | SET_NETDEV_DEV(dev, &lp->pdev.dev); | 583 | SET_NETDEV_DEV(dev, &lp->pdev.dev); |
577 | 584 | ||
578 | /* | ||
579 | * If this name ends up conflicting with an existing registered | ||
580 | * netdevice, that is OK, register_netdev{,ice}() will notice this | ||
581 | * and fail. | ||
582 | */ | ||
583 | snprintf(dev->name, sizeof(dev->name), "eth%d", index); | ||
584 | |||
585 | dev->netdev_ops = &iss_netdev_ops; | 585 | dev->netdev_ops = &iss_netdev_ops; |
586 | dev->mtu = lp->mtu; | 586 | dev->mtu = lp->mtu; |
587 | dev->watchdog_timeo = (HZ >> 1); | 587 | dev->watchdog_timeo = (HZ >> 1); |