DPDK patches and discussions
 help / color / mirror / Atom feed
From: Chaoyong He <chaoyong.he@corigine.com>
To: dev@dpdk.org
Cc: oss-drivers@corigine.com, Long Wu <long.wu@corigine.com>,
	chaoyong.he@corigine.com, stable@dpdk.org,
	Peng Zhang <peng.zhang@corigine.com>
Subject: [PATCH] net/nfp: fix offload drop flow rule failed
Date: Mon,  8 Jul 2024 13:37:24 +0800	[thread overview]
Message-ID: <20240708053724.82369-1-chaoyong.he@corigine.com> (raw)

From: Long Wu <long.wu@corigine.com>

The issue is caused by an invalid exit logic in flow compile function.

Fixes: 4839d4b4e180 ("net/nfp: forbid offload flow rules with empty action list")
Cc: chaoyong.he@corigine.com
Cc: stable@dpdk.org

Signed-off-by: Long Wu <long.wu@corigine.com>
Reviewed-by: Chaoyong He <chaoyong.he@corigine.com>
Reviewed-by: Peng Zhang <peng.zhang@corigine.com>
---
 drivers/net/nfp/flower/nfp_flower_flow.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/net/nfp/flower/nfp_flower_flow.c b/drivers/net/nfp/flower/nfp_flower_flow.c
index 24e7047407..df84eedae4 100644
--- a/drivers/net/nfp/flower/nfp_flower_flow.c
+++ b/drivers/net/nfp/flower/nfp_flower_flow.c
@@ -4757,7 +4757,7 @@ nfp_flow_compile_action(struct nfp_flower_representor *representor,
 		total_actions++;
 	}
 
-	if (total_actions == 0 || param.position == param.action_data) {
+	if (nfp_flow->install_flag && total_actions == 0) {
 		PMD_DRV_LOG(ERR, "The action list is empty");
 		return -ENOTSUP;
 	}
-- 
2.39.1


             reply	other threads:[~2024-07-08  5:37 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-07-08  5:37 Chaoyong He [this message]
2024-07-08 15:58 ` Ferruh Yigit

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=20240708053724.82369-1-chaoyong.he@corigine.com \
    --to=chaoyong.he@corigine.com \
    --cc=dev@dpdk.org \
    --cc=long.wu@corigine.com \
    --cc=oss-drivers@corigine.com \
    --cc=peng.zhang@corigine.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).