DPDK-dev Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Stephen Hemminger <stephen@networkplumber.org>
To: dev@dpdk.org
Cc: Stephen Hemminger <stephen@networkplumber.org>,
	Aman Singh <aman.deep.singh@intel.com>
Subject: [PATCH 4/4] app/testpmd: report reason when queue setup command fails
Date: Thu,  2 Jul 2026 09:10:14 -0700	[thread overview]
Message-ID: <20260702161244.363233-5-stephen@networkplumber.org> (raw)
In-Reply-To: <20260702161244.363233-1-stephen@networkplumber.org>

The interactive "port <id> rxq|txq <id> setup" command printed a
bare failure message. rte_eth_rx/tx_queue_setup() can fail with
-EBUSY without logging anything, for example when the port is
started and the PMD does not support runtime queue setup, leaving
the user with no clue:

  testpmd> port 0 rxq 0 setup
  Failed to setup RX queue

Print the error string:

  Failed to setup RX queue: Device or resource busy

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
---
 app/test-pmd/cmdline.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/app/test-pmd/cmdline.c b/app/test-pmd/cmdline.c
index bb62778a26..e0dcdc1193 100644
--- a/app/test-pmd/cmdline.c
+++ b/app/test-pmd/cmdline.c
@@ -3092,7 +3092,8 @@ cmd_setup_rxtx_queue_parsed(
 				     &port->rxq[res->qid].conf,
 				     mp);
 		if (ret)
-			fprintf(stderr, "Failed to setup RX queue\n");
+			fprintf(stderr, "Failed to setup RX queue: %s\n",
+				rte_strerror(-ret));
 	} else {
 		socket_id = txring_numa[res->portid];
 		if (!numa_support || socket_id == NUMA_NO_CONFIG)
@@ -3109,7 +3110,8 @@ cmd_setup_rxtx_queue_parsed(
 					     socket_id,
 					     &port->txq[res->qid].conf);
 		if (ret)
-			fprintf(stderr, "Failed to setup TX queue\n");
+			fprintf(stderr, "Failed to setup TX queue: %s\n",
+				rte_strerror(-ret));
 	}
 }
 
-- 
2.53.0


      parent reply	other threads:[~2026-07-02 16:13 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-07-02 13:07 [PATCH] app/testpmd: fix multi-pool Rx setup with --no-NUMA Maayan Kashani
2026-07-02 16:10 ` [PATCH 0/4] app/testpmd: fix socket id handling with NUMA disabled Stephen Hemminger
2026-07-02 16:10   ` [PATCH 1/4] app/testpmd: fix port socket ID " Stephen Hemminger
2026-07-02 16:10   ` [PATCH 2/4] app/testpmd: consolidate port socket ID computation Stephen Hemminger
2026-07-02 16:10   ` [PATCH 3/4] app/testpmd: display any socket ID as text Stephen Hemminger
2026-07-02 16:10   ` Stephen Hemminger [this message]

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=20260702161244.363233-5-stephen@networkplumber.org \
    --to=stephen@networkplumber.org \
    --cc=aman.deep.singh@intel.com \
    --cc=dev@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