Hi Fan, > This patch changes the experimental raw data path dequeue burst API. > Originally the API enforces the user to provide callback function > to get maximum dequeue count. This change gives the user one more > option to pass directly the expected dequeue count. > > Signed-off-by: Fan Zhang <roy.fan.zh...@intel.com> > --- > app/test/test_cryptodev.c | 8 +------- > doc/guides/rel_notes/release_21_05.rst | 3 +++ > drivers/crypto/qat/qat_sym_hw_dp.c | 21 ++++++++++++++++++--- > lib/librte_cryptodev/rte_cryptodev.c | 5 +++-- > lib/librte_cryptodev/rte_cryptodev.h | 8 ++++++++ > 5 files changed, 33 insertions(+), 12 deletions(-) > > diff --git a/app/test/test_cryptodev.c b/app/test/test_cryptodev.c > index f91debc168..a910547423 100644 > --- a/app/test/test_cryptodev.c > +++ b/app/test/test_cryptodev.c > @@ -162,12 +162,6 @@ ceil_byte_length(uint32_t num_bits) > return (num_bits >> 3); > } > > -static uint32_t > -get_raw_dp_dequeue_count(void *user_data __rte_unused) > -{ > - return 1; > -} > - > static void > post_process_raw_dp_op(void *user_data, uint32_t index __rte_unused, > uint8_t is_op_success) > @@ -345,7 +339,7 @@ process_sym_raw_dp_op(uint8_t dev_id, uint16_t > qp_id, > n = n_success = 0; > while (count++ < MAX_RAW_DEQUEUE_COUNT && n == 0) { > n = rte_cryptodev_raw_dequeue_burst(ctx, > - get_raw_dp_dequeue_count, > post_process_raw_dp_op, > + NULL, 1, post_process_raw_dp_op, > (void **)&ret_op, 0, &n_success, > &dequeue_status); > if (dequeue_status < 0) { > diff --git a/doc/guides/rel_notes/release_21_05.rst > b/doc/guides/rel_notes/release_21_05.rst > index 8e686cc627..943f1596c5 100644 > --- a/doc/guides/rel_notes/release_21_05.rst > +++ b/doc/guides/rel_notes/release_21_05.rst > @@ -130,6 +130,9 @@ API Changes > Also, make sure to start the actual text at the margin. > ======================================================= > > +* cryptodev: the function ``rte_cryptodev_raw_dequeue_burst`` is added a > + parameter ``max_nb_to_dequeue`` to give user a more flexible dequeue > control. > +
Shouldn't we remove the callback completely? What is the use case of having 2 different methods of passing a Simple dequeue count? Why do we need such flexibility? Regards, Akhil