From: Maxime Coquelin <maxime.coquelin@redhat.com>
To: Nicolas Chautru <nicolas.chautru@intel.com>, dev@dpdk.org
Cc: hernan.vargas@intel.com, Vipin.Varghese@amd.com
Subject: Re: [PATCH v2 3/3] test/bbdev: explicit check for allocation failure
Date: Wed, 7 Dec 2022 09:40:29 +0100 [thread overview]
Message-ID: <2bdb6439-4fbd-9643-2f16-4eb750e7bf14@redhat.com> (raw)
In-Reply-To: <20221206191441.12428-4-nicolas.chautru@intel.com>
On 12/6/22 20:14, Nicolas Chautru wrote:
> Adding check for error on return of the
> rte_bbdev_*_op_alloc_bulk calls in bbdev-test.
>
> Signed-off-by: Nicolas Chautru <nicolas.chautru@intel.com>
> ---
> app/test-bbdev/test_bbdev_perf.c | 9 ++++++---
> 1 file changed, 6 insertions(+), 3 deletions(-)
>
> diff --git a/app/test-bbdev/test_bbdev_perf.c b/app/test-bbdev/test_bbdev_perf.c
> index b2e536b5e3..a922d69ada 100644
> --- a/app/test-bbdev/test_bbdev_perf.c
> +++ b/app/test-bbdev/test_bbdev_perf.c
> @@ -4958,7 +4958,8 @@ offload_latency_test_fft(struct rte_mempool *mempool, struct test_buffers *bufs,
> if (unlikely(num_to_process - dequeued < burst_sz))
> burst_sz = num_to_process - dequeued;
>
> - rte_bbdev_fft_op_alloc_bulk(mempool, ops_enq, burst_sz);
> + ret = rte_bbdev_fft_op_alloc_bulk(mempool, ops_enq, burst_sz);
> + TEST_ASSERT_SUCCESS(ret, "Allocation failed for %d ops", ops_enq);
> if (test_vector.op_type != RTE_BBDEV_OP_NONE)
> copy_reference_fft_op(ops_enq, burst_sz, dequeued,
> bufs->inputs,
> @@ -5040,7 +5041,8 @@ offload_latency_test_dec(struct rte_mempool *mempool, struct test_buffers *bufs,
> if (unlikely(num_to_process - dequeued < burst_sz))
> burst_sz = num_to_process - dequeued;
>
> - rte_bbdev_dec_op_alloc_bulk(mempool, ops_enq, burst_sz);
> + ret = rte_bbdev_dec_op_alloc_bulk(mempool, ops_enq, burst_sz);
> + TEST_ASSERT_SUCCESS(ret, "Allocation failed for %d ops", ops_enq);
> if (test_vector.op_type != RTE_BBDEV_OP_NONE)
> copy_reference_dec_op(ops_enq, burst_sz, dequeued,
> bufs->inputs,
> @@ -5125,7 +5127,8 @@ offload_latency_test_ldpc_dec(struct rte_mempool *mempool,
> if (unlikely(num_to_process - dequeued < burst_sz))
> burst_sz = num_to_process - dequeued;
>
> - rte_bbdev_dec_op_alloc_bulk(mempool, ops_enq, burst_sz);
> + ret = rte_bbdev_dec_op_alloc_bulk(mempool, ops_enq, burst_sz);
> + TEST_ASSERT_SUCCESS(ret, "Allocation failed for %d ops", ops_enq);
> if (test_vector.op_type != RTE_BBDEV_OP_NONE)
> copy_reference_ldpc_dec_op(ops_enq, burst_sz, dequeued,
> bufs->inputs,
You need to add Fixes tag and cc stable.
Maxime
next prev parent reply other threads:[~2022-12-07 8:40 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-12-06 19:14 [PATCH v2 0/3] test/bbdev: fix build issues with optional build flag Nicolas Chautru
2022-12-06 19:14 ` [PATCH v2 1/3] test/bbdev: fix build issue " Nicolas Chautru
2022-12-07 8:38 ` Maxime Coquelin
2022-12-06 19:14 ` [PATCH v2 2/3] " Nicolas Chautru
2022-12-07 8:39 ` Maxime Coquelin
2022-12-06 19:14 ` [PATCH v2 3/3] test/bbdev: explicit check for allocation failure Nicolas Chautru
2022-12-07 8:40 ` Maxime Coquelin [this message]
2022-12-07 15:33 ` Chautru, Nicolas
2022-12-09 10:35 ` Maxime Coquelin
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=2bdb6439-4fbd-9643-2f16-4eb750e7bf14@redhat.com \
--to=maxime.coquelin@redhat.com \
--cc=Vipin.Varghese@amd.com \
--cc=dev@dpdk.org \
--cc=hernan.vargas@intel.com \
--cc=nicolas.chautru@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;
as well as URLs for NNTP newsgroup(s).