mlx5e update features on config changes
Tariq Toukan
maintainercover mlx5e update features on config changes
Hi,
This small patchset by Dragos adds a call to netdev_update_features() in configuration changes that could impact the features status.
Series generated against:
commit 81bc949f640f ("selftests: tls: add a selftest for wrapping rec_seq")
Thanks,
Tariq
Dragos Tatulea (2):
net/mlx5e: Update features on MTU change
net/mlx5e: Update features on ring size change
drivers/net/ethernet/mellanox/mlx5/core/en_ethtool.c | 3 +++ drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 4 ++++ 2 files changed, 7 insertions(+)
Signature · 1 line
2.44.0
Tariq Toukan
maintainerPATCH 1/2 net/mlx5e: Update features on MTU change
From: Dragos Tatulea <[email protected]>
When the MTU changes successfully, trigger netdev_update_features() to enable features in wanted state if applicable.
An example of such scenario:
$ ip link set dev eth1 up $ ethtool --set-ring eth1 rx 8192 $ ip link set dev eth1 mtu 9000 $ ethtool --features eth1 rx-gro-hw on --> fails $ ip link set dev eth1 mtu 7000
With this patch, HW GRO will be turned on automatically because it is set in the device's wanted_features.
--- drivers/net/ethernet/mellanox/mlx5/core/en_main.c | 4 ++++ 1 file changed, 4 insertions(+)
drivers/net/ethernet/mellanox/mlx5/core/en_main.c +4 -0
@@ -4557,6 +4557,10 @@ int mlx5e_change_mtu(struct net_device *netdev, int new_mtu, out:WRITE_ONCE (netdev->mtu, params->sw_mtu);mutex_unlock (&priv->state_lock); + +if (!err) +netdev_update_features (netdev); +return err; }
Signature · 1 line
2.44.0
Re: [PATCH net-next 1/2] net/mlx5e: Update features on MTU change
Quoted 12 lines · Tariq Toukan
From: Dragos Tatulea <[email protected]>
When the MTU changes successfully, trigger
netdev_update_features()to enable features in wanted state if applicable.An example of such scenario:
$ ip link set dev eth1 up $ ethtool --set-ring eth1 rx 8192 $ ip link set dev eth1 mtu 9000 $ ethtool --features eth1 rx-gro-hw on --> fails $ ip link set dev eth1 mtu 7000
Quoted 6 lines
With this patch, HW GRO will be turned on automatically because it is set in the device's
wanted_features.Signed-off-by Dragos Tatulea <[email protected]>Reviewed-by Gal Pressman <[email protected]>Signed-off-by Tariq Toukan <[email protected]>
Tariq Toukan
maintainerPATCH 2/2 net/mlx5e: Update features on ring size change
In reply to Tariq ToukanFrom: Dragos Tatulea <[email protected]>
When the ring size changes successfully, trigger netdev_update_features() to enable features in wanted state if applicable.
An example of such scenario:
$ ip link set dev eth1 up $ ethtool --set-ring eth1 rx 8192 $ ip link set dev eth1 mtu 9000 $ ethtool --features eth1 rx-gro-hw on --> fails $ ethtool --set-ring eth1 rx 1024
With this patch, HW GRO will be turned on automatically because it is set in the device's wanted_features.
--- drivers/net/ethernet/mellanox/mlx5/core/en_ethtool.c | 3 +++ 1 file changed, 3 insertions(+)
drivers/net/ethernet/mellanox/mlx5/core/en_ethtool.c +3 -0
@@ -406,6 +406,9 @@ int mlx5e_ethtool_set_ringparam(struct mlx5e_priv *priv, unlock:mutex_unlock (&priv->state_lock); +if (!err) +netdev_update_features (priv->netdev); +return err; }
Signature · 1 line
2.44.0
Re: [PATCH net-next 2/2] net/mlx5e: Update features on ring size change
Quoted 13 lines · Tariq Toukan
From: Dragos Tatulea <[email protected]>
When the ring size changes successfully, trigger
netdev_update_features()to enable features in wanted state if applicable.An example of such scenario:
$ ip link set dev eth1 up $ ethtool --set-ring eth1 rx 8192 $ ip link set dev eth1 mtu 9000 $ ethtool --features eth1 rx-gro-hw on --> fails $ ethtool --set-ring eth1 rx 1024
Quoted 6 lines
With this patch, HW GRO will be turned on automatically because it is set in the device's
wanted_features.Signed-off-by Dragos Tatulea <[email protected]>Reviewed-by Gal Pressman <[email protected]>Signed-off-by Tariq Toukan <[email protected]>
This series was applied to netdev/net-next.git (main) by Jakub Kicinski <[email protected]>:
Hello:
This series was applied to netdev/net-next.git (main) by Jakub Kicinski <[email protected]>:
Quoted 9 lines · On Thu, 24 Oct 2024 19:41:31 +0300 you wrote:
Hi,
This small patchset by Dragos adds a call to
netdev_update_features()in configuration changes that could impact the features status.Series generated against:
commit81bc949f640f("selftests: tls: add a selftest for wrappingrec_seq")[...]
Here is the summary with links:
- [net-next,1/2] net/mlx5e: Update features on MTU change
https://git.kernel.org/netdev/net-next/c/7999da12a670 - [net-next,2/2] net/mlx5e: Update features on ring size change https://git.kernel.org/netdev/net-next/c/a7b6c074e42d
You are awesome, thank you!
Signature · 2 lines
Deet-doot-dot, I am a bot. https://korg.docs.kernel.org/patchwork/pwbot.html