net/bnxt: fix unnecessary delay in port stop
authorKalesh AP <kalesh-anakkur.purayil@broadcom.com>
Thu, 6 Feb 2020 16:33:08 +0000 (22:03 +0530)
committerFerruh Yigit <ferruh.yigit@intel.com>
Fri, 14 Feb 2020 11:42:12 +0000 (12:42 +0100)
commit967a722be08cacdd05e6a29d2e1790d5747a6217
tree862544e3e155dcd5caa02a4a0951a2a33cc32616
parenta0c2b3d8ee501b90eb11c2a82da0aaca19362bd3
net/bnxt: fix unnecessary delay in port stop

VFs and multifunction PFs do not have the privilege to change
link configuration. We force the physical link down as a part
of device stop only for single physical function(SPF).

This change also helps in eliminating the logs when a VF port
is stopped:

"Port 0: link state change event"
"bnxt_print_link_info(): Port 0 Link Up - speed 25000 Mbps - full-duplex"

Fixes: 316e412299fd ("net/bnxt: fix crash when closing")
Cc: stable@dpdk.org
Signed-off-by: Kalesh AP <kalesh-anakkur.purayil@broadcom.com>
Reviewed-by: Somnath Kotur <somnath.kotur@broadcom.com>
Reviewed-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
drivers/net/bnxt/bnxt_ethdev.c