Skip to content

Commit

Permalink
net/mlx5: remove device status check in flow creation
Browse files Browse the repository at this point in the history
[ upstream commit 4095ce34095e33ae9e8b19150b9280ff8737a590 ]

The flow rule can be inserted even before the device started. The
only exception is for a queue or RSS action.

For the other interfaces of template API, the start status is not
checked. The checking would cause some cache miss or eviction since
the flag locates on some other cache line.

Fixes: f1fecff ("net/mlx5: support Direct Rules action template API")

Signed-off-by: Bing Zhao <bingz@nvidia.com>
Acked-by: Ori Kam <orika@nvidia.com>
  • Loading branch information
zorrohahaha authored and bluca committed Mar 13, 2024
1 parent cc21b4a commit fccac36
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions drivers/net/mlx5/mlx5_flow_hw.c
Original file line number Diff line number Diff line change
Expand Up @@ -2514,10 +2514,6 @@ flow_hw_async_flow_create(struct rte_eth_dev *dev,
uint32_t flow_idx;
int ret;

if (unlikely((!dev->data->dev_started))) {
rte_errno = EINVAL;
goto error;
}
if (unlikely(!priv->hw_q[queue].job_idx)) {
rte_errno = ENOMEM;
goto error;
Expand Down

0 comments on commit fccac36

Please sign in to comment.