diff options
author | Roi Dayan <roid@nvidia.com> | 2023-04-02 14:13:25 +0300 |
---|---|---|
committer | Saeed Mahameed <saeedm@nvidia.com> | 2023-05-19 20:50:29 +0300 |
commit | c97c9fe48ae3ccca75fb6001a3bd2bfcb094dbd7 (patch) | |
tree | 19bb7d7319b57e495afbba7342ef952f701246e1 /drivers/net/ethernet/mellanox/mlx5/core/eswitch.c | |
parent | 806815bf3c1d885e686ddc0e75d941078dcf56ae (diff) | |
download | linux-c97c9fe48ae3ccca75fb6001a3bd2bfcb094dbd7.tar.xz |
net/mlx5e: E-Switch, Update when to set other vport context
Other vport context should be set if vport number is not 0.
In case of ECPF, vport 0 represents the host PF representor so also
need to set other vport context.
Signed-off-by: Roi Dayan <roid@nvidia.com>
Reviewed-by: Maor Dickman <maord@nvidia.com>
Signed-off-by: Saeed Mahameed <saeedm@nvidia.com>
Diffstat (limited to 'drivers/net/ethernet/mellanox/mlx5/core/eswitch.c')
-rw-r--r-- | drivers/net/ethernet/mellanox/mlx5/core/eswitch.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/net/ethernet/mellanox/mlx5/core/eswitch.c b/drivers/net/ethernet/mellanox/mlx5/core/eswitch.c index 901c53751b0a..bf97a593d1d4 100644 --- a/drivers/net/ethernet/mellanox/mlx5/core/eswitch.c +++ b/drivers/net/ethernet/mellanox/mlx5/core/eswitch.c @@ -113,7 +113,8 @@ static int arm_vport_context_events_cmd(struct mlx5_core_dev *dev, u16 vport, opcode, MLX5_CMD_OP_MODIFY_NIC_VPORT_CONTEXT); MLX5_SET(modify_nic_vport_context_in, in, field_select.change_event, 1); MLX5_SET(modify_nic_vport_context_in, in, vport_number, vport); - MLX5_SET(modify_nic_vport_context_in, in, other_vport, 1); + if (vport || mlx5_core_is_ecpf(dev)) + MLX5_SET(modify_nic_vport_context_in, in, other_vport, 1); nic_vport_ctx = MLX5_ADDR_OF(modify_nic_vport_context_in, in, nic_vport_context); |