Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 088c4ee3 authored by Catherine Sullivan's avatar Catherine Sullivan Committed by Jeff Kirsher
Browse files

i40e: Reassign incorrect PHY type to fix a FW bug



Some FW versions are incorrectly reporting a breakout cable as PHY type
0x3 when it should be 0x16 (I40E_PHY_TYPE_10GBASE_SFPP_CU).
If we get this value back from FW and the version is < 4.40, reassign it
to I40E_PHY_TYPE_10GBASE_SFPP_CU.

Change-ID: Ibb41a0e3cd2c0753744e8553959240df6ed13ae8
Signed-off-by: default avatarCatherine Sullivan <catherine.sullivan@intel.com>
Tested-by: default avatarJim Young <james.m.young@intel.com>
Signed-off-by: default avatarJeff Kirsher <jeffrey.t.kirsher@intel.com>
parent 9a660eea
Loading
Loading
Loading
Loading
+4 −0
Original line number Original line Diff line number Diff line
@@ -1481,6 +1481,10 @@ i40e_status i40e_aq_get_link_info(struct i40e_hw *hw,
	else
	else
		hw_link_info->lse_enable = false;
		hw_link_info->lse_enable = false;


	if ((hw->aq.fw_maj_ver < 4 || (hw->aq.fw_maj_ver == 4 &&
	     hw->aq.fw_min_ver < 40)) && hw_link_info->phy_type == 0xE)
		hw_link_info->phy_type = I40E_PHY_TYPE_10GBASE_SFPP_CU;

	/* save link status information */
	/* save link status information */
	if (link)
	if (link)
		*link = *hw_link_info;
		*link = *hw_link_info;