CNB96: netdev_features: start cleaning netdev_features_t up

JIRA: https://issues.redhat.com/browse/RHEL-59091

Explanation from the upstream cover letter by Alexander Lobakin:

NETDEV_FEATURE_COUNT is currently 64, which means we can't add any new features as netdev_features_t is u64. As per several discussions, instead of converting netdev_features_t to a bitmap, which would mean A LOT of changes, we can try cleaning up netdev feature bits. There's a bunch of bits which don't really mean features, rather device attributes/properties that can't be changed via Ethtool in any of the drivers. Such attributes can be moved to netdev private flags without losing any functionality.

Start converting some read-only netdev features to private flags from the ones that are most obvious, like lockless Tx, inability to change network namespace etc. I was able to reduce NETDEV_FEATURE_COUNT from 64 to 60, which mean 4 free slots for new features. There are obviously more read-only features to convert, such as highDMA, "challenged VLAN", HSR (4 bits) - this will be done in subsequent series. Please note that netdev features are not uAPI/ABI by any means. Ethtool passes their names and bits to the userspace separately and there are no hardcoded names/bits in the userspace, so that new Ethtool could work on older kernels and vice versa. Even shell scripts won't most likely break since the removed bits were always read-only, meaning nobody would try touching them from a script.

I proposed a Release Note Text in the Jira to document that "tx-lockless", "netns-local", "fcoe-mtu" will no longer appear in "ethtool -k".

Signed-off-by: Michal Schmidt mschmidt@redhat.com

Edited by Michal Schmidt

Merge request reports

Loading