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 14BAAA0471 for ; Mon, 9 Sep 2019 11:54:22 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 366191E8AB; Mon, 9 Sep 2019 11:54:21 +0200 (CEST) Received: from mga14.intel.com (mga14.intel.com [192.55.52.115]) by dpdk.org (Postfix) with ESMTP id 0170D1BEC9 for ; Mon, 9 Sep 2019 11:54:19 +0200 (CEST) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from fmsmga007.fm.intel.com ([10.253.24.52]) by fmsmga103.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 09 Sep 2019 02:54:19 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.64,484,1559545200"; d="scan'208";a="185146358" Received: from fmsmsx105.amr.corp.intel.com ([10.18.124.203]) by fmsmga007.fm.intel.com with ESMTP; 09 Sep 2019 02:54:18 -0700 Received: from fmsmsx154.amr.corp.intel.com (10.18.116.70) by FMSMSX105.amr.corp.intel.com (10.18.124.203) with Microsoft SMTP Server (TLS) id 14.3.439.0; Mon, 9 Sep 2019 02:54:18 -0700 Received: from lcsmsx152.ger.corp.intel.com (10.186.165.231) by FMSMSX154.amr.corp.intel.com (10.18.116.70) with Microsoft SMTP Server (TLS) id 14.3.439.0; Mon, 9 Sep 2019 02:54:18 -0700 Received: from hasmsx107.ger.corp.intel.com ([169.254.2.239]) by LCSMSX152.ger.corp.intel.com ([169.254.4.122]) with mapi id 14.03.0439.000; Mon, 9 Sep 2019 12:54:16 +0300 From: "Konieczny, TomaszX" To: "dev@dpdk.org" Thread-Topic: Flow control rx/tx mismatch? Thread-Index: AdVm8uWmb6RImKJsTLG8ReTkaNCpAA== Date: Mon, 9 Sep 2019 09:54:16 +0000 Message-ID: <08D1104B74A4E2498083321F42D5B4C9172E275E@hasmsx107.ger.corp.intel.com> Accept-Language: en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-product: dlpe-windows dlp-version: 11.2.0.6 dlp-reaction: no-action x-originating-ip: [10.184.70.10] Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Subject: [dpdk-dev] Flow control rx/tx mismatch? 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" Hi, According to DPDK documentation:=20 "RX pause frame, enable flowctrl on TX side."=20 "TX pause frame, enable flowctrl on RX side".=20 While in testpmd (/app/test-pmd/cmdline.c): /* * Rx on/off, flow control is enabled/disabled on RX side. This can indicat= e * the RTE_FC_TX_PAUSE, Transmit pause frame at the Rx side. * Tx on/off, flow control is enabled/disabled on TX side. This can indicat= e * the RTE_FC_RX_PAUSE, Respond to the pause frame at the Tx side. */ =09 However the code looks like this: static enum rte_eth_fc_mode rx_tx_onoff_2_lfc_mode[2][2] =3D { {RTE_FC_NONE, RTE_FC_TX_PAUSE}, {RTE_FC_RX_PAUSE, RTE_FC_FULL} fc_conf.mode =3D rx_tx_onoff_2_lfc_mode[rx_fc_en][tx_fc_en]; and if ((fc_conf.mode =3D=3D RTE_FC_RX_PAUSE) || (fc_conf.mode =3D=3D RTE_FC_FULL)) rx_fc_en =3D 1; if ((fc_conf.mode =3D=3D RTE_FC_TX_PAUSE) || (fc_conf.mode =3D=3D RTE_FC_FULL)) tx_fc_en =3D 1; what suggest that rx_fc_en means RX_PAUSE not TX_PAUSE . My personal tests also show, that RTE_FC_TX_PAUSE enables fc on transmissio= n (responds to pause frame). What is the actual desired action? Should rx_fc_en set RTE_FC_RX_PAUSE or R= TE_FC_TX_PAUSE? In the first case, don't you think that the documentation e= ntries are misleading? In later case, does DPDK work correctly and in line = with documentation? Regards Tomasz Konieczny --------------------------------------------------------------------- Intel Corporation (UK) Ltd. Co. Reg. #1134945 Pipers Way, Swindon SN3 1RJ