patches for DPDK stable branches
 help / color / Atom feed
From: Ciara Power <>
Cc:, Ciara Power <>,
Subject: [dpdk-stable] [PATCH] examples/ioat: fix failure check for ioat dequeue
Date: Tue,  4 Feb 2020 16:00:06 +0000
Message-ID: <> (raw)

The nb_dq return value from the ioat dequeue is negative in failure
cases, however the variable was an unsigned int, causing the condition
where nb_dq <= 0 to never be true. This is now cast to a signed int,
which will successfully reflect the -1 value to be used in this
conditional check.

Coverity issue: 350342
Coverity issue: 350349
Fixes: 92c981637ffc ("examples/ioat: handle failure case for ioat dequeue")

Signed-off-by: Ciara Power <>
 examples/ioat/ioatfwd.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/examples/ioat/ioatfwd.c b/examples/ioat/ioatfwd.c
index e9117718f..f460a5c92 100644
--- a/examples/ioat/ioatfwd.c
+++ b/examples/ioat/ioatfwd.c
@@ -460,7 +460,7 @@ ioat_tx_port(struct rxtx_port_config *tx_config)
-		if (nb_dq <= 0)
+		if ((int32_t) nb_dq <= 0)
 		if (copy_mode == COPY_MODE_IOAT_NUM)

             reply index

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-02-04 16:00 Ciara Power [this message]
2020-02-13 12:09 ` Bruce Richardson
2020-02-13 14:01 ` [dpdk-stable] [dpdk-dev] " David Marchand

Reply instructions:

You may reply publically 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:

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

  git send-email \ \ \ \ \ \

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

patches for DPDK stable branches

Archives are clonable:
	git clone --mirror stable/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 stable stable/ \
	public-inbox-index stable

Newsgroup available over NNTP:

AGPL code for this site: git clone public-inbox