DPDK patches and discussions
 help / color / mirror / Atom feed
From: Ajit Khaparde <ajit.khaparde@broadcom.com>
To: David Marchand <david.marchand@6wind.com>
Cc: dev@dpdk.org, Somnath Kotur <somnath.kotur@broadcom.com>,
	dpdk stable <stable@dpdk.org>
Subject: Re: [dpdk-dev] [PATCH] net/bnxt: add missing ids in xstats
Date: Thu, 7 Jun 2018 14:34:19 -0700	[thread overview]
Message-ID: <CACZ4nhshUenSOeEcnuSQSbDgc2oyrAGGFDFxeiZfs0arqEmbaQ@mail.gmail.com> (raw)
In-Reply-To: <1528349765-31471-1-git-send-email-david.marchand@6wind.com>

On Wed, Jun 6, 2018 at 10:36 PM, David Marchand <david.marchand@6wind.com>
wrote:

> The xstats api expects that the driver fills both values and ids for each
> filled entries.
>
> Fixes: bfb9c2260be2 ("net/bnxt: support xstats get/reset")
>
> Signed-off-by: David Marchand <david.marchand@6wind.com>
>
​​
Acked-by:
​ Ajit Khaparde <ajit.khaparde@broadcom.com>
​


> ---
>  drivers/net/bnxt/bnxt_stats.c | 3 +++
>  1 file changed, 3 insertions(+)
>
> diff --git a/drivers/net/bnxt/bnxt_stats.c b/drivers/net/bnxt/bnxt_stats.c
> index bbd4e78..a5d3c86 100644
> --- a/drivers/net/bnxt/bnxt_stats.c
> +++ b/drivers/net/bnxt/bnxt_stats.c
> @@ -278,6 +278,7 @@ int bnxt_dev_xstats_get_op(struct rte_eth_dev *eth_dev,
>         count = 0;
>         for (i = 0; i < RTE_DIM(bnxt_rx_stats_strings); i++) {
>                 uint64_t *rx_stats = (uint64_t *)bp->hw_rx_port_stats;
> +               xstats[count].id = count;
>                 xstats[count].value = rte_le_to_cpu_64(
>                                 *(uint64_t *)((char *)rx_stats +
>                                 bnxt_rx_stats_strings[i].offset));
> @@ -286,6 +287,7 @@ int bnxt_dev_xstats_get_op(struct rte_eth_dev *eth_dev,
>
>         for (i = 0; i < RTE_DIM(bnxt_tx_stats_strings); i++) {
>                 uint64_t *tx_stats = (uint64_t *)bp->hw_tx_port_stats;
> +               xstats[count].id = count;
>                 xstats[count].value = rte_le_to_cpu_64(
>                                  *(uint64_t *)((char *)tx_stats +
>                                 bnxt_tx_stats_strings[i].offset));
> @@ -293,6 +295,7 @@ int bnxt_dev_xstats_get_op(struct rte_eth_dev *eth_dev,
>         }
>
>         /* The Tx drop pkts aka the Anti spoof coounter */
> +       xstats[count].id = count;
>         xstats[count].value = rte_le_to_cpu_64(tx_drop_pkts);
>         count++;
>
> --
> 2.7.4
>
>

  reply	other threads:[~2018-06-07 21:35 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-06-07  5:36 David Marchand
2018-06-07 21:34 ` Ajit Khaparde [this message]
2018-06-08 19:57   ` [dpdk-dev] [dpdk-stable] " Ferruh Yigit
2018-06-08 19:58     ` Ferruh Yigit

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=CACZ4nhshUenSOeEcnuSQSbDgc2oyrAGGFDFxeiZfs0arqEmbaQ@mail.gmail.com \
    --to=ajit.khaparde@broadcom.com \
    --cc=david.marchand@6wind.com \
    --cc=dev@dpdk.org \
    --cc=somnath.kotur@broadcom.com \
    --cc=stable@dpdk.org \
    /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).