From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id BAD91A052B; Tue, 28 Jul 2020 12:25:06 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 8E31B1C027; Tue, 28 Jul 2020 12:25:06 +0200 (CEST) Received: from mga17.intel.com (mga17.intel.com [192.55.52.151]) by dpdk.org (Postfix) with ESMTP id BCE281BE8A for ; Tue, 28 Jul 2020 12:25:04 +0200 (CEST) IronPort-SDR: uLmESDmYC046KnJ643bkHHhQSbloYk6ufvK+9zAF88iGBsY83ZfshUndCNv74OeRtHLzuknKZh V5x6aNqw8r1g== X-IronPort-AV: E=McAfee;i="6000,8403,9695"; a="131247968" X-IronPort-AV: E=Sophos;i="5.75,406,1589266800"; d="scan'208";a="131247968" X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga005.jf.intel.com ([10.7.209.41]) by fmsmga107.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 28 Jul 2020 03:25:03 -0700 IronPort-SDR: opxI2cLtFolUZaxQxxyiu8Xeb9/c88GEbqCBIE6nDqEJNtDXFwyI+yHKsVu+gIaQptt3Aj+Hmg q11ZdNCWywsw== X-IronPort-AV: E=Sophos;i="5.75,406,1589266800"; d="scan'208";a="464420275" Received: from bricha3-mobl.ger.corp.intel.com ([10.249.40.141]) by orsmga005-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-SHA; 28 Jul 2020 03:25:01 -0700 Date: Tue, 28 Jul 2020 11:24:58 +0100 From: Bruce Richardson To: Stephen Hemminger Cc: Anatoly Burakov , dev@dpdk.org, remy.horton@intel.com, ciara.power@intel.com Message-ID: <20200728102458.GA2333@bricha3-MOBL.ger.corp.intel.com> References: <20200702172852.6201-1-stephen@networkplumber.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200702172852.6201-1-stephen@networkplumber.org> Subject: Re: [dpdk-dev] [PATCH] metrics: make number of metrics names configurable 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" On Thu, Jul 02, 2020 at 10:28:52AM -0700, Stephen Hemminger wrote: > The maximum number of metrics is hardcoded at 256. > This severely limits the usefulness of the library. > It should be configurable like other limits in DPDK. > > Fixes: 349950ddb9c5 ("metrics: add information metrics library") > Cc: remy.horton@intel.com > Cc: ciara.power@intel.com > Signed-off-by: Stephen Hemminger > --- > config/common_base | 1 + > config/meson.build | 2 +- > lib/librte_metrics/rte_metrics.h | 1 - > 3 files changed, 2 insertions(+), 2 deletions(-) > > diff --git a/config/common_base b/config/common_base > index fe30c515e5a3..f0212faec80c 100644 > --- a/config/common_base > +++ b/config/common_base > @@ -917,6 +917,7 @@ CONFIG_RTE_LIBRTE_JOBSTATS=y > # Compile the device metrics library > # > CONFIG_RTE_LIBRTE_METRICS=y > +CONFIG_RTE_METRICS_MAX_METRICS=256 > > # > # Compile the bitrate statistics library > diff --git a/config/meson.build b/config/meson.build > index 351e268c1f5b..cc8cb8fbf2f0 100644 > --- a/config/meson.build > +++ b/config/meson.build > @@ -238,7 +238,7 @@ dpdk_conf.set('RTE_ENABLE_TRACE_FP', get_option('enable_trace_fp')) > dpdk_conf.set('RTE_MAX_VFIO_GROUPS', 64) > dpdk_conf.set('RTE_DRIVER_MEMPOOL_BUCKET_SIZE_KB', 64) > dpdk_conf.set('RTE_LIBRTE_DPAA2_USE_PHYS_IOVA', true) > - > +dpdk_conf.set('RTE_METRICS_MAX_METRICS', 256) > The meson.build file should really just be used for computed values, I think. For build-time constants like this it's probably better put in config/rte_config.h file. Regards, /Bruce