patches for DPDK stable branches
 help / color / mirror / Atom feed
From: Li Zhang <lizh@nvidia.com>
To: lizh@nvidia.com
Cc: stable@dpdk.org
Subject: [dpdk-stable] [PATCH v1 1/1] net/mlx5: fix port id / push VLAN actions index incorrect
Date: Tue, 16 Mar 2021 10:31:24 +0200	[thread overview]
Message-ID: <20210316083124.677467-1-lizh@nvidia.com> (raw)

When using port id or push VLAN action index to find
the action in cache, it will fail to find actions.
The root cause is the index is not saved in cache when
creating the port id action or push vlan action.
To fix these issues, update the index in cache when creating.

Fixes: 0fd5f82aaa0 ("net/mlx5: make port ID action cache thread safe")
Fixes: 3422af2af2e ("net/mlx5: make push VLAN action cache thread safe")
Cc: stable@dpdk.org

Signed-off-by: Li Zhang <lizh@nvidia.com>
---
 drivers/net/mlx5/mlx5_flow_dv.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/net/mlx5/mlx5_flow_dv.c b/drivers/net/mlx5/mlx5_flow_dv.c
index 1a74d5ac2b..23e5849783 100644
--- a/drivers/net/mlx5/mlx5_flow_dv.c
+++ b/drivers/net/mlx5/mlx5_flow_dv.c
@@ -3612,6 +3612,7 @@ flow_dv_port_id_create_cb(struct mlx5_cache_list *list,
 				   "cannot create action");
 		return NULL;
 	}
+	cache->idx = idx;
 	return &cache->entry;
 }
 
@@ -3703,6 +3704,7 @@ flow_dv_push_vlan_create_cb(struct mlx5_cache_list *list,
 				   "cannot create push vlan action");
 		return NULL;
 	}
+	cache->idx = idx;
 	return &cache->entry;
 }
 
-- 
2.21.0


             reply	other threads:[~2021-03-16  8:31 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-03-16  8:31 Li Zhang [this message]
2021-03-16 12:05 Li Zhang
2021-03-16 12:21 ` Slava Ovsiienko
2021-03-17 16:16 ` Raslan Darawsheh

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20210316083124.677467-1-lizh@nvidia.com \
    --to=lizh@nvidia.com \
    --cc=stable@dpdk.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).