Maxim Mikityanskiy 2847bfed88 ethtool: Account for hw_features in netlink interface
ethtool-netlink ignores dev->hw_features and may confuse the drivers by
asking them to enable features not in the hw_features bitmask. For
example:

1. ethtool -k eth0
   tls-hw-tx-offload: off [fixed]
2. ethtool -K eth0 tls-hw-tx-offload on
   tls-hw-tx-offload: on
3. ethtool -k eth0
   tls-hw-tx-offload: on [fixed]

Fitler out dev->hw_features from req_wanted to fix it and to resemble
the legacy ethtool behavior.

Fixes: 0980bfcd6954 ("ethtool: set netdev features with FEATURES_SET request")
Signed-off-by: Maxim Mikityanskiy <maximmi@mellanox.com>
Reviewed-by: Michal Kubecek <mkubecek@suse.cz>
Signed-off-by: David S. Miller <davem@davemloft.net>
2020-08-18 16:00:24 -07:00
..
2020-07-10 13:54:00 -07:00
2020-07-10 13:54:00 -07:00
2020-03-29 22:32:36 -07:00
2020-06-29 17:45:02 -07:00
2020-07-10 13:54:00 -07:00
2020-07-10 13:54:00 -07:00
2020-03-29 22:32:36 -07:00
2020-07-10 13:54:00 -07:00