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 D8C59A00C3; Wed, 8 Jun 2022 11:43:50 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id CA04740689; Wed, 8 Jun 2022 11:43:50 +0200 (CEST) Received: from shelob.oktetlabs.ru (shelob.oktetlabs.ru [91.220.146.113]) by mails.dpdk.org (Postfix) with ESMTP id BC4FA4021D for ; Wed, 8 Jun 2022 11:43:49 +0200 (CEST) Received: from [192.168.1.40] (unknown [188.170.81.145]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by shelob.oktetlabs.ru (Postfix) with ESMTPSA id E2591307; Wed, 8 Jun 2022 12:43:48 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 shelob.oktetlabs.ru E2591307 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=oktetlabs.ru; s=default; t=1654681429; bh=wIueMnrJi0QLCPoBQGdup4G5bmQGel21kY7w41QgZLY=; h=Date:Subject:To:Cc:References:From:In-Reply-To:From; b=YukEArBaTMs+j8QhYqbr3bZ+yi4+/Kq7e74TFmeWJygFpR+e1gEZo3Pu2kDKJC+8U pYV709JRQrGtw2SE+/GqnS6vDhMvwUGKD+ZvLwl1WNHf5Sf/h9BPLDEFgS65DuARQx 8QyGlNcSJNiUSzbrMX+ihFFa347TyNSIYOHQr+ak= Message-ID: <040541c4-fc22-b9ac-8442-c904baae15b9@oktetlabs.ru> Date: Wed, 8 Jun 2022 12:43:41 +0300 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.9.0 Subject: Re: [PATCH v5 0/7] introduce per-queue available descriptor threshold and host shaper Content-Language: en-US To: Spike Du , matan@nvidia.com, viacheslavo@nvidia.com, orika@nvidia.com, thomas@monjalon.net Cc: stephen@networkplumber.org, mb@smartsharesystems.com, dev@dpdk.org, rasland@nvidia.com References: <20220603124821.1148119-1-spiked@nvidia.com> <20220607125942.241379-1-spiked@nvidia.com> From: Andrew Rybchenko In-Reply-To: <20220607125942.241379-1-spiked@nvidia.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit 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 @Matan, @Viacheslav, could you review mlx5 patches of the series, please. On 6/7/22 15:59, Spike Du wrote: > available descriptor threshold(ADT for short) is per RX queue attribute, when RX queue available descriptors for HW is below ADT, HW sends an event to application. > Host shaper can configure shaper rate and avail_thresh-triggered for a host port. > The shaper limits the rate of traffic from host port to embedded ARM rx port on Nvidia BlueField 2 NIC. > If avail_thresh-triggered is enabled, a 100Mbps shaper is enabled automatically when one of the host port's Rx queues receives available descriptor threshold event. > > These two features can combine to control traffic from host port to wire port for BlueField 2 NIC. > The traffic flows from host to embedded ARM, then to the physical port. > The work flow is on the ARM system, configure available descriptor threshold to RX queue and enable avail_thresh-triggered flag in host shaper, after receiving available descriptor threshold event, delay a while until RX queue is empty , then disable the shaper. We recycle this work flow to reduce RX queue drops on ARM system. > > Add new libethdev API to set available descriptor threshold, add rte event RTE_ETH_EVENT_RX_AVAIL_THRESH to handle available descriptor threshold event. For host shaper, because it doesn't align to existing DPDK framework and is specific to Nvidia NIC, use PMD private API. > > For integration with testpmd, put the private cmdline function and available descriptor threshold event handler in mlx5 PMD directory by adding a new file mlx5_testpmd.c. Follow David Marchand's driver specific commands framework to add mlx5 specific commands. > > > Spike Du (7): > net/mlx5: add LWM support for Rxq > common/mlx5: share interrupt management > ethdev: introduce Rx queue based available descriptor threshold > net/mlx5: add LWM event handling support > net/mlx5: support Rx queue based available descriptor threshold > net/mlx5: add private API to config host port shaper > app/testpmd: add Host Shaper command