DPDK patches and discussions
 help / color / mirror / Atom feed
From: Gowrishankar Muthukrishnan <gmuthukrishn@marvell.com>
To: Rebecca Troy <rebecca.troy@intel.com>, "dev@dpdk.org" <dev@dpdk.org>
Cc: "roy.fan.zhang@intel.com" <roy.fan.zhang@intel.com>,
	"ciara.power@intel.com" <ciara.power@intel.com>,
	Akhil Goyal <gakhil@marvell.com>,
	Declan Doherty <declan.doherty@intel.com>
Subject: Re: [dpdk-dev] [EXT]  [PATCH] cryptodev: add telemetry callbacks
Date: Wed, 29 Sep 2021 05:14:38 +0000	[thread overview]
Message-ID: <CO1PR18MB4714D0326E55C0D88715694DCBA99@CO1PR18MB4714.namprd18.prod.outlook.com> (raw)
In-Reply-To: <20210819102157.1190022-1-rebecca.troy@intel.com>

> An example usage can be seen below:
> 
> Connecting to /var/run/dpdk/rte/dpdk_telemetry.v2
> {"version": "DPDK 21.11.0-rc0", "pid": 1135019, "max_output_len": 16384}
> --> /
> {"/": ["/", "/cryptodev/list", "/cryptodev/stats", ...]}
> --> /cryptodev/list
> {"/cryptodev/list": {"0000:1a:01.0_qat_sym": 0, "0000:1a:01.0_qat_asym": \
> 	1}}

Will this be better if we list keys by port ID, as port ID is used as param in appropriate endpoints ?
Just a suggestion.

> --> /cryptodev/stats,0
> {"/cryptodev/stats": {"enqueued_count": 0, "dequeued_count": 0, \
> 	"enqueue_err_count": 0, "dequeue_err_count": 0}}
> 
> Signed-off-by: Rebecca Troy <rebecca.troy@intel.com>
> ---
>  lib/cryptodev/rte_cryptodev.c | 62 +++++++++++++++++++++++++++++++++++
>  1 file changed, 62 insertions(+)
> 
> diff --git a/lib/cryptodev/rte_cryptodev.c b/lib/cryptodev/rte_cryptodev.c index
> 447aa9d519..1e3ab633cc 100644
> --- a/lib/cryptodev/rte_cryptodev.c
> +++ b/lib/cryptodev/rte_cryptodev.c
> @@ -36,6 +36,7 @@
>  #include <rte_errno.h>
>  #include <rte_spinlock.h>
>  #include <rte_string_fns.h>
> +#include <rte_telemetry.h>
> 
>  #include "rte_crypto.h"
>  #include "rte_cryptodev.h"
> @@ -2427,3 +2428,64 @@ rte_cryptodev_allocate_driver(struct
> cryptodev_driver *crypto_drv,
> 
>  	return nb_drivers++;
>  }
> +
> +static int
> +cryptodev_handle_dev_list(const char *cmd __rte_unused,
> +		const char *params __rte_unused,
> +		struct rte_tel_data *d)
> +{
> +	int dev_id;
> +
> +	if (rte_cryptodev_count() < 1)
> +		return -1;
> +
> +	rte_tel_data_start_dict(d);
> +	for (dev_id = 0; dev_id < RTE_CRYPTO_MAX_DEVS; dev_id++)
> +		if (rte_cryptodev_pmd_is_valid_dev(dev_id))

This is broken now. Correct function is rte_cryptodev_is_valid_dev() .

Thanks,
Gowrishankar

  parent reply	other threads:[~2021-09-29  5:14 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-08-19 10:21 [dpdk-dev] " Rebecca Troy
2021-08-20 12:59 ` Zhang, Roy Fan
2021-09-28 10:47 ` [dpdk-dev] [EXT] " Akhil Goyal
2021-09-28 10:48 ` Akhil Goyal
2021-09-29  5:14 ` Gowrishankar Muthukrishnan [this message]
2021-09-29  7:51   ` Bruce Richardson
2021-10-07 10:17 ` [dpdk-dev] " Rebecca Troy
2021-10-07 14:11   ` [dpdk-dev] [PATCH v3] " Rebecca Troy
2021-10-12 14:30     ` Power, Ciara
2021-10-13 10:22     ` [dpdk-dev] [PATCH v4] " Rebecca Troy
2021-10-13 10:57       ` Power, Ciara
2021-10-13 12:15       ` Tal Shnaiderman
2021-10-13 15:22       ` [dpdk-dev] [PATCH v5] " Rebecca Troy
2021-10-13 16:08         ` Bruce Richardson
2021-10-25  4:32         ` [dpdk-dev] [EXT] " Akhil Goyal
2021-10-26  8:22           ` Troy, Rebecca
2021-10-26 12:00         ` [dpdk-dev] [PATCH v6] " Rebecca Troy
2021-10-26 14:37           ` [dpdk-dev] [EXT] " Akhil Goyal

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=CO1PR18MB4714D0326E55C0D88715694DCBA99@CO1PR18MB4714.namprd18.prod.outlook.com \
    --to=gmuthukrishn@marvell.com \
    --cc=ciara.power@intel.com \
    --cc=declan.doherty@intel.com \
    --cc=dev@dpdk.org \
    --cc=gakhil@marvell.com \
    --cc=rebecca.troy@intel.com \
    --cc=roy.fan.zhang@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).