Hi all, I'm preparing the patch and will send it in 10 minutes
Thx, Tomek > -----Original Message----- > From: Thomas Monjalon [mailto:tho...@monjalon.net] > Sent: Friday, April 19, 2019 11:30 AM > To: David Marchand <david.march...@redhat.com> > Cc: Cel, TomaszX <tomaszx....@intel.com>; Jozwiak, TomaszX > <tomaszx.jozw...@intel.com>; Yongseok Koh <ys...@mellanox.com>; > dev@dpdk.org; Trahe, Fiona <fiona.tr...@intel.com>; Yigit, Ferruh > <ferruh.yi...@intel.com> > Subject: Re: [dpdk-dev] [PATCH v2 1/1] test/compress: add max mbuf size > test case > > 19/04/2019 11:25, David Marchand: > > On Fri, Apr 19, 2019 at 11:08 AM Thomas Monjalon > <tho...@monjalon.net> > > wrote: > > > > > There are some variables declared in the middle of the function, and > > > one (i) is declared twice with two different types. > > > > > > Tomasz and Tomasz, are you working on it urgently please? > > > > > > > Found out that this test is not built by default. > > I have a trivial fix but I wonder how this has been tested seeing how > > it won't compile. > > It is enabled with devtools/test-build.sh and it is compiling fine with recent > compilers I think. > > Please send your fix. > > > > > 19/04/2019 00:42, Yongseok Koh: > > > > Hi, > > > > > > > > I'm seeing compile error. > > > > Isn't it due to this patch? > > > > > > > > $ gcc --version > > > > gcc (GCC) 4.8.5 20150623 (Red Hat 4.8.5-28) > > > > > > > > > > > > FAILED: app/test/app@test@@dpdk-test@exe/test_compressdev.c.o > > > [...] > > > > ../app/test/test_compressdev.c: In function > > > ‘test_compressdev_deflate_stateless_dynamic_big’: > > > > ../app/test/test_compressdev.c:1992:16: error: conflicting types for ‘i’ > > > > for (uint32_t i = 0; i < BIG_DATA_TEST_SIZE - 1; ++i) > > > > ^ > > > > ../app/test/test_compressdev.c:1949:11: note: previous definition of ‘i’ > > > was here > > > > uint16_t i = 0; > > > > ^ > > > > ../app/test/test_compressdev.c:1992:2: error: ‘for’ loop initial > > > declarations are only allowed in C99 mode > > > > for (uint32_t i = 0; i < BIG_DATA_TEST_SIZE - 1; ++i) > > > > ^ > > > > ../app/test/test_compressdev.c:1992:2: note: use option -std=c99 > > > > or > > > -std=gnu99 to compile your code > > > > ../app/test/test_compressdev.c:1996:19: warning: assignment from > > > incompatible pointer type [enabled by default] > > > > int_data.buf_idx = &i; > > > > ^ > > > > [1501/1523] Generating igb_uio with a custom command. > > > > make: Entering directory `/usr/src/kernels/3.10.0-862.el7.x86_64' > > > > CC [M] > > > /auto/mtiswgwork/yskoh/git/mellanox/dpdk.org-2/build/kernel/linux/ig > > > b_uio/igb_uio.o > > > > Building modules, stage 2. > > > > MODPOST 1 modules > > > > make[1]: Warning: File > > > `/auto/mtiswgwork/yskoh/git/mellanox/dpdk.org- > 2/build/kernel/linux/igb_uio/igb_uio.mod.c' > > > has modification time 0.0096 s in the future > > > > CC > > > /auto/mtiswgwork/yskoh/git/mellanox/dpdk.org-2/build/kernel/linux/ig > > > b_uio/igb_uio.mod.o > > > > LD [M] > > > /auto/mtiswgwork/yskoh/git/mellanox/dpdk.org-2/build/kernel/linux/ig > > > b_uio/igb_uio.ko > > > > make[1]: warning: Clock skew detected. Your build may be > incomplete. > > > > make: Leaving directory `/usr/src/kernels/3.10.0-862.el7.x86_64' > > > > > > > > > > > > Thanks, > > > > Yongseok > > > > > > [...] > > > > >> +static int > > > > >> +test_compressdev_deflate_stateless_dynamic_big(void) > > > > >> +{ > > > > >> + struct comp_testsuite_params *ts_params = &testsuite_params; > > > > >> + uint16_t i = 0; > > > > >> + int ret = TEST_SUCCESS; > > > > >> + const struct rte_compressdev_capabilities *capab; > > > > >> + char *test_buffer = NULL; > > > > >> + > > > > >> + capab = rte_compressdev_capability_get(0, > > > > >> RTE_COMP_ALGO_DEFLATE); > > > > >> + TEST_ASSERT(capab != NULL, "Failed to retrieve device > > > capabilities"); > > > > >> + > > > > >> + if ((capab->comp_feature_flags & > > > > >> RTE_COMP_FF_HUFFMAN_DYNAMIC) == 0) > > > > >> + return -ENOTSUP; > > > > >> + > > > > >> + if ((capab->comp_feature_flags & > > > > >> RTE_COMP_FF_OOP_SGL_IN_SGL_OUT) == 0) > > > > >> + return -ENOTSUP; > > > > >> + > > > > >> + test_buffer = rte_malloc(NULL, BIG_DATA_TEST_SIZE, 0); if > > > > >> + (test_buffer == NULL) { > > > > >> + RTE_LOG(ERR, USER1, > > > > >> + "Can't allocate buffer for big-data\n"); > > > > >> + return TEST_FAILED; > > > > >> + } > > > > >> + > > > > >> + struct interim_data_params int_data = { > > > > >> + (const char * const *)&test_buffer, > > > > >> + 1, > > > > >> + NULL, > > > > >> + &ts_params->def_comp_xform, > > > > >> + &ts_params->def_decomp_xform, > > > > >> + 1 > > > > >> + }; > > > > >> + > > > > >> + struct test_data_params test_data = { > > > > >> + RTE_COMP_OP_STATELESS, > > > > >> + SGL_BOTH, > > > > >> + ZLIB_DECOMPRESS, > > > > >> + 0, > > > > >> + 1 > > > > >> + }; > > > > >> + > > > > >> + ts_params->def_comp_xform->compress.deflate.huffman = > > > > >> + > > > > >> RTE_COMP_HUFFMAN_DYNAMIC; > > > > >> + > > > > >> + /* fill the buffer with data based on rand. data */ > > > > >> + srand(BIG_DATA_TEST_SIZE); for (uint32_t i = 0; i < > > > > >> + BIG_DATA_TEST_SIZE - 1; ++i) > > > > >> + test_buffer[i] = (uint8_t)(rand() % ((uint8_t)-1)) | > > > > >> + 1; > > > > >> + > > > > >> + test_buffer[BIG_DATA_TEST_SIZE-1] = 0; int_data.buf_idx = > > > > >> + &i; > > > > > > > > > > > > > > > > > >