Hi Pablo, Feedback for a small change below. > -----Original Message----- > From: dev [mailto:dev-boun...@dpdk.org] On Behalf Of Pablo de Lara > Sent: Friday, April 27, 2018 3:15 PM > To: dev@dpdk.org > Cc: Trahe, Fiona <fiona.tr...@intel.com>; shally.ve...@cavium.com; > ahmed.mans...@nxp.com; ashish.gu...@cavium.com; De Lara Guarch, > Pablo <pablo.de.lara.gua...@intel.com> > Subject: [dpdk-dev] [PATCH v3 4/5] test/compress: add multi xform test > > Add test that checks if multiple xforms can be handled on a single enqueue > call. > > Signed-off-by: Pablo de Lara <pablo.de.lara.gua...@intel.com> > --- > test/test/test_compressdev.c | 257 > ++++++++++++++++++++++++++++++++----------- > 1 file changed, 191 insertions(+), 66 deletions(-) > > diff --git a/test/test/test_compressdev.c b/test/test/test_compressdev.c > index bb026d74f..0253d12ea 100644 > --- a/test/test/test_compressdev.c > +++ b/test/test/test_compressdev.c > @@ -27,7 +27,7 @@ > #define COMPRESS_BUF_SIZE_RATIO 1.3 > #define NUM_MBUFS 16 > #define NUM_OPS 16 > -#define NUM_MAX_XFORMS 1 > +#define NUM_MAX_XFORMS 16 > #define NUM_MAX_INFLIGHT_OPS 128 > #define CACHE_SIZE 0 > > @@ -52,8 +52,8 @@ struct priv_op_data { > struct comp_testsuite_params { > struct rte_mempool *mbuf_pool; > struct rte_mempool *op_pool; > - struct rte_comp_xform def_comp_xform; > - struct rte_comp_xform def_decomp_xform; > + struct rte_comp_xform *def_comp_xform; > + struct rte_comp_xform *def_decomp_xform; > }; > > static struct comp_testsuite_params testsuite_params = { 0 }; @@ -65,6 > +65,8 @@ testsuite_teardown(void) > > rte_mempool_free(ts_params->mbuf_pool); > rte_mempool_free(ts_params->op_pool); > + rte_free(ts_params->def_comp_xform); > + rte_free(ts_params->def_decomp_xform); > } > > static int > @@ -108,19 +110,24 @@ testsuite_setup(void) > goto exit; > } > > + ts_params->def_comp_xform = > + rte_malloc(NULL, sizeof(struct rte_comp_xform), 0); > + ts_params->def_decomp_xform = > + rte_malloc(NULL, sizeof(struct rte_comp_xform), 0); > +
Perhaps add a check to ensure this memory has been successfully allocated, as you did you with the mempool malloc above this, in PATCH 1/5. <...>