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 E28F6A0A0F; Fri, 4 Jun 2021 16:42:41 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 76D374068F; Fri, 4 Jun 2021 16:42:41 +0200 (CEST) Received: from shelob.oktetlabs.ru (shelob.oktetlabs.ru [91.220.146.113]) by mails.dpdk.org (Postfix) with ESMTP id DB57A40147 for ; Fri, 4 Jun 2021 16:42:40 +0200 (CEST) Received: by shelob.oktetlabs.ru (Postfix, from userid 122) id 9AB6D7F68E; Fri, 4 Jun 2021 17:42:40 +0300 (MSK) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on shelob.oktetlabs.ru X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=ALL_TRUSTED, DKIM_ADSP_DISCARD, URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.2 Received: from aros.oktetlabs.ru (aros.oktetlabs.ru [192.168.38.17]) by shelob.oktetlabs.ru (Postfix) with ESMTP id 945E67F514 for ; Fri, 4 Jun 2021 17:42:34 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 shelob.oktetlabs.ru 945E67F514 Authentication-Results: shelob.oktetlabs.ru/945E67F514; dkim=none; dkim-atps=neutral From: Andrew Rybchenko To: dev@dpdk.org Date: Fri, 4 Jun 2021 17:42:14 +0300 Message-Id: <20210604144225.287678-1-andrew.rybchenko@oktetlabs.ru> X-Mailer: git-send-email 2.30.2 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Subject: [dpdk-dev] [PATCH 00/11] net/sfc: provide Rx/Tx doorbells stats 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 Sender: "dev" Rx/Tx doorbells stats are essential for performance investigation. On the way fix ethdev documenation to refine requirements on driver callback. It allows to make these callbacks a bit simpler. Add testpmd option to show specified xstats periodically or upon request, for example: * --display-xstats rx_good_packets,tx_good_packets --stats-period 1 Port statistics ==================================== ######################## NIC statistics for port 0 ######################## RX-packets: 14102808 RX-missed: 0 RX-bytes: 7164239264 RX-errors: 0 RX-nombuf: 0 TX-packets: 14102789 TX-errors: 0 TX-bytes: 7164226028 Throughput (since last show) Rx-pps: 2349577 Rx-bps: 9548682392 Tx-pps: 2349576 Tx-bps: 9548682408 Value Rate (since last show) rx_good_packets 14103280 2349575 tx_good_packets 14103626 2349573 ############################################################################ * -i --display-xstats tx_good_packets,vadapter_rx_overflow testpmd> port start 0 ... No xstat 'vadapter_rx_overflow' on port 0 - skip it ... testpmd> start tx_first testpmd> show port stats all Value Rate (since last show) tx_good_packets 132545336 1420439 net/sfc part of the patch series should be applied on top of [1]. [1] https://patches.dpdk.org/project/dpdk/list/?series=17238 Ivan Ilchenko (11): net/sfc: fix get xstats by ID callback to use MAC stats lock net/sfc: fix reading adapter state without locking ethdev: fix docs of functions getting xstats by IDs ethdev: fix docs of drivers callbacks getting xstats by IDs net/sfc: fix xstats by ID callbacks according to ethdev net/sfc: fix accessing xstats by an unsorted list of IDs net/sfc: fix MAC stats update to work for stopped device net/sfc: simplify getting of available xstats case net/sfc: prepare to add more xstats net/sfc: add xstats for Rx/Tx doorbells app/testpmd: add option to display extended statistics app/test-pmd/cmdline.c | 56 +++ app/test-pmd/config.c | 66 +++ app/test-pmd/parameters.c | 18 + app/test-pmd/testpmd.c | 122 ++++++ app/test-pmd/testpmd.h | 21 + doc/guides/testpmd_app_ug/run_app.rst | 5 + drivers/net/sfc/meson.build | 1 + drivers/net/sfc/sfc.c | 16 + drivers/net/sfc/sfc.h | 18 +- drivers/net/sfc/sfc_dp.h | 10 + drivers/net/sfc/sfc_ef10.h | 3 +- drivers/net/sfc/sfc_ef100_rx.c | 1 + drivers/net/sfc/sfc_ef100_tx.c | 1 + drivers/net/sfc/sfc_ef10_essb_rx.c | 3 +- drivers/net/sfc/sfc_ef10_rx.c | 3 +- drivers/net/sfc/sfc_ef10_tx.c | 1 + drivers/net/sfc/sfc_ethdev.c | 185 +++++---- drivers/net/sfc/sfc_port.c | 127 +++++- drivers/net/sfc/sfc_rx.c | 1 + drivers/net/sfc/sfc_sw_stats.c | 572 ++++++++++++++++++++++++++ drivers/net/sfc/sfc_sw_stats.h | 49 +++ drivers/net/sfc/sfc_tx.c | 4 +- lib/ethdev/ethdev_driver.h | 43 +- lib/ethdev/rte_ethdev.h | 23 +- 24 files changed, 1243 insertions(+), 106 deletions(-) create mode 100644 drivers/net/sfc/sfc_sw_stats.c create mode 100644 drivers/net/sfc/sfc_sw_stats.h -- 2.30.2