system-linux: add support for configurable rxhash option#55
Open
tk154 wants to merge 3 commits intoopenwrt:masterfrom
Open
system-linux: add support for configurable rxhash option#55tk154 wants to merge 3 commits intoopenwrt:masterfrom
tk154 wants to merge 3 commits intoopenwrt:masterfrom
Conversation
Rename `ethtool_feature_value()` to `ethtool_get_feature_value()` and change its return type from `bool` to `int` for clearer error handling. - Return `-1` on error instead of `false` - Return `0` to indicate the feature isn't enabled - Return `1` to indicate the feature is enabled Signed-off-by: Til Kaiser <mail@tk154.de>
Introduce `ethtool_set_feature_value()` to enable or disable NIC features via `ETHTOOL_SFEATURES`. Signed-off-by: Til Kaiser <mail@tk154.de>
Some devices (e.g. Marvell boards) support Receive Side Scaling (RSS)
but do not enable it by default. This change introduces a new `rxhash`
option in the device section of the network configuration to toggle
the feature, e.g.:
config device
option name 'eth0'
option rxhash '1'
Signed-off-by: Til Kaiser <mail@tk154.de>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This series extends
netifdwith helper functions for ethtoolfeature management and introduces a new
rxhashdevice option.Changes include:
ethtool_feature_value()toethtool_get_feature_value()to query NIC features with error handling (-1 on error, 0/1 for disabled/enabled).
ethtool_set_feature_value()to enable or disable NIC featuresvia
ETHTOOL_SFEATURES.rxhashoption in network configuration to toggleReceive Side Scaling (RSS). This is useful on devices such as
Marvell boards, where RSS support exists but isn't enabled by default.
Example configuration: