summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSomnath Kotur <somnath.kotur@broadcom.com>2022-02-20 04:05:47 -0500
committerDavid S. Miller <davem@davemloft.net>2022-02-20 13:47:14 +0000
commit84d3c83e6ea7d46cf3de3a54578af73eb24a64f2 (patch)
tree0221daf6910b1897a002b7f2d022996f19ecd632
parent8940e6b669ca1196ce0a0549c819078096390f76 (diff)
downloadlinux-84d3c83e6ea7d46cf3de3a54578af73eb24a64f2.tar.bz2
bnxt_en: Fix active FEC reporting to ethtool
ethtool --show-fec <interface> does not show anything when the Active FEC setting in the chip is set to None. Fix it to properly return ETHTOOL_FEC_OFF in that case. Fixes: 8b2775890ad8 ("bnxt_en: Report FEC settings to ethtool.") Signed-off-by: Somnath Kotur <somnath.kotur@broadcom.com> Signed-off-by: Michael Chan <michael.chan@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r--drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c b/drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c
index 003330e8cd58..e195f4a669d8 100644
--- a/drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c
+++ b/drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c
@@ -1969,6 +1969,9 @@ static int bnxt_get_fecparam(struct net_device *dev,
case PORT_PHY_QCFG_RESP_ACTIVE_FEC_FEC_RS272_IEEE_ACTIVE:
fec->active_fec |= ETHTOOL_FEC_LLRS;
break;
+ case PORT_PHY_QCFG_RESP_ACTIVE_FEC_FEC_NONE_ACTIVE:
+ fec->active_fec |= ETHTOOL_FEC_OFF;
+ break;
}
return 0;
}