From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 9B44FA0350; Tue, 22 Feb 2022 13:58:07 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 37E8141153; Tue, 22 Feb 2022 13:57:58 +0100 (CET) Received: from mga03.intel.com (mga03.intel.com [134.134.136.65]) by mails.dpdk.org (Postfix) with ESMTP id DB37441142 for ; Tue, 22 Feb 2022 13:57:55 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1645534676; x=1677070676; h=from:to:subject:date:message-id:in-reply-to:references: mime-version:content-transfer-encoding; bh=FZiVtNHcYXmBUVYUZL7u8DF5s7GUqvX+r23OKPwTBjk=; b=T+md6qINNwru9mHKaa+Mr3WJfKCtIIhsddIq7wm8RMhQGBAc4SS4drK9 HuPpiUXX+Pvnh1o4PYM5wuF5Ckddanvzrt4lJ5+QjdH+NfEfjAXgTbIAL 5gai66Fs0fvAId45EodYsII7hk71UxREIKQH3JE3gHlf2J1q0kRa3mAEW q5+i8IhHJ6ClYY5y8EhxG38AHxo+B8HkacrTX52lvckbCAw8C2BPkCyqd k3EpnMTjAZeAqyEQz2g0WWnrgmcdZmJ09QbTNtu0eD/E4jcJsQfUNocD8 3cp5Q6zP/l6HvKtW3ICYZzL3km9hnrFK5RJvdq3mwIrXLw4bR5pu6RVoq w==; X-IronPort-AV: E=McAfee;i="6200,9189,10265"; a="251627060" X-IronPort-AV: E=Sophos;i="5.88,387,1635231600"; d="scan'208";a="251627060" Received: from fmsmga007.fm.intel.com ([10.253.24.52]) by orsmga103.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 22 Feb 2022 04:57:55 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.88,387,1635231600"; d="scan'208";a="542926661" Received: from silpixa00397515.ir.intel.com (HELO silpixa00397515.ger.corp.intel.com) ([10.237.222.51]) by fmsmga007.fm.intel.com with ESMTP; 22 Feb 2022 04:57:53 -0800 From: Megha Ajmera To: dev@dpdk.org, jasvinder.singh@intel.com, cristian.dumitrescu@intel.com, thomas@monjalon.net, david.marchand@redhat.com, sham.singh.thakur@intel.com Subject: [PATCH v3 3/4] sched: enable statistics unconditionally Date: Tue, 22 Feb 2022 12:57:44 +0000 Message-Id: <20220222125745.2944462-4-megha.ajmera@intel.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20220222125745.2944462-1-megha.ajmera@intel.com> References: <20220218093650.2549927-1-megha.ajmera@intel.com> <20220222125745.2944462-1-megha.ajmera@intel.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Removed RTE_SCHED_COLLECT_STATS flag from rte_config.h. Stats collection is always enabled. Signed-off-by: Megha Ajmera --- config/rte_config.h | 1 - doc/guides/sample_app_ug/qos_scheduler.rst | 6 ------ lib/sched/rte_sched.c | 12 ------------ 3 files changed, 19 deletions(-) diff --git a/config/rte_config.h b/config/rte_config.h index d449af4810..de6fea5b67 100644 --- a/config/rte_config.h +++ b/config/rte_config.h @@ -90,7 +90,6 @@ /* rte_sched defines */ #undef RTE_SCHED_CMAN -#undef RTE_SCHED_COLLECT_STATS #undef RTE_SCHED_SUBPORT_TC_OV /* rte_graph defines */ diff --git a/doc/guides/sample_app_ug/qos_scheduler.rst b/doc/guides/sample_app_ug/qos_scheduler.rst index 0782e41ee7..34b662b230 100644 --- a/doc/guides/sample_app_ug/qos_scheduler.rst +++ b/doc/guides/sample_app_ug/qos_scheduler.rst @@ -39,12 +39,6 @@ The application is located in the ``qos_sched`` sub-directory. This application is intended as a linux only. -.. note:: - - To get statistics on the sample app using the command line interface as described in the next section, - DPDK must be compiled defining *RTE_SCHED_COLLECT_STATS*, which can be done by changing the relevant - entry in the ``config/rte_config.h`` file. - .. note:: Number of grinders is currently set to 8. This can be modified by specifying RTE_SCHED_PORT_N_GRINDERS=N in diff --git a/lib/sched/rte_sched.c b/lib/sched/rte_sched.c index 9c85edb4cc..8a051049de 100644 --- a/lib/sched/rte_sched.c +++ b/lib/sched/rte_sched.c @@ -1779,8 +1779,6 @@ rte_sched_port_queue_is_empty(struct rte_sched_subport *subport, #endif /* RTE_SCHED_DEBUG */ -#ifdef RTE_SCHED_COLLECT_STATS - static inline void rte_sched_port_update_subport_stats(struct rte_sched_port *port, struct rte_sched_subport *subport, @@ -1838,8 +1836,6 @@ rte_sched_port_update_queue_stats_on_drop(struct rte_sched_subport *subport, #endif } -#endif /* RTE_SCHED_COLLECT_STATS */ - #ifdef RTE_SCHED_CMAN static inline int @@ -1978,18 +1974,14 @@ rte_sched_port_enqueue_qptrs_prefetch0(struct rte_sched_subport *subport, struct rte_mbuf *pkt, uint32_t subport_qmask) { struct rte_sched_queue *q; -#ifdef RTE_SCHED_COLLECT_STATS struct rte_sched_queue_extra *qe; -#endif uint32_t qindex = rte_mbuf_sched_queue_get(pkt); uint32_t subport_queue_id = subport_qmask & qindex; q = subport->queue + subport_queue_id; rte_prefetch0(q); -#ifdef RTE_SCHED_COLLECT_STATS qe = subport->queue_extra + subport_queue_id; rte_prefetch0(qe); -#endif return subport_queue_id; } @@ -2031,12 +2023,10 @@ rte_sched_port_enqueue_qwa(struct rte_sched_port *port, if (unlikely(rte_sched_port_cman_drop(port, subport, pkt, qindex, qlen) || (qlen >= qsize))) { rte_pktmbuf_free(pkt); -#ifdef RTE_SCHED_COLLECT_STATS rte_sched_port_update_subport_stats_on_drop(port, subport, qindex, pkt, qlen < qsize); rte_sched_port_update_queue_stats_on_drop(subport, qindex, pkt, qlen < qsize); -#endif return 0; } @@ -2048,10 +2038,8 @@ rte_sched_port_enqueue_qwa(struct rte_sched_port *port, rte_bitmap_set(subport->bmp, qindex); /* Statistics */ -#ifdef RTE_SCHED_COLLECT_STATS rte_sched_port_update_subport_stats(port, subport, qindex, pkt); rte_sched_port_update_queue_stats(subport, qindex, pkt); -#endif return 1; } -- 2.25.1