OSDN Git Service

net/mlx5e: Ethtool driver callback for query/set FEC policy
authorShay Agroskin <shayag@mellanox.com>
Tue, 28 Aug 2018 07:37:52 +0000 (10:37 +0300)
committerSaeed Mahameed <saeedm@mellanox.com>
Thu, 18 Oct 2018 20:13:31 +0000 (13:13 -0700)
commit6cfa94605091b65cb2895a826750a30fbed99770
tree38fda5a72d0cea05d3f4ffdac2bd4dcb91303c85
parent2095b264147753eee0f122b8c0c9f035a32f0a25
net/mlx5e: Ethtool driver callback for query/set FEC policy

Driver callback function for 'ethtool --show-fec',
'ethtool --set-fec' commands.

The query function returns active and configured FEC policy
for current link speed.

The set function sets FEC policy for all supported link
speeds.
1) If current link speed doesn't support requested FEC policy,
   the function fails.
2) If a different link speed doesn't support requested FEC
   policy, FEC capbilities for this speed are turned off.

Signed-off-by: Shay Agroskin <shayag@mellanox.com>
Reviewed-by: Eran Ben Elisha <eranbe@mellanox.com>
Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>
drivers/net/ethernet/mellanox/mlx5/core/en_ethtool.c