DPDK patches and discussions
 help / color / mirror / Atom feed
From: "De Lara Guarch, Pablo" <pablo.de.lara.guarch@intel.com>
To: Shally Verma <shally.verma@caviumnetworks.com>
Cc: "dev@dpdk.org" <dev@dpdk.org>,
	"pathreya@caviumnetworks.com" <pathreya@caviumnetworks.com>,
	"mchalla@caviumnetworks.com" <mchalla@caviumnetworks.com>,
	Sunila Sahu <sunila.sahu@caviumnetworks.com>,
	Ashish Gupta <ashish.gupta@caviumnetworks.com>
Subject: Re: [dpdk-dev] [PATCH v2 2/6] compress/octeontx: add device setup PMD ops
Date: Fri, 13 Jul 2018 22:21:36 +0000	[thread overview]
Message-ID: <E115CCD9D858EF4F90C690B0DCB4D8977F8FA74A@IRSMSX107.ger.corp.intel.com> (raw)
In-Reply-To: <1530550477-22444-3-git-send-email-shally.verma@caviumnetworks.com>



> -----Original Message-----
> From: Shally Verma [mailto:shally.verma@caviumnetworks.com]
> Sent: Monday, July 2, 2018 5:55 PM
> To: De Lara Guarch, Pablo <pablo.de.lara.guarch@intel.com>
> Cc: dev@dpdk.org; pathreya@caviumnetworks.com;
> mchalla@caviumnetworks.com; Sunila Sahu
> <sunila.sahu@caviumnetworks.com>; Ashish Gupta
> <ashish.gupta@caviumnetworks.com>
> Subject: [PATCH v2 2/6] compress/octeontx: add device setup PMD ops
> 
> From: Sunila Sahu <sunila.sahu@caviumnetworks.com>
> 
> implement device configure and PMD ops.
> setup stream resource memory pool
> setup and enable hardware queue
> 
> 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/zip_pmd.c | 251
> ++++++++++++++++++++++++++++++++++++
>  drivers/compress/octeontx/zipvf.c   |  73 +++++++++++
>  drivers/compress/octeontx/zipvf.h   |  56 +++++++-
>  3 files changed, 378 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/compress/octeontx/zip_pmd.c
> b/drivers/compress/octeontx/zip_pmd.c
> index 2011db37e..44c271e1a 100644
> --- a/drivers/compress/octeontx/zip_pmd.c
> +++ b/drivers/compress/octeontx/zip_pmd.c
> @@ -9,8 +9,259 @@
>  #include <rte_cpuflags.h>
>  #include <rte_malloc.h>
> 
> +static const struct rte_compressdev_capabilities
> +				octtx_zip_pmd_capabilities[] = {
> +	{	.algo = RTE_COMP_ALGO_DEFLATE,
> +		/* Deflate */
> +		.comp_feature_flags = 0,

Need to add at least Fixed feature flag here.

> +		/* Non sharable Priv XFORM and Stateless */
> +		.window_size = {
> +				.min = 1,
> +				.max = 14,
> +				.increment = 1
> +				/* size supported 2^1 to 2^14 */
> +		},
> +	},
> +	RTE_COMP_END_OF_CAPABILITIES_LIST()
> +};
> +

...

> +
> +/** Release queue pair */
> +static int
> +zip_pmd_qp_release(struct rte_compressdev *dev, uint16_t qp_id) {
> +	struct zipvf_qp *qp = dev->data->queue_pairs[qp_id];
> +	struct rte_ring *r = NULL;
> +
> +	if (qp != NULL) {
> +		zipvf_q_term(qp);
> +		r = rte_ring_lookup(qp->name);

You can use qp->processed_pkts.

> +		if (r)
> +			rte_ring_free(r);
> +		rte_free(qp);
> +		dev->data->queue_pairs[qp_id] = NULL;
> +	}
> +	return 0;
> +}
> +

...

> +qp_setup_cleanup:
> +	if (qp->processed_pkts) {
> +		rte_ring_free(qp->processed_pkts);
> +		qp->processed_pkts = NULL;
> +	}
> +	if (qp) {
> +		rte_free(qp);
> +		qp = NULL;
> +	

No need to set NULL these two last pointers.

  reply	other threads:[~2018-07-13 22:21 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-07-02 16:54 [dpdk-dev] [PATCH v2 0/6] compress: add Octeontx ZIP compression PMD Shally Verma
2018-07-02 16:54 ` [dpdk-dev] [PATCH v2 1/6] compress/octeontx: add octeontx zip PMD support Shally Verma
2018-07-13 16:23   ` De Lara Guarch, Pablo
2018-07-02 16:54 ` [dpdk-dev] [PATCH v2 2/6] compress/octeontx: add device setup PMD ops Shally Verma
2018-07-13 22:21   ` De Lara Guarch, Pablo [this message]
2018-07-02 16:54 ` [dpdk-dev] [PATCH v2 3/6] compress/octeontx: add xform and stream create support Shally Verma
2018-07-13 22:24   ` De Lara Guarch, Pablo
2018-07-17 12:50     ` Verma, Shally
2018-07-02 16:54 ` [dpdk-dev] [PATCH v2 4/6] compress/octeontx: add ops enq deq apis Shally Verma
2018-07-02 16:54 ` [dpdk-dev] [PATCH v2 5/6] doc: add Octeonx zip guide Shally Verma
2018-07-13 22:26   ` De Lara Guarch, Pablo
2018-07-02 16:54 ` [dpdk-dev] [PATCH v2 6/6] usertools: update devbind for octeontx zip device Shally Verma
2018-07-11  5:53 ` [dpdk-dev] [PATCH v2 0/6] compress: add Octeontx ZIP compression PMD Verma, Shally
2018-07-11  8:24   ` De Lara Guarch, Pablo

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=E115CCD9D858EF4F90C690B0DCB4D8977F8FA74A@IRSMSX107.ger.corp.intel.com \
    --to=pablo.de.lara.guarch@intel.com \
    --cc=ashish.gupta@caviumnetworks.com \
    --cc=dev@dpdk.org \
    --cc=mchalla@caviumnetworks.com \
    --cc=pathreya@caviumnetworks.com \
    --cc=shally.verma@caviumnetworks.com \
    --cc=sunila.sahu@caviumnetworks.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).