DPDK patches and discussions
 help / color / mirror / Atom feed
From: "Verma, Shally" <Shally.Verma@cavium.com>
To: "De Lara Guarch, Pablo" <pablo.de.lara.guarch@intel.com>,
	"Gupta, Ashish" <Ashish.Gupta@cavium.com>
Cc: "dev@dpdk.org" <dev@dpdk.org>,
	"Athreya, Narayana Prasad" <NarayanaPrasad.Athreya@cavium.com>,
	"Challa, Mahipal" <Mahipal.Challa@cavium.com>,
	"Sahu, Sunila" <Sunila.Sahu@cavium.com>
Subject: Re: [dpdk-dev] [PATCH v3 4/6] compress/octeontx: add ops enq deq apis
Date: Tue, 24 Jul 2018 08:22:04 +0000	[thread overview]
Message-ID: <CY4PR0701MB3634075A26A4C5ADD72E958EF0550@CY4PR0701MB3634.namprd07.prod.outlook.com> (raw)
In-Reply-To: <E115CCD9D858EF4F90C690B0DCB4D8977F8FFCF7@IRSMSX107.ger.corp.intel.com>



>-----Original Message-----
>From: De Lara Guarch, Pablo <pablo.de.lara.guarch@intel.com>
>Sent: 24 July 2018 04:11
>To: Gupta, Ashish <Ashish.Gupta@cavium.com>
>Cc: dev@dpdk.org; Athreya, Narayana Prasad <NarayanaPrasad.Athreya@cavium.com>; Challa, Mahipal
><Mahipal.Challa@cavium.com>; Verma, Shally <Shally.Verma@cavium.com>; Sahu, Sunila <Sunila.Sahu@cavium.com>
>Subject: RE: [PATCH v3 4/6] compress/octeontx: add ops enq deq apis
>
>External Email
>
>Hi Ashish,
>
>
>> -----Original Message-----
>> From: Ashish Gupta [mailto:Ashish.Gupta@caviumnetworks.com]
>> Sent: Friday, July 20, 2018 8:05 PM
>> To: De Lara Guarch, Pablo <pablo.de.lara.guarch@intel.com>
>> Cc: dev@dpdk.org; narayanaprasad.athreya@cavium.com;
>> mahipal.challa@cavium.com; Ashish Gupta
>> <ashish.gupta@caviumnetworks.com>; Shally Verma
>> <shally.verma@caviumnetworks.com>; Sunila Sahu
>> <sunila.sahu@caviumnetworks.com>
>> Subject: [PATCH v3 4/6] compress/octeontx: add ops enq deq apis
>>
>> Add enqueue/dequeue APIs to perform compression/decompression operations
>>
>> Signed-off-by: Ashish Gupta <ashish.gupta@caviumnetworks.com>
>> Signed-off-by: Shally Verma <shally.verma@caviumnetworks.com>
>> Signed-off-by: Sunila Sahu <sunila.sahu@caviumnetworks.com>
>> ---
>>  drivers/compress/octeontx/otx_zip.c     |  49 +++++++++
>>  drivers/compress/octeontx/otx_zip.h     | 169
>> ++++++++++++++++++++++++++++++++
>>  drivers/compress/octeontx/otx_zip_pmd.c | 119 ++++++++++++++++++++++
>>  3 files changed, 337 insertions(+)
>>
>
>...
>
>>  int
>>  zipvf_create(struct rte_compressdev *compressdev)  { diff --git
>> a/drivers/compress/octeontx/otx_zip.h b/drivers/compress/octeontx/otx_zip.h
>> index 3fcd86a86..73a99e624 100644
>> --- a/drivers/compress/octeontx/otx_zip.h
>> +++ b/drivers/compress/octeontx/otx_zip.h
>
>...
>
>> +
>> +static inline int
>> +zipvf_prepare_in_buf(struct zip_stream *zstrm, struct rte_comp_op *op)
>> +{
>> +     uint32_t offset, inlen;
>> +     union zip_zptr_s *sg_list = NULL;
>> +     struct rte_mbuf *m_src;
>> +     union zip_inst_s *inst = zstrm->inst;
>> +     rte_iova_t iova;
>> +
>> +     inlen = op->src.length;
>> +     offset = op->src.offset;
>> +     m_src = op->m_src;
>> +
>> +     if (m_src->nb_segs == 1) {
>> +             /* Prepare direct input data pointer */
>> +             inst->s.dg = 0;
>> +             inst->s.inp_ptr_addr.s.addr =
>> +                     rte_pktmbuf_iova_offset(m_src, offset);
>> +             inst->s.inp_ptr_ctl.s.length = inlen;
>> +             return 0;
>> +     }
>> +
>> +     ZIP_PMD_INFO("Input packet is segmented\n");
>> +
>> +     /* Packet is segmented, create gather buffer */
>
>Looks like you actually support SGL, even though you are not setting that in the capabilities.
>Now that the SGL tests are available, you should check if the PMD passes the tests
>and update the capabilities accordingly.
>
>Also, you should take into account if offset is big enough to cross boundaries
>between segments (so first segment to be compressed/decompressed is not the first segment of the SGL).
>Look at the comments that I made in the ZLIB PMD (partly based on comments left in the ISAL PMD),
>since they should apply to this case too.
Ok. Will take care when we add SGL support. Right now, we're planning to make 1st release with Linear buffer support only.

Thanks
Shally
>
>> +     inst->s.dg = 1;
>> +     iova = rte_mempool_virt2iova(zstrm->bufs[IN_DATA_BUF]);
>> +     if (iova & 0xF) {
>> +             /* Align it to 16 Byte address */
>> +             iova = ZIP_ALIGN_ROUNDUP(iova, ZIP_SGPTR_ALIGN);
>> +     }
>> +
>>

  reply	other threads:[~2018-07-24  8:22 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-07-20 19:04 [dpdk-dev] [PATCH v3 0/6] compress: add Octeontx ZIP compression PMD Ashish Gupta
2018-07-20 19:04 ` [dpdk-dev] [PATCH v3 1/6] compress/octeontx: add octeontx zip PMD Ashish Gupta
2018-07-20 19:04 ` [dpdk-dev] [PATCH v3 2/6] compress/octeontx: add device setup PMD ops Ashish Gupta
2018-07-20 19:04 ` [dpdk-dev] [PATCH v3 3/6] compress/octeontx: add xform and stream create support Ashish Gupta
2018-07-20 19:04 ` [dpdk-dev] [PATCH v3 4/6] compress/octeontx: add ops enq deq apis Ashish Gupta
2018-07-23 22:40   ` De Lara Guarch, Pablo
2018-07-24  8:22     ` Verma, Shally [this message]
2018-07-20 19:04 ` [dpdk-dev] [PATCH v3 5/6] doc: add Octeonx zip guide Ashish Gupta
2018-07-20 19:04 ` [dpdk-dev] [PATCH v3 6/6] usertools: update devbind for octeontx zip device Ashish Gupta

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=CY4PR0701MB3634075A26A4C5ADD72E958EF0550@CY4PR0701MB3634.namprd07.prod.outlook.com \
    --to=shally.verma@cavium.com \
    --cc=Ashish.Gupta@cavium.com \
    --cc=Mahipal.Challa@cavium.com \
    --cc=NarayanaPrasad.Athreya@cavium.com \
    --cc=Sunila.Sahu@cavium.com \
    --cc=dev@dpdk.org \
    --cc=pablo.de.lara.guarch@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).