DPDK patches and discussions
 help / color / mirror / Atom feed
From: Nicolas Chautru <nicolas.chautru@intel.com>
To: dev@dpdk.org, maxime.coquelin@redhat.com
Cc: hemant.agrawal@nxp.com, hernan.vargas@intel.com,
	Nicolas Chautru <nicolas.chautru@intel.com>
Subject: [PATCH v1 1/2] app/bbdev: add capture of queue dump
Date: Fri, 25 Oct 2024 10:57:08 -0700	[thread overview]
Message-ID: <20241025175709.1415722-2-nicolas.chautru@intel.com> (raw)
In-Reply-To: <20241025175709.1415722-1-nicolas.chautru@intel.com>

Capturing additional queue dump information in the
bbdev-test application using the api introduced earlier.

Signed-off-by: Nicolas Chautru <nicolas.chautru@intel.com>
---
 app/test-bbdev/test_bbdev_perf.c | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)

diff --git a/app/test-bbdev/test_bbdev_perf.c b/app/test-bbdev/test_bbdev_perf.c
index 9be360b225..405c22de44 100644
--- a/app/test-bbdev/test_bbdev_perf.c
+++ b/app/test-bbdev/test_bbdev_perf.c
@@ -111,6 +111,8 @@ static uint32_t ldpc_cap_flags;
 /* FFT window width predefined on device and on vector. */
 static int fft_window_width_dev;
 
+bool dump_ops = true;
+
 /* Represents tested active devices */
 static struct active_device {
 	const char *driver_name;
@@ -3109,6 +3111,20 @@ run_test_case_on_device(test_case_function *test_case_func, uint8_t dev_id,
 	/* Run test case function */
 	t_ret = test_case_func(ad, op_params);
 
+	if (dump_ops) {
+		/* Dump queue information in local file. */
+		static FILE *fd;
+		fd = fopen("./dump_bbdev_queue_ops.txt", "w");
+		if (fd == NULL) {
+			printf("Open dump file error.\n");
+			return -1;
+		}
+		rte_bbdev_queue_ops_dump(ad->dev_id, ad->queue_ids[i], fd);
+		fclose(fd);
+		/* Run it once only. */
+		dump_ops = false;
+	}
+
 	/* Free active device resources and return */
 	free_buffers(ad, op_params);
 	return t_ret;
-- 
2.34.1


  reply	other threads:[~2024-10-25 17:57 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-10-25 17:57 [PATCH v1 0/2] app/bbdev: minor application updates Nicolas Chautru
2024-10-25 17:57 ` Nicolas Chautru [this message]
2024-10-25 17:57 ` [PATCH v1 2/2] app/bbdev: add support for interrupt disable Nicolas Chautru

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=20241025175709.1415722-2-nicolas.chautru@intel.com \
    --to=nicolas.chautru@intel.com \
    --cc=dev@dpdk.org \
    --cc=hemant.agrawal@nxp.com \
    --cc=hernan.vargas@intel.com \
    --cc=maxime.coquelin@redhat.com \
    /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).