From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wr0-f171.google.com (mail-wr0-f171.google.com [209.85.128.171]) by dpdk.org (Postfix) with ESMTP id 2CA412A5E for ; Thu, 2 Mar 2017 14:43:29 +0100 (CET) Received: by mail-wr0-f171.google.com with SMTP id u108so52372886wrb.3 for ; Thu, 02 Mar 2017 05:43:29 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=6wind-com.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=9cXja6ebqIEK16cWOla/nGvd9FgplLSW0S+22JauXec=; b=yHKgcC167Ks/7nv6WFXC/ekFLAOqXZngAPdrnKLJ4rgOKYHp6OREXM4GW1INzD2uMX hcK+se+5P3IlZ27bEVsfz3VBgKzixyMqZFF1/N5h74sWGAjhr7me3l0pxy1ZltHUYzAu 0uXc+5fE/c9JR+hoGucnWZ9w/CIm1IswlJywK/xjQuto3kLJCtzXRCSr2j//cDFqpg0B n2AMfAervvzz4oFeW+dKw1F+AdwKbuZhMLchF3/i1Og8jWhabAEhCv455wa+M8qeqOi7 B888Zu6FGm112NE/QsVjy67Q4ML26loYoc1idWLzkIzo5AQj5zeH9Rgeg8N6bYSNht9S 8Jng== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=9cXja6ebqIEK16cWOla/nGvd9FgplLSW0S+22JauXec=; b=qtyoHjIzFIluvZSaxl9989LCP5RAKUsltyTh9KHUJRoCcmtM87Cy5kOI5l+8o4e4dZ tkvBqiL26gH2DL+Cf+9aKrizZcLmejdVi9c3w9D+Ti/Cw7iIFaQzPfiRPJfV4TYBmdIW le6QlMCGrSa6Y7bzF0oc/zo/2Zt9ya7vZDmTYOrKRsVawFr35FPgyVmD9Ojbrndbxdph Qnh+HpAQFUw/m0YDbZgki/0PU9GRVXcrc65eaGx8eRzNHxFpPm1v3C3+c3xNUNFADO5/ vvH/YXN2HEFCKFOLWOkEfw43xoRdmusyfb/vf2Asx03FZSM203dfI2qzDM4o5v+bB722 o7nw== X-Gm-Message-State: AMke39kqlfjq4ZF5J6fNKrCzdMRbR6rIVe2BAw5SumnohnI9CPv/dQldLC9lojwVcY0PrsU/ X-Received: by 10.223.128.231 with SMTP id 94mr11934445wrl.165.1488462208863; Thu, 02 Mar 2017 05:43:28 -0800 (PST) Received: from platinum (2a01cb0c03c651000226b0fffeed02fc.ipv6.abo.wanadoo.fr. [2a01:cb0c:3c6:5100:226:b0ff:feed:2fc]) by smtp.gmail.com with ESMTPSA id v18sm10942455wrc.41.2017.03.02.05.43.28 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Thu, 02 Mar 2017 05:43:28 -0800 (PST) Date: Thu, 2 Mar 2017 14:43:26 +0100 From: Olivier Matz To: Stephen Hemminger Cc: dev@dpdk.org, thomas.monjalon@6wind.com, konstantin.ananyev@intel.com, wenzhuo.lu@intel.com, helin.zhang@intel.com, jingjing.wu@intel.com, adrien.mazarguil@6wind.com, nelio.laranjeiro@6wind.com, ferruh.yigit@intel.com, bruce.richardson@intel.com Message-ID: <20170302144326.7d65fc39@platinum> In-Reply-To: <20170301100706.5df566fb@xeon-e3> References: <1479981261-19512-1-git-send-email-olivier.matz@6wind.com> <1488388752-1819-1-git-send-email-olivier.matz@6wind.com> <20170301100706.5df566fb@xeon-e3> X-Mailer: Claws Mail 3.14.1 (GTK+ 2.24.31; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Subject: Re: [dpdk-dev] [PATCH 0/6] get status of Rx and Tx descriptors 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: , X-List-Received-Date: Thu, 02 Mar 2017 13:43:29 -0000 Hi Stephen, On Wed, 1 Mar 2017 10:07:06 -0800, Stephen Hemminger wrote: > On Wed, 1 Mar 2017 18:19:06 +0100 > Olivier Matz wrote: > > > This patchset introduces a new ethdev API: > > - rte_eth_rx_descriptor_status() > > - rte_eth_tx_descriptor_status() > > > > The Rx API is aims to replace rte_eth_rx_descriptor_done() which > > does almost the same, but does not differentiate the case of a > > descriptor used by the driver (not returned to the hw). > > > > The usage of these functions can be: > > - on Rx, anticipate that the cpu is not fast enough to process > > all incoming packets, and take dispositions to solve the > > problem (add more cpus, drop specific packets, ...) > > - on Tx, detect that the link is overloaded, and take dispositions > > to solve the problem (notify flow control, drop specific > > packets) > > > > The patchset updates ixgbe, i40e, e1000, mlx5. > > The other drivers that implement the descriptor_done() API are > > fm10k, sfc, virtio. They are not updated. > > If the new API is accepted, the descriptor_done() can be deprecated, > > and examples/l3fwd-power will be updated to. > > > > > > RFC->v1: > > - instead of optimizing an API that returns the number of used > > descriptors like rx_queue_count(), use a more simple API that > > returns the status of a descriptor, like rx_descriptor_done(). > > - remove ethdev api rework (first 2 patches), they have been > > sent separately > > > > > > Olivier Matz (6): > > ethdev: add descriptor status API > > net/ixgbe: implement descriptor status API > > net/e1000: implement descriptor status API (igb) > > net/e1000: implement descriptor status API (em) > > net/mlx5: implement descriptor status API > > net/i40e: implement descriptor status API > > > > drivers/net/e1000/e1000_ethdev.h | 10 +++++ > > drivers/net/e1000/em_ethdev.c | 2 + > > drivers/net/e1000/em_rxtx.c | 49 ++++++++++++++++++++++ > > drivers/net/e1000/igb_ethdev.c | 2 + > > drivers/net/e1000/igb_rxtx.c | 46 +++++++++++++++++++++ > > drivers/net/i40e/i40e_ethdev.c | 2 + > > drivers/net/i40e/i40e_ethdev_vf.c | 2 + > > drivers/net/i40e/i40e_rxtx.c | 56 +++++++++++++++++++++++++ > > drivers/net/i40e/i40e_rxtx.h | 4 ++ > > drivers/net/ixgbe/ixgbe_ethdev.c | 4 ++ > > drivers/net/ixgbe/ixgbe_ethdev.h | 5 +++ > > drivers/net/ixgbe/ixgbe_rxtx.c | 55 +++++++++++++++++++++++++ > > drivers/net/mlx5/mlx5.c | 2 + > > drivers/net/mlx5/mlx5_rxtx.c | 83 +++++++++++++++++++++++++++++++++++++ > > drivers/net/mlx5/mlx5_rxtx.h | 2 + > > lib/librte_ether/rte_ethdev.h | 86 +++++++++++++++++++++++++++++++++++++++ > > 16 files changed, 410 insertions(+) > > > > Could you update examples to use this? I can update examples/l3fwd-power, but it will break the support for drivers that do not implement the new API. Maybe we could do this in a second time, after all drivers are converted?