From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: <fiona.trahe@intel.com> Received: from mga12.intel.com (mga12.intel.com [192.55.52.136]) by dpdk.org (Postfix) with ESMTP id 001D81C01 for <dev@dpdk.org>; Mon, 29 Oct 2018 18:29:40 +0100 (CET) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga005.jf.intel.com ([10.7.209.41]) by fmsmga106.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 29 Oct 2018 10:29:39 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.54,441,1534834800"; d="scan'208";a="269746030" Received: from irsmsx108.ger.corp.intel.com ([163.33.3.3]) by orsmga005.jf.intel.com with ESMTP; 29 Oct 2018 10:29:38 -0700 Received: from irsmsx101.ger.corp.intel.com ([169.254.1.134]) by IRSMSX108.ger.corp.intel.com ([169.254.11.101]) with mapi id 14.03.0415.000; Mon, 29 Oct 2018 17:29:37 +0000 From: "Trahe, Fiona" <fiona.trahe@intel.com> To: Jerin Jacob <jerin.jacob@caviumnetworks.com>, "dev@dpdk.org" <dev@dpdk.org>, "Gupta, Ashish" <Ashish.Gupta@cavium.com> CC: "thomas@monjalon.net" <thomas@monjalon.net>, "Jacob, Jerin" <Jerin.JacobKollanukkaran@cavium.com>, "Trahe, Fiona" <fiona.trahe@intel.com> Thread-Topic: [dpdk-dev] [PATCH] compress/qat: fix build issue with clang 7.0.0 Thread-Index: AQHUbhTcptk0MRX4tECMgUqnhOhFc6U2fFqA Date: Mon, 29 Oct 2018 17:29:36 +0000 Message-ID: <348A99DA5F5B7549AA880327E580B43589667138@IRSMSX101.ger.corp.intel.com> References: <20181027164739.13110-1-jerin.jacob@caviumnetworks.com> In-Reply-To: <20181027164739.13110-1-jerin.jacob@caviumnetworks.com> Accept-Language: en-IE, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiNGIwYmQyMzgtNzQzYy00MzllLTg5NjctMTAzNmU2YmYyYmNiIiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX05UIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE3LjEwLjE4MDQuNDkiLCJUcnVzdGVkTGFiZWxIYXNoIjoiTkw2NVpnNFJLZlwvZDY4WTZKb3hZSEJtUVFiYkxWdWd6djFrZ3JnZ2UwS2FMSTNGOVp4UlFhV2VINUhpbnZkTU4ifQ== x-ctpclassification: CTP_NT dlp-product: dlpe-windows dlp-version: 11.0.400.15 dlp-reaction: no-action x-originating-ip: [163.33.239.180] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Subject: Re: [dpdk-dev] [PATCH] compress/qat: fix build issue with clang 7.0.0 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions <dev.dpdk.org> List-Unsubscribe: <https://mails.dpdk.org/options/dev>, <mailto:dev-request@dpdk.org?subject=unsubscribe> List-Archive: <http://mails.dpdk.org/archives/dev/> List-Post: <mailto:dev@dpdk.org> List-Help: <mailto:dev-request@dpdk.org?subject=help> List-Subscribe: <https://mails.dpdk.org/listinfo/dev>, <mailto:dev-request@dpdk.org?subject=subscribe> X-List-Received-Date: Mon, 29 Oct 2018 17:29:41 -0000 Hi Jerin, > -----Original Message----- > From: Jerin Jacob [mailto:jerin.jacob@caviumnetworks.com] > Sent: Saturday, October 27, 2018 9:48 AM > To: dev@dpdk.org; Trahe, Fiona <fiona.trahe@intel.com>; De Lara Guarch, P= ablo > <pablo.de.lara.guarch@intel.com>; Gupta, Ashish <Ashish.Gupta@cavium.com> > Cc: thomas@monjalon.net; Jacob, Jerin <Jerin.JacobKollanukkaran@cavium.co= m> > Subject: [dpdk-dev] [PATCH] compress/qat: fix build issue with clang 7.0.= 0 >=20 > QAT_NUM_BUFS_IN_IM_SGL defined as 1 the code access beyond > the first element. >=20 > error log: > /export/dpdk.org/drivers/compress/qat/qat_comp_pmd.c:214:3: > error: array index 1 is past the end of the array > (which contains 1 element) [-Werror,-Warray-bounds] > sgl->buffers[1].addr =3D mz_start_phys + offset_of_flat_buffs + >=20 > Fixes: a124830a6f00 ("compress/qat: enable dynamic huffman encoding") >=20 > Signed-off-by: Jerin Jacob <jerin.jacob@caviumnetworks.com> > --- > drivers/compress/qat/qat_comp.h | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) >=20 > diff --git a/drivers/compress/qat/qat_comp.h b/drivers/compress/qat/qat_c= omp.h > index 99a4462eb..24d0d9cb4 100644 > --- a/drivers/compress/qat/qat_comp.h > +++ b/drivers/compress/qat/qat_comp.h > @@ -17,7 +17,7 @@ >=20 > #define QAT_64_BYTE_ALIGN_MASK (~0x3f) > #define QAT_64_BYTE_ALIGN (64) > -#define QAT_NUM_BUFS_IN_IM_SGL 1 > +#define QAT_NUM_BUFS_IN_IM_SGL 2 [Fiona] Thanks for this. I'm surprised gcc didn't give a warning. However, setting to 2 causes issues on some platforms, which=20 was why we reverted to 1 in an earlier iteration. So Nack I'll send a different patch to fix. >=20 > #define ERR_CODE_QAT_COMP_WRONG_FW -99 >=20 > -- > 2.19.1