From patchwork Thu Mar 30 21:00:57 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Remy Horton X-Patchwork-Id: 22952 Return-Path: X-Original-To: patchwork@dpdk.org Delivered-To: patchwork@dpdk.org Received: from [92.243.14.124] (localhost [IPv6:::1]) by dpdk.org (Postfix) with ESMTP id 138762C02; Thu, 30 Mar 2017 23:01:24 +0200 (CEST) Received: from mga07.intel.com (mga07.intel.com [134.134.136.100]) by dpdk.org (Postfix) with ESMTP id CA967101B for ; Thu, 30 Mar 2017 23:01:08 +0200 (CEST) Received: from orsmga005.jf.intel.com ([10.7.209.41]) by orsmga105.jf.intel.com with ESMTP; 30 Mar 2017 14:01:06 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.36,248,1486454400"; d="scan'208";a="81136768" Received: from mprzygod-mobl.ger.corp.intel.com (HELO FC23.ger.corp.intel.com) ([10.252.23.81]) by orsmga005.jf.intel.com with ESMTP; 30 Mar 2017 14:01:05 -0700 From: Remy Horton To: dev@dpdk.org Cc: Thomas Monjalon Date: Thu, 30 Mar 2017 22:00:57 +0100 Message-Id: <1490907662-27666-2-git-send-email-remy.horton@intel.com> X-Mailer: git-send-email 2.5.5 In-Reply-To: <1490907662-27666-1-git-send-email-remy.horton@intel.com> References: <1490907662-27666-1-git-send-email-remy.horton@intel.com> Subject: [dpdk-dev] [PATCH v14 1/6] lib: add information metrics library X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" This patch adds a new information metrics library. This Metrics library implements a mechanism by which producers can publish numeric information for later querying by consumers. Metrics themselves are statistics that are not generated by PMDs, and hence are not reported via ethdev extended statistics. Metric information is populated using a push model, where producers update the values contained within the metric library by calling an update function on the relevant metrics. Consumers receive metric information by querying the central metric data, which is held in shared memory. Signed-off-by: Remy Horton --- MAINTAINERS | 4 + config/common_base | 5 + doc/api/doxy-api-index.md | 3 +- doc/api/doxy-api.conf | 3 +- doc/guides/prog_guide/index.rst | 3 +- doc/guides/prog_guide/metrics_lib.rst | 180 +++++++++++++++++ doc/guides/rel_notes/release_17_05.rst | 9 + lib/Makefile | 2 + lib/librte_metrics/Makefile | 51 +++++ lib/librte_metrics/rte_metrics.c | 302 +++++++++++++++++++++++++++++ lib/librte_metrics/rte_metrics.h | 240 +++++++++++++++++++++++ lib/librte_metrics/rte_metrics_version.map | 13 ++ mk/rte.app.mk | 1 + 13 files changed, 813 insertions(+), 3 deletions(-) create mode 100644 doc/guides/prog_guide/metrics_lib.rst create mode 100644 lib/librte_metrics/Makefile create mode 100644 lib/librte_metrics/rte_metrics.c create mode 100644 lib/librte_metrics/rte_metrics.h create mode 100644 lib/librte_metrics/rte_metrics_version.map diff --git a/MAINTAINERS b/MAINTAINERS index 4cb6e49..4eede38 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -626,6 +626,10 @@ F: lib/librte_jobstats/ F: examples/l2fwd-jobstats/ F: doc/guides/sample_app_ug/l2_forward_job_stats.rst +Metrics +M: Remy Horton +F: lib/librte_metrics/ + Test Applications ----------------- diff --git a/config/common_base b/config/common_base index 2d54ddf..52394d9 100644 --- a/config/common_base +++ b/config/common_base @@ -503,6 +503,11 @@ CONFIG_RTE_LIBRTE_EFD=y CONFIG_RTE_LIBRTE_JOBSTATS=y # +# Compile the device metrics library +# +CONFIG_RTE_LIBRTE_METRICS=y + +# # Compile librte_lpm # CONFIG_RTE_LIBRTE_LPM=y diff --git a/doc/api/doxy-api-index.md b/doc/api/doxy-api-index.md index eb39f69..1cbe128 100644 --- a/doc/api/doxy-api-index.md +++ b/doc/api/doxy-api-index.md @@ -4,7 +4,7 @@ API {#index}