diff options
author | Maxim Mikityanskiy <maximmi@mellanox.com> | 2021-02-04 12:21:16 +0200 |
---|---|---|
committer | Saeed Mahameed <saeedm@nvidia.com> | 2021-04-16 11:48:17 -0700 |
commit | b3b886cf965d5f8d8e51f9481ce60ee8f9548580 (patch) | |
tree | 5df96f6389c55ee4dfec891d390b7204d3606fc0 /drivers/net/ethernet/mellanox/mlx5/core/en.h | |
parent | net/mlx5e: Use mlx5e_safe_switch_channels when channels are closed (diff) | |
download | linux-dev-b3b886cf965d5f8d8e51f9481ce60ee8f9548580.tar.xz linux-dev-b3b886cf965d5f8d8e51f9481ce60ee8f9548580.zip |
net/mlx5e: Refactor on-the-fly configuration changes
This commit extends mlx5e_safe_switch_channels() to support on-the-fly
configuration changes, when the channels are open, but don't need to be
recreated. Such flows exist when a parameter being changed doesn't
affect how the queues are created, or when the queues can be modified
while remaining active.
Before this commit, such flows were handled as special cases on the
caller site. This commit adds this functionality to
mlx5e_safe_switch_channels(), allowing the caller to pass a boolean
indicating whether it's required to recreate the channels or it's
allowed to skip it. The logic of switching channel parameters is now
completely encapsulated into mlx5e_safe_switch_channels().
Signed-off-by: Maxim Mikityanskiy <maximmi@mellanox.com>
Signed-off-by: Saeed Mahameed <saeedm@nvidia.com>
Diffstat (limited to 'drivers/net/ethernet/mellanox/mlx5/core/en.h')
-rw-r--r-- | drivers/net/ethernet/mellanox/mlx5/core/en.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/ethernet/mellanox/mlx5/core/en.h b/drivers/net/ethernet/mellanox/mlx5/core/en.h index 28a68eef8ae6..d9ed20a4db53 100644 --- a/drivers/net/ethernet/mellanox/mlx5/core/en.h +++ b/drivers/net/ethernet/mellanox/mlx5/core/en.h @@ -1021,7 +1021,7 @@ int mlx5e_safe_reopen_channels(struct mlx5e_priv *priv); int mlx5e_safe_switch_channels(struct mlx5e_priv *priv, struct mlx5e_channels *new_chs, mlx5e_fp_preactivate preactivate, - void *context); + void *context, bool reset); int mlx5e_update_tx_netdev_queues(struct mlx5e_priv *priv); int mlx5e_num_channels_changed(struct mlx5e_priv *priv); int mlx5e_num_channels_changed_ctx(struct mlx5e_priv *priv, void *context); |