From: Bruce Richardson <bruce.richardson@intel.com>
To: dev@dpdk.org
Cc: Bruce Richardson <bruce.richardson@intel.com>,
Naga Harish K S V <s.v.naga.harish.k@intel.com>
Subject: [PATCH] test/event_eth_tx_adapter: skip tests if no eventdev
Date: Tue, 21 Jul 2026 12:56:35 +0100 [thread overview]
Message-ID: <20260721115635.2209399-1-bruce.richardson@intel.com> (raw)
If there is no eventdev present, and the SW eventdev driver is not
available, skip the eth tx adapter tests, rather than failing on event
creation.
Note: We keep the failure case where we do have the event/sw driver
built, but fail to create an instance of it.
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
---
app/test/test_event_eth_tx_adapter.c | 10 ++++++++--
1 file changed, 8 insertions(+), 2 deletions(-)
diff --git a/app/test/test_event_eth_tx_adapter.c b/app/test/test_event_eth_tx_adapter.c
index bec298a8b8..18801028ce 100644
--- a/app/test/test_event_eth_tx_adapter.c
+++ b/app/test/test_event_eth_tx_adapter.c
@@ -202,12 +202,13 @@ deinit_ports(void)
static int
testsuite_setup(void)
{
- const char *vdev_name = "event_sw0";
-
int err = init_ports();
TEST_ASSERT(err == 0, "Port initialization failed err %d\n", err);
+#ifdef RTE_EVENT_SW
if (rte_event_dev_count() == 0) {
+ const char *vdev_name = "event_sw0";
+
printf("Failed to find a valid event device,"
" testing with event_sw0 device\n");
err = rte_vdev_init(vdev_name, NULL);
@@ -215,6 +216,11 @@ testsuite_setup(void)
vdev_name, err);
event_dev_delete = 1;
}
+#endif
+ if (rte_event_dev_count() == 0) {
+ printf("Failed to find a valid event device, skipping test\n");
+ return TEST_SKIPPED;
+ }
return err;
}
--
2.53.0
next reply other threads:[~2026-07-21 11:56 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-07-21 11:56 Bruce Richardson [this message]
2026-07-21 12:07 ` [PATCH] test/event_eth_tx_adapter: skip tests if no eventdev David Marchand
2026-07-21 12:31 ` Bruce Richardson
2026-07-21 13:23 ` [PATCH v2] " Bruce Richardson
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=20260721115635.2209399-1-bruce.richardson@intel.com \
--to=bruce.richardson@intel.com \
--cc=dev@dpdk.org \
--cc=s.v.naga.harish.k@intel.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