From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga01.intel.com (mga01.intel.com [192.55.52.88]) by dpdk.org (Postfix) with ESMTP id 608E85A69 for ; Wed, 25 Feb 2015 18:29:43 +0100 (CET) Received: from orsmga002.jf.intel.com ([10.7.209.21]) by fmsmga101.fm.intel.com with ESMTP; 25 Feb 2015 09:29:39 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.09,646,1418112000"; d="scan'208";a="690677613" Received: from irsmsx101.ger.corp.intel.com ([163.33.3.153]) by orsmga002.jf.intel.com with ESMTP; 25 Feb 2015 09:29:38 -0800 Received: from irsmsx108.ger.corp.intel.com ([169.254.11.218]) by IRSMSX101.ger.corp.intel.com ([163.33.3.153]) with mapi id 14.03.0195.001; Wed, 25 Feb 2015 17:29:36 +0000 From: "Dumitrescu, Cristian" To: Thomas Monjalon , Stephen Hemminger Thread-Topic: [dpdk-dev] [PATCH v2 4/7] rte_sched: don't clear statistics when read Thread-Index: AQHQUG2PBcpMkTs6GkOPMSEXjrLftJ0Bn0QQ Date: Wed, 25 Feb 2015 17:29:36 +0000 Message-ID: <3EB4FA525960D640B5BDFFD6A3D891263231D32F@IRSMSX108.ger.corp.intel.com> References: <1423116841-19799-4-git-send-email-stephen@networkplumber.org> <20150224111852.42253352@urahara> <3501387.NqU76YxSK9@xps13> In-Reply-To: <3501387.NqU76YxSK9@xps13> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [163.33.239.181] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Cc: "dev@dpdk.org" , Stephen Hemminger Subject: Re: [dpdk-dev] [PATCH v2 4/7] rte_sched: don't clear statistics when read X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 25 Feb 2015 17:29:47 -0000 > -----Original Message----- > From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Thomas Monjalon > Sent: Tuesday, February 24, 2015 8:07 PM > To: Stephen Hemminger > Cc: dev@dpdk.org; Stephen Hemminger > Subject: Re: [dpdk-dev] [PATCH v2 4/7] rte_sched: don't clear statistics = when > read >=20 > 2015-02-24 11:18, Stephen Hemminger: > > On Mon, 23 Feb 2015 23:51:31 +0000 > > Thomas Monjalon wrote: > > > > > 2015-02-05 07:43, Neil Horman: > > > > On Wed, Feb 04, 2015 at 10:13:58PM -0800, Stephen Hemminger wrote: > > > > > + > > > > > +/** > > > > > + * Hierarchical scheduler subport statistics reset > > > > > + * > > > > > + * @param port > > > > > + * Handle to port scheduler instance > > > > > + * @param subport_id > > > > > + * Subport ID > > > > > + * @return > > > > > + * 0 upon success, error code otherwise > > > > > + */ > > > > > +int > > > > > +rte_sched_subport_stats_reset(struct rte_sched_port *port, > > > > > + uint32_t subport_id); > > > > > + > > > > > /** > > > > > * Hierarchical scheduler queue statistics read > > > > > * > > > > > @@ -338,6 +353,20 @@ rte_sched_queue_read_stats(struct > rte_sched_port *port, > > > > > struct rte_sched_queue_stats *stats, > > > > > uint16_t *qlen); > > > > > > > > > > +/** > > > > > + * Hierarchical scheduler queue statistics reset > > > > > + * > > > > > + * @param port > > > > > + * Handle to port scheduler instance > > > > > + * @param queue_id > > > > > + * Queue ID within port scheduler > > > > > + * @return > > > > > + * 0 upon success, error code otherwise > > > > > + */ > > > > > +int > > > > > +rte_sched_queue_stats_reset(struct rte_sched_port *port, > > > > > + uint32_t queue_id); > > > > > + > > > > Both need to be added to the version map to expose them properly. > > > > Neil > > > > > > Stephen, this patchset is partially acked and could enter in 2.0.0-rc= 1. > > > May you send a v3 addressing comments? Or should I break the serie by > > > applying only some of them? Or postpone the serie to 2.1? > > > > I can resend v3. Wasn't clear that a conclusion was reached. > > IMHO read should not clear. >=20 > Me too. I'm just saying that I cannot apply anything. > So you have to decide the strategy to adopt for your patches. How about my latest proposal to have the stats read functions either reset = the counters or not, based on init-time user configuration? I did not see a= ny reply on this. Maybe you guys missed my reply, I am pasting it below: "Personally, I think we should avoid proliferating the number of stats func= tions, I would keep a single set of stats read functions, which can clear t= he stats or not, depending on behaviour configured per rte_sched object at = creation time. Basically, based on the value of configuration parameter str= uct rte_sched_params::clear_stats_on_reset, the stats read functions do cle= ar the counters or not. In my opinion, this allows a clean init-time select= ion of the required behaviour, and it also provides backward compatibility.= Any issues with this approach?"