From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga12.intel.com (mga12.intel.com [192.55.52.136]) by dpdk.org (Postfix) with ESMTP id 001D81C01 for ; 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" To: Jerin Jacob , "dev@dpdk.org" , "Gupta, Ashish" CC: "thomas@monjalon.net" , "Jacob, Jerin" , "Trahe, Fiona" 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 List-Unsubscribe: , List-Archive: List-Post: List-Help: List-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 ; De Lara Guarch, P= ablo > ; Gupta, Ashish > Cc: thomas@monjalon.net; Jacob, Jerin > 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 > --- > 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