From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by dpdk.org (Postfix) with ESMTP id E5D7929AC for ; Fri, 20 Jul 2018 19:19:20 +0200 (CEST) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga005.fm.intel.com ([10.253.24.32]) by fmsmga102.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 20 Jul 2018 10:19:19 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.51,380,1526367600"; d="scan'208";a="246972147" Received: from irsmsx153.ger.corp.intel.com ([163.33.192.75]) by fmsmga005.fm.intel.com with ESMTP; 20 Jul 2018 10:19:18 -0700 Received: from irsmsx107.ger.corp.intel.com ([169.254.10.193]) by IRSMSX153.ger.corp.intel.com ([169.254.9.210]) with mapi id 14.03.0319.002; Fri, 20 Jul 2018 18:19:18 +0100 From: "De Lara Guarch, Pablo" To: "Trahe, Fiona" , "dev@dpdk.org" CC: "Jozwiak, TomaszX" Thread-Topic: [PATCH 1/2] common/qat: add sgl header Thread-Index: AQHUHfd9UrnXB+TYhEmDhU3jLGIz46SYXWpA Date: Fri, 20 Jul 2018 17:19:17 +0000 Message-ID: References: <1531850150-21767-1-git-send-email-fiona.trahe@intel.com> In-Reply-To: <1531850150-21767-1-git-send-email-fiona.trahe@intel.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-titus-metadata-40: eyJDYXRlZ29yeUxhYmVscyI6IiIsIk1ldGFkYXRhIjp7Im5zIjoiaHR0cDpcL1wvd3d3LnRpdHVzLmNvbVwvbnNcL0ludGVsMyIsImlkIjoiMGE2ZmEzZjYtYzA5Yy00N2JhLWJhMTYtNmYwNWViN2Y4ZjZkIiwicHJvcHMiOlt7Im4iOiJDVFBDbGFzc2lmaWNhdGlvbiIsInZhbHMiOlt7InZhbHVlIjoiQ1RQX05UIn1dfV19LCJTdWJqZWN0TGFiZWxzIjpbXSwiVE1DVmVyc2lvbiI6IjE3LjEwLjE4MDQuNDkiLCJUcnVzdGVkTGFiZWxIYXNoIjoiQjJoaWF3VGhmZmRuXC9qcm9BMXpQN1F2aWhFdUJQTTlJKytuQ2ZrXC9GMzV4eDlxUkt2Q0YzUnU2elJiQTRTaHVQIn0= x-ctpclassification: CTP_NT dlp-product: dlpe-windows dlp-version: 11.0.200.100 dlp-reaction: no-action x-originating-ip: [163.33.239.182] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Subject: Re: [dpdk-dev] [PATCH 1/2] common/qat: add sgl header 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: Fri, 20 Jul 2018 17:19:21 -0000 > -----Original Message----- > From: Trahe, Fiona > Sent: Tuesday, July 17, 2018 6:56 PM > To: dev@dpdk.org > Cc: De Lara Guarch, Pablo ; Trahe, Fiona > ; Jozwiak, TomaszX > Subject: [PATCH 1/2] common/qat: add sgl header >=20 > This patch refactors the sgl struct so it includes a flexible array of fl= at buffers as > sym and compress PMDs can have different size sgls. >=20 > Signed-off-by: Tomasz Jozwiak > Signed-off-by: Fiona Trahe > --- > drivers/common/qat/qat_common.c | 53 ++++++++++++++++++++++++++++++- > ---------- > drivers/common/qat/qat_common.h | 23 ++++++++++-------- > drivers/crypto/qat/qat_sym.c | 12 ++++++---- > drivers/crypto/qat/qat_sym.h | 14 +++++++++-- > 4 files changed, 71 insertions(+), 31 deletions(-) >=20 > diff --git a/drivers/common/qat/qat_common.c > b/drivers/common/qat/qat_common.c index c206d3b..c25372d 100644 > --- a/drivers/common/qat/qat_common.c > +++ b/drivers/common/qat/qat_common.c > @@ -8,40 +8,53 @@ >=20 > int > qat_sgl_fill_array(struct rte_mbuf *buf, uint64_t buf_start, > - struct qat_sgl *list, uint32_t data_len) > + void *list_in, uint32_t data_len, > + const int32_t max_segs) This should be "uint16_t max_segs". ... > +sgl_end: > +#if RTE_LOG_DP_LEVEL >=3D RTE_LOG_DEBUG > + QAT_DP_LOG(INFO, "SGL with %d buffers:", list->num_bufs); > + for (uint8_t i =3D 0; i < list->num_bufs; i++) { I think declaring a variable inside the for statement is not allowed in som= e compilers? > + QAT_DP_LOG(INFO, "QAT SGL buf %d, len =3D %d, iova =3D > 0x%012lx", > + i, list->buffers[i].len, > + list->buffers[i].addr); > + QAT_DP_HEXDUMP_LOG(DEBUG, "qat SGL", > + virt_addr[i], list->buffers[i].len); > + } > +#endif > + > return 0;