diff options
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/net/ixgbe/ixgbe_main.c | 8 | ||||
-rw-r--r-- | drivers/net/ixgbe/ixgbe_phy.c | 3 |
2 files changed, 9 insertions, 2 deletions
diff --git a/drivers/net/ixgbe/ixgbe_main.c b/drivers/net/ixgbe/ixgbe_main.c index 5588ef493a3d..aaf482c0d520 100644 --- a/drivers/net/ixgbe/ixgbe_main.c +++ b/drivers/net/ixgbe/ixgbe_main.c | |||
@@ -3724,7 +3724,7 @@ static void ixgbe_sfp_task(struct work_struct *work) | |||
3724 | if ((hw->phy.type == ixgbe_phy_nl) && | 3724 | if ((hw->phy.type == ixgbe_phy_nl) && |
3725 | (hw->phy.sfp_type == ixgbe_sfp_type_not_present)) { | 3725 | (hw->phy.sfp_type == ixgbe_sfp_type_not_present)) { |
3726 | s32 ret = hw->phy.ops.identify_sfp(hw); | 3726 | s32 ret = hw->phy.ops.identify_sfp(hw); |
3727 | if (ret) | 3727 | if (ret == IXGBE_ERR_SFP_NOT_PRESENT) |
3728 | goto reschedule; | 3728 | goto reschedule; |
3729 | ret = hw->phy.ops.reset(hw); | 3729 | ret = hw->phy.ops.reset(hw); |
3730 | if (ret == IXGBE_ERR_SFP_NOT_SUPPORTED) { | 3730 | if (ret == IXGBE_ERR_SFP_NOT_SUPPORTED) { |
@@ -4534,13 +4534,17 @@ static void ixgbe_sfp_config_module_task(struct work_struct *work) | |||
4534 | u32 err; | 4534 | u32 err; |
4535 | 4535 | ||
4536 | adapter->flags |= IXGBE_FLAG_IN_SFP_MOD_TASK; | 4536 | adapter->flags |= IXGBE_FLAG_IN_SFP_MOD_TASK; |
4537 | |||
4538 | /* Time for electrical oscillations to settle down */ | ||
4539 | msleep(100); | ||
4537 | err = hw->phy.ops.identify_sfp(hw); | 4540 | err = hw->phy.ops.identify_sfp(hw); |
4541 | |||
4538 | if (err == IXGBE_ERR_SFP_NOT_SUPPORTED) { | 4542 | if (err == IXGBE_ERR_SFP_NOT_SUPPORTED) { |
4539 | dev_err(&adapter->pdev->dev, "failed to initialize because " | 4543 | dev_err(&adapter->pdev->dev, "failed to initialize because " |
4540 | "an unsupported SFP+ module type was detected.\n" | 4544 | "an unsupported SFP+ module type was detected.\n" |
4541 | "Reload the driver after installing a supported " | 4545 | "Reload the driver after installing a supported " |
4542 | "module.\n"); | 4546 | "module.\n"); |
4543 | ixgbe_down(adapter); | 4547 | unregister_netdev(adapter->netdev); |
4544 | return; | 4548 | return; |
4545 | } | 4549 | } |
4546 | hw->mac.ops.setup_sfp(hw); | 4550 | hw->mac.ops.setup_sfp(hw); |
diff --git a/drivers/net/ixgbe/ixgbe_phy.c b/drivers/net/ixgbe/ixgbe_phy.c index 453e966762f0..9ecad17522c3 100644 --- a/drivers/net/ixgbe/ixgbe_phy.c +++ b/drivers/net/ixgbe/ixgbe_phy.c | |||
@@ -60,6 +60,7 @@ s32 ixgbe_identify_phy_generic(struct ixgbe_hw *hw) | |||
60 | 60 | ||
61 | if (hw->phy.type == ixgbe_phy_unknown) { | 61 | if (hw->phy.type == ixgbe_phy_unknown) { |
62 | for (phy_addr = 0; phy_addr < IXGBE_MAX_PHY_ADDR; phy_addr++) { | 62 | for (phy_addr = 0; phy_addr < IXGBE_MAX_PHY_ADDR; phy_addr++) { |
63 | hw->phy.mdio.prtad = phy_addr; | ||
63 | if (mdio45_probe(&hw->phy.mdio, phy_addr) == 0) { | 64 | if (mdio45_probe(&hw->phy.mdio, phy_addr) == 0) { |
64 | ixgbe_get_phy_id(hw); | 65 | ixgbe_get_phy_id(hw); |
65 | hw->phy.type = | 66 | hw->phy.type = |
@@ -68,6 +69,8 @@ s32 ixgbe_identify_phy_generic(struct ixgbe_hw *hw) | |||
68 | break; | 69 | break; |
69 | } | 70 | } |
70 | } | 71 | } |
72 | /* clear value if nothing found */ | ||
73 | hw->phy.mdio.prtad = 0; | ||
71 | } else { | 74 | } else { |
72 | status = 0; | 75 | status = 0; |
73 | } | 76 | } |