]> git.baikalelectronics.ru Git - kernel.git/commit
cxgb4/cxgb4vf: fix flow control display for auto negotiation
authorRahul Lakkireddy <rahul.lakkireddy@chelsio.com>
Mon, 30 Dec 2019 12:44:08 +0000 (18:14 +0530)
committerDavid S. Miller <davem@davemloft.net>
Mon, 30 Dec 2019 22:40:42 +0000 (14:40 -0800)
commit3eb56994633dd140dccc3514ad0a168e9e2b9a67
tree84a55bc3e51ec51d3948cd22ba140567c5890f79
parent28f7ccb0cb90b5e4c3a2a9782d76ca86e940336b
cxgb4/cxgb4vf: fix flow control display for auto negotiation

As per 802.3-2005, Section Two, Annex 28B, Table 28B-2 [1], when
_only_ Rx pause is enabled, both symmetric and asymmetric pause
towards local device must be enabled. Also, firmware returns the local
device's flow control pause params as part of advertised capabilities
and negotiated params as part of current link attributes. So, fix up
ethtool's flow control pause params fetch logic to read from acaps,
instead of linkattr.

[1] https://standards.ieee.org/standard/802_3-2005.html

Fixes: 4fcf6640524d ("cxgb4/cxgbvf: Handle 32-bit fw port capabilities")
Signed-off-by: Surendra Mobiya <surendra@chelsio.com>
Signed-off-by: Rahul Lakkireddy <rahul.lakkireddy@chelsio.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/chelsio/cxgb4/cxgb4.h
drivers/net/ethernet/chelsio/cxgb4/cxgb4_ethtool.c
drivers/net/ethernet/chelsio/cxgb4/t4_hw.c
drivers/net/ethernet/chelsio/cxgb4vf/cxgb4vf_main.c
drivers/net/ethernet/chelsio/cxgb4vf/t4vf_common.h
drivers/net/ethernet/chelsio/cxgb4vf/t4vf_hw.c