Skip to content

Commit e3c1950

Browse files
Gal PressmanSaeed Mahameed
authored andcommitted
net/mlx5e: Fix ethtool pause support and advertise reporting
Pause bit should set when RX pause is on, not TX pause. Also, setting Asym_Pause is incorrect, and should be turned off. Fixes: 665bc53 ("net/mlx5e: Use new ethtool get/set link ksettings API") Signed-off-by: Gal Pressman <[email protected]> Cc: [email protected] Signed-off-by: Saeed Mahameed <[email protected]>
1 parent b383b54 commit e3c1950

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

drivers/net/ethernet/mellanox/mlx5/core/en_ethtool.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -794,7 +794,6 @@ static void get_supported(u32 eth_proto_cap,
794794
ptys2ethtool_supported_port(link_ksettings, eth_proto_cap);
795795
ptys2ethtool_supported_link(supported, eth_proto_cap);
796796
ethtool_link_ksettings_add_link_mode(link_ksettings, supported, Pause);
797-
ethtool_link_ksettings_add_link_mode(link_ksettings, supported, Asym_Pause);
798797
}
799798

800799
static void get_advertising(u32 eth_proto_cap, u8 tx_pause,
@@ -804,7 +803,7 @@ static void get_advertising(u32 eth_proto_cap, u8 tx_pause,
804803
unsigned long *advertising = link_ksettings->link_modes.advertising;
805804

806805
ptys2ethtool_adver_link(advertising, eth_proto_cap);
807-
if (tx_pause)
806+
if (rx_pause)
808807
ethtool_link_ksettings_add_link_mode(link_ksettings, advertising, Pause);
809808
if (tx_pause ^ rx_pause)
810809
ethtool_link_ksettings_add_link_mode(link_ksettings, advertising, Asym_Pause);

0 commit comments

Comments
 (0)