|
@@ -2278,13 +2278,15 @@ i40e_status i40e_update_link_info(struct i40e_hw *hw)
|
|
if (status)
|
|
if (status)
|
|
return status;
|
|
return status;
|
|
|
|
|
|
- status = i40e_aq_get_phy_capabilities(hw, false, false, &abilities,
|
|
|
|
- NULL);
|
|
|
|
- if (status)
|
|
|
|
- return status;
|
|
|
|
|
|
+ if (hw->phy.link_info.link_info & I40E_AQ_MEDIA_AVAILABLE) {
|
|
|
|
+ status = i40e_aq_get_phy_capabilities(hw, false, false,
|
|
|
|
+ &abilities, NULL);
|
|
|
|
+ if (status)
|
|
|
|
+ return status;
|
|
|
|
|
|
- memcpy(hw->phy.link_info.module_type, &abilities.module_type,
|
|
|
|
- sizeof(hw->phy.link_info.module_type));
|
|
|
|
|
|
+ memcpy(hw->phy.link_info.module_type, &abilities.module_type,
|
|
|
|
+ sizeof(hw->phy.link_info.module_type));
|
|
|
|
+ }
|
|
|
|
|
|
return status;
|
|
return status;
|
|
}
|
|
}
|