net/bnxt: fix speed autonegotiation
authorKalesh AP <kalesh-anakkur.purayil@broadcom.com>
Wed, 27 Apr 2022 14:58:16 +0000 (20:28 +0530)
committerAjit Khaparde <ajit.khaparde@broadcom.com>
Tue, 10 May 2022 05:13:41 +0000 (07:13 +0200)
commit34a075947879232fcbaf656665380ce25f0523aa
tree8a06232e4c406ead627a2d68ecf3c6eeb86823a7
parent8599820580c56477670b9f7260a2a1627a1d54dc
net/bnxt: fix speed autonegotiation

The "active_fec_signal_mode" in HWRM_PORT_PHY_QCFG response
does not return correct value till the link is up. Driver cannot
rely on active_fec_signal_mode while setting autoneg speed.

While setting autoneg speed, driver is currently checking only
"auto_link_speed_mask". Fixed to check "auto_pam4_link_speed_mask"
as well. Also, while setting auto mode and setting speed mask,
driver will have to set both NRZ and PAM4 mask.

Fixes: c23f9ded0391 ("net/bnxt: support 200G PAM4 link")
Cc: stable@dpdk.org
Signed-off-by: Kalesh AP <kalesh-anakkur.purayil@broadcom.com>
Reviewed-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
Reviewed-by: Somnath Kotur <somnath.kotur@broadcom.com>
drivers/net/bnxt/bnxt_hwrm.c