From mboxrd@z Thu Jan 1 00:00:00 1970 From: Qi Zhang Subject: [PATCH v5 0/3] runtime queue setup Date: Mon, 2 Apr 2018 10:59:32 +0800 Message-ID: <20180402025935.33312-1-qi.z.zhang@intel.com> References: <20180212045314.171616-1-qi.z.zhang@intel.com> Cc: dev@dpdk.org, beilei.xing@intel.com, jingjing.wu@intel.com, wenzhuo.lu@intel.com, Qi Zhang To: thomas@monjalon.net, konstantin.ananyev@intel.com Return-path: Received: from mga07.intel.com (mga07.intel.com [134.134.136.100]) by dpdk.org (Postfix) with ESMTP id 07C5634F3 for ; Mon, 2 Apr 2018 04:59:32 +0200 (CEST) In-Reply-To: <20180212045314.171616-1-qi.z.zhang@intel.com> List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" v5: - fix first tx queue check in i40e. v4: - fix i40e rx/tx funciton conflict handle. - no need conflict check for first rx/tx queue at runtime setup. - fix missing offload paramter in testpmd cmdline. v3: - not overload deferred start. - rename deferred setup to runtime setup. - remove unecessary testpmd parameters (patch 2/4 of v2) - add offload support to testpmd queue setup command line - i40e fix: return fail when required rx/tx function conflict with exist setup. v2: - enhance comment in rte_ethdev.h According to exist implementation,rte_eth_[rx|tx]_queue_setup will always return fail if device is already started(rte_eth_dev_start). This can't satisfied the usage when application want to deferred setup part of the queues while keep traffic running on those queues already be setup. example: rte_eth_dev_config(nb_rxq = 2, nb_txq =2) rte_eth_rx_queue_setup(idx = 0 ...) rte_eth_rx_queue_setup(idx = 0 ...) rte_eth_dev_start(...) /* [rx|tx]_burst is ready to start on queue 0 */ rte_eth_rx_queue_setup(idx=1 ...) /* fail*/ Basically this is not a general hardware limitation, because for NIC like i40e, ixgbe, it is not necessary to stop the whole device before configure a fresh queue or reconfigure an exist queue with no traffic on it. The patch let etherdev driver expose the capability flag through rte_eth_dev_info_get when it support deferred queue configuraiton, then base on these flag, rte_eth_[rx|tx]_queue_setup could decide continue to setup the queue or just return fail when device already started. Qi Zhang (3): ether: support runtime queue setup app/testpmd: add command for queue setup net/i40e: enable runtime queue setup app/test-pmd/cmdline.c | 129 ++++++++++++++++++++ doc/guides/nics/features.rst | 8 ++ doc/guides/testpmd_app_ug/testpmd_funcs.rst | 7 ++ drivers/net/i40e/i40e_ethdev.c | 4 + drivers/net/i40e/i40e_rxtx.c | 183 ++++++++++++++++++++++++---- lib/librte_ether/rte_ethdev.c | 30 +++-- lib/librte_ether/rte_ethdev.h | 7 ++ 7 files changed, 333 insertions(+), 35 deletions(-) -- 2.13.6