Commit 3747f031 authored by Chinh T Cao's avatar Chinh T Cao Committed by Jeff Kirsher

ice: Don't clear auto_fec bit in ice_cfg_phy_fec()

The driver should never clear the auto_fec_enable bit.
Signed-off-by: default avatarChinh T Cao <chinh.t.cao@intel.com>
Tested-by: default avatarAndrew Bowers <andrewx.bowers@intel.com>
Signed-off-by: default avatarJeff Kirsher <jeffrey.t.kirsher@intel.com>
parent 057911ba
...@@ -2181,27 +2181,24 @@ ice_cfg_phy_fec(struct ice_aqc_set_phy_cfg_data *cfg, enum ice_fec_mode fec) ...@@ -2181,27 +2181,24 @@ ice_cfg_phy_fec(struct ice_aqc_set_phy_cfg_data *cfg, enum ice_fec_mode fec)
{ {
switch (fec) { switch (fec) {
case ICE_FEC_BASER: case ICE_FEC_BASER:
/* Clear auto FEC and RS bits, and AND BASE-R ability /* Clear RS bits, and AND BASE-R ability
* bits and OR request bits. * bits and OR request bits.
*/ */
cfg->caps &= ~ICE_AQC_PHY_EN_AUTO_FEC;
cfg->link_fec_opt &= ICE_AQC_PHY_FEC_10G_KR_40G_KR4_EN | cfg->link_fec_opt &= ICE_AQC_PHY_FEC_10G_KR_40G_KR4_EN |
ICE_AQC_PHY_FEC_25G_KR_CLAUSE74_EN; ICE_AQC_PHY_FEC_25G_KR_CLAUSE74_EN;
cfg->link_fec_opt |= ICE_AQC_PHY_FEC_10G_KR_40G_KR4_REQ | cfg->link_fec_opt |= ICE_AQC_PHY_FEC_10G_KR_40G_KR4_REQ |
ICE_AQC_PHY_FEC_25G_KR_REQ; ICE_AQC_PHY_FEC_25G_KR_REQ;
break; break;
case ICE_FEC_RS: case ICE_FEC_RS:
/* Clear auto FEC and BASE-R bits, and AND RS ability /* Clear BASE-R bits, and AND RS ability
* bits and OR request bits. * bits and OR request bits.
*/ */
cfg->caps &= ~ICE_AQC_PHY_EN_AUTO_FEC;
cfg->link_fec_opt &= ICE_AQC_PHY_FEC_25G_RS_CLAUSE91_EN; cfg->link_fec_opt &= ICE_AQC_PHY_FEC_25G_RS_CLAUSE91_EN;
cfg->link_fec_opt |= ICE_AQC_PHY_FEC_25G_RS_528_REQ | cfg->link_fec_opt |= ICE_AQC_PHY_FEC_25G_RS_528_REQ |
ICE_AQC_PHY_FEC_25G_RS_544_REQ; ICE_AQC_PHY_FEC_25G_RS_544_REQ;
break; break;
case ICE_FEC_NONE: case ICE_FEC_NONE:
/* Clear auto FEC and all FEC option bits. */ /* Clear all FEC option bits. */
cfg->caps &= ~ICE_AQC_PHY_EN_AUTO_FEC;
cfg->link_fec_opt &= ~ICE_AQC_PHY_FEC_MASK; cfg->link_fec_opt &= ~ICE_AQC_PHY_FEC_MASK;
break; break;
case ICE_FEC_AUTO: case ICE_FEC_AUTO:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment