DPDK patches and discussions
 help / color / mirror / Atom feed
From: Jerin Jacob <jerinjacobk@gmail.com>
To: David Marchand <david.marchand@redhat.com>
Cc: dev@dpdk.org, alosadag@redhat.com, stable@dpdk.org,
	 Jerin Jacob <jerinj@marvell.com>,
	Bruce Richardson <bruce.richardson@intel.com>
Subject: Re: [PATCH] test/event: skip test if no driver is present
Date: Thu, 1 Feb 2024 23:14:44 +0530	[thread overview]
Message-ID: <CALBAE1PTvkGLf1_Ew0Ue1o0yHRoKsuu3rxRXFeWt1HspJt1-8g@mail.gmail.com> (raw)
In-Reply-To: <20240124123338.551436-1-david.marchand@redhat.com>

On Wed, Jan 24, 2024 at 6:03 PM David Marchand
<david.marchand@redhat.com> wrote:
>
> Align eventdev with what other device abstraction libraries do: if no
> driver is present, skip the tests.
>
> Fixes: f8f9d233ea0e ("test/eventdev: add unit tests")
> Cc: stable@dpdk.org
>
> Signed-off-by: David Marchand <david.marchand@redhat.com>

Applied to dpdk-next-eventdev/for-main. Thanks


> ---
>  app/test/test_eventdev.c | 10 ++++++++--
>  1 file changed, 8 insertions(+), 2 deletions(-)
>
> diff --git a/app/test/test_eventdev.c b/app/test/test_eventdev.c
> index 71de947ce4..e4e234dc98 100644
> --- a/app/test/test_eventdev.c
> +++ b/app/test/test_eventdev.c
> @@ -33,9 +33,15 @@ testsuite_setup(void)
>         uint8_t count;
>         count = rte_event_dev_count();
>         if (!count) {
> +               int ret;
> +
>                 printf("Failed to find a valid event device,"
> -                       " testing with event_skeleton device\n");
> -               return rte_vdev_init("event_skeleton", NULL);
> +                       " trying with event_skeleton device\n");
> +               ret = rte_vdev_init("event_skeleton", NULL);
> +               if (ret != 0) {
> +                       printf("No event device, skipping\n");
> +                       return TEST_SKIPPED;
> +               }
>         }
>         return TEST_SUCCESS;
>  }
> --
> 2.43.0
>

      reply	other threads:[~2024-02-01 17:45 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-01-24 12:33 David Marchand
2024-02-01 17:44 ` Jerin Jacob [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=CALBAE1PTvkGLf1_Ew0Ue1o0yHRoKsuu3rxRXFeWt1HspJt1-8g@mail.gmail.com \
    --to=jerinjacobk@gmail.com \
    --cc=alosadag@redhat.com \
    --cc=bruce.richardson@intel.com \
    --cc=david.marchand@redhat.com \
    --cc=dev@dpdk.org \
    --cc=jerinj@marvell.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).