From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by dpdk.space (Postfix) with ESMTP id 74EEAA00E6 for ; Fri, 19 Apr 2019 11:25:34 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 3D3FC1BA92; Fri, 19 Apr 2019 11:25:33 +0200 (CEST) Received: from mail-ua1-f66.google.com (mail-ua1-f66.google.com [209.85.222.66]) by dpdk.org (Postfix) with ESMTP id E791D1BA90 for ; Fri, 19 Apr 2019 11:25:31 +0200 (CEST) Received: by mail-ua1-f66.google.com with SMTP id p13so1598839uaa.11 for ; Fri, 19 Apr 2019 02:25:31 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=rMD6UiMDABU0DnK+7OTpZTmON+UUjMVyt54qKnw3yRk=; b=RkFQKWiNyflcRvF0rR9yPprLpAhmcdGaZncLYuGPE/HuEBStfERekSrMDBgvJhuNm+ sxoXoQU5t4ynVo4EG9ITkDKf4UYRPvVUUi9CHHPCjGVAjqG7Z/V676FvCSvRLCbhLYr4 3C/WQSaLGTb8uZomHBx4cH7vIRMFUUZNP66vsH46YuGBbo2jVNwSszT+PENfF6dAksup sy8EY4dJ901vEusFbPjOkJ5hlquKz4WIPeKNW+SBBaud9ri4kWu2p7zhIoqHxKLh9av1 EvP7uuK/IxU5RMALHZGatPAAcd5R15TApfW5s+Jx1ZT8e/1p9nkDZrd2bdkf3shyj1jM 5B5w== X-Gm-Message-State: APjAAAVYSizQAqpFBgkVRLh5ln2sfmGYjsdpkJp/vx5NQ8Pfv4c25Idu iCQCQZ4fZRJgGn0HdPnq8sNtRLqraA1P/5OHnM5xHg== X-Google-Smtp-Source: APXvYqxDcnwyNPMgtEieZ0cz0oMvWRfHcm3SXgMIMCTG26ZKtobVH7WrecQbWm7muag4d6nLSTem1wsiYL43Q3KbyhA= X-Received: by 2002:ab0:6419:: with SMTP id x25mr1506767uao.86.1555665931061; Fri, 19 Apr 2019 02:25:31 -0700 (PDT) MIME-Version: 1.0 References: <1550223873-17119-3-git-send-email-tomaszx.jozwiak@intel.com> <825F643C-86B8-4A5D-934A-E074DE1458C1@mellanox.com> <2973149.5co8HxeFWj@xps> In-Reply-To: <2973149.5co8HxeFWj@xps> From: David Marchand Date: Fri, 19 Apr 2019 11:25:19 +0200 Message-ID: To: Thomas Monjalon Cc: "Cel, TomaszX" , "Jozwiak, TomaszX" , Yongseok Koh , "dev@dpdk.org" , "Trahe, Fiona" , "Yigit, Ferruh" Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Content-Filtered-By: Mailman/MimeDel 2.1.15 Subject: Re: [dpdk-dev] [PATCH v2 1/1] test/compress: add max mbuf size test case X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" Message-ID: <20190419092519.vRDLjZ0jcFlt37ZK5DbT7JyXN6NIK2Q4oVgnLNqliUQ@z> On Fri, Apr 19, 2019 at 11:08 AM Thomas Monjalon 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. --=20 David Marchand > > 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 > =E2=80=98test_compressdev_deflate_stateless_dynamic_big=E2=80=99: > > ../app/test/test_compressdev.c:1992:16: error: conflicting types for = =E2=80=98i=E2=80=99 > > for (uint32_t i =3D 0; i < BIG_DATA_TEST_SIZE - 1; ++i) > > ^ > > ../app/test/test_compressdev.c:1949:11: note: previous definition of = =E2=80=98i=E2=80=99 > was here > > uint16_t i =3D 0; > > ^ > > ../app/test/test_compressdev.c:1992:2: error: =E2=80=98for=E2=80=99 loo= p initial > declarations are only allowed in C99 mode > > for (uint32_t i =3D 0; i < BIG_DATA_TEST_SIZE - 1; ++i) > > ^ > > ../app/test/test_compressdev.c:1992:2: note: use option -std=3Dc99 or > -std=3Dgnu99 to compile your code > > ../app/test/test_compressdev.c:1996:19: warning: assignment from > incompatible pointer type [enabled by default] > > int_data.buf_idx =3D &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/igb_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_ui= o/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/igb_uio= /igb_uio.mod.o > > LD [M] > /auto/mtiswgwork/yskoh/git/mellanox/dpdk.org-2/build/kernel/linux/igb_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 =3D &testsuite_params; > > >> + uint16_t i =3D 0; > > >> + int ret =3D TEST_SUCCESS; > > >> + const struct rte_compressdev_capabilities *capab; > > >> + char *test_buffer =3D NULL; > > >> + > > >> + capab =3D rte_compressdev_capability_get(0, > > >> RTE_COMP_ALGO_DEFLATE); > > >> + TEST_ASSERT(capab !=3D NULL, "Failed to retrieve device > capabilities"); > > >> + > > >> + if ((capab->comp_feature_flags & > > >> RTE_COMP_FF_HUFFMAN_DYNAMIC) =3D=3D 0) > > >> + return -ENOTSUP; > > >> + > > >> + if ((capab->comp_feature_flags & > > >> RTE_COMP_FF_OOP_SGL_IN_SGL_OUT) =3D=3D 0) > > >> + return -ENOTSUP; > > >> + > > >> + test_buffer =3D rte_malloc(NULL, BIG_DATA_TEST_SIZE, 0); > > >> + if (test_buffer =3D=3D NULL) { > > >> + RTE_LOG(ERR, USER1, > > >> + "Can't allocate buffer for big-data\n"); > > >> + return TEST_FAILED; > > >> + } > > >> + > > >> + struct interim_data_params int_data =3D { > > >> + (const char * const *)&test_buffer, > > >> + 1, > > >> + NULL, > > >> + &ts_params->def_comp_xform, > > >> + &ts_params->def_decomp_xform, > > >> + 1 > > >> + }; > > >> + > > >> + struct test_data_params test_data =3D { > > >> + RTE_COMP_OP_STATELESS, > > >> + SGL_BOTH, > > >> + ZLIB_DECOMPRESS, > > >> + 0, > > >> + 1 > > >> + }; > > >> + > > >> + ts_params->def_comp_xform->compress.deflate.huffman =3D > > >> + > > >> RTE_COMP_HUFFMAN_DYNAMIC; > > >> + > > >> + /* fill the buffer with data based on rand. data */ > > >> + srand(BIG_DATA_TEST_SIZE); > > >> + for (uint32_t i =3D 0; i < BIG_DATA_TEST_SIZE - 1; ++i) > > >> + test_buffer[i] =3D (uint8_t)(rand() % ((uint8_t)-1)) | 1; > > >> + > > >> + test_buffer[BIG_DATA_TEST_SIZE-1] =3D 0; > > >> + int_data.buf_idx =3D &i; > > > >