From mboxrd@z Thu Jan 1 00:00:00 1970 From: Bruce Richardson Subject: Re: [PATCH v2 12/40] bnxt: statistics operations Date: Thu, 26 May 2016 10:40:27 +0100 Message-ID: <20160526094027.GD11928@bricha3-MOBL3> References: <1463179589-82681-1-git-send-email-stephen.hurd@broadcom.com> <1463179589-82681-12-git-send-email-stephen.hurd@broadcom.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: dev@dpdk.org To: Stephen Hurd Return-path: Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by dpdk.org (Postfix) with ESMTP id 1D9522BDF for ; Thu, 26 May 2016 11:40:30 +0200 (CEST) Content-Disposition: inline In-Reply-To: <1463179589-82681-12-git-send-email-stephen.hurd@broadcom.com> List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" On Fri, May 13, 2016 at 03:46:01PM -0700, Stephen Hurd wrote: > Add get and clear staitstics operations and the asociated HWRM calls. > > Signed-off-by: Stephen Hurd > Reviewed-by: Ajit Kumar Khaparde > --- > drivers/net/bnxt/Makefile | 1 + > drivers/net/bnxt/bnxt.h | 5 +- > drivers/net/bnxt/bnxt_cpr.c | 5 +- > drivers/net/bnxt/bnxt_cpr.h | 2 - > drivers/net/bnxt/bnxt_ethdev.c | 3 + > drivers/net/bnxt/bnxt_hwrm.c | 49 ++++++++++++ > drivers/net/bnxt/bnxt_hwrm.h | 8 +- > drivers/net/bnxt/bnxt_rxq.c | 1 + > drivers/net/bnxt/bnxt_stats.c | 142 +++++++++++++++++++++++++++++++++ > drivers/net/bnxt/bnxt_stats.h | 44 ++++++++++ > drivers/net/bnxt/bnxt_txq.c | 1 + > drivers/net/bnxt/hsi_struct_def_dpdk.h | 107 +++++++++++++++++++++++++ > 12 files changed, 358 insertions(+), 10 deletions(-) > create mode 100644 drivers/net/bnxt/bnxt_stats.c > create mode 100644 drivers/net/bnxt/bnxt_stats.h > > diff --git a/drivers/net/bnxt/Makefile b/drivers/net/bnxt/Makefile > index 21ed71c..f6a04f8 100644 > --- a/drivers/net/bnxt/Makefile > +++ b/drivers/net/bnxt/Makefile > @@ -54,6 +54,7 @@ SRCS-$(CONFIG_RTE_LIBRTE_BNXT_PMD) += bnxt_filter.c > SRCS-$(CONFIG_RTE_LIBRTE_BNXT_PMD) += bnxt_hwrm.c > SRCS-$(CONFIG_RTE_LIBRTE_BNXT_PMD) += bnxt_ring.c > SRCS-$(CONFIG_RTE_LIBRTE_BNXT_PMD) += bnxt_rxq.c > +SRCS-$(CONFIG_RTE_LIBRTE_BNXT_PMD) += bnxt_stats.c > SRCS-$(CONFIG_RTE_LIBRTE_BNXT_PMD) += bnxt_txq.c > SRCS-$(CONFIG_RTE_LIBRTE_BNXT_PMD) += bnxt_vnic.c > > diff --git a/drivers/net/bnxt/bnxt.h b/drivers/net/bnxt/bnxt.h > index 38b590b..96f162e 100644 > --- a/drivers/net/bnxt/bnxt.h > +++ b/drivers/net/bnxt/bnxt.h > @@ -42,9 +42,6 @@ > #include > #include > > -/* TODO make bnxt.def_cp_ring a pointer to avoid this... */ > -#include "bnxt_cpr.h" > - This fix doesn't seem to logically belong in this patch. See if it can be merged in with the patch where the TODO was first raised. > #define BNXT_MAX_MTU 9000 > #define VLAN_TAG_SIZE 4 > > @@ -141,7 +138,7 @@ struct bnxt { > struct bnxt_tx_queue **tx_queues; > > /* Default completion ring */ > - struct bnxt_cp_ring_info def_cp_ring; > + struct bnxt_cp_ring_info *def_cp_ring; Even though it's not strictly necessary, it might be nice to put in a dummy forward definition of the bnxt_cp_ring_info before this structure to show that it's a structure type that will be used later, but is opaque. i.e. put in a line with: "struct bnxt_cp_ring_info;" /Bruce