From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by dpdk.org (Postfix) with ESMTP id 53B92212 for ; Wed, 1 Oct 2014 23:55:14 +0200 (CEST) Received: from azsmga001.ch.intel.com ([10.2.17.19]) by orsmga102.jf.intel.com with ESMTP; 01 Oct 2014 14:55:41 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.04,635,1406617200"; d="scan'208";a="481360428" Received: from jrharri1-fbsd.ch.intel.com ([10.2.43.47]) by azsmga001.ch.intel.com with ESMTP; 01 Oct 2014 15:01:59 -0700 To: dev@dpdk.org From: Jim Harris Date: Wed, 01 Oct 2014 15:00:21 -0700 Message-ID: <20141001220021.19571.38617.stgit@jrharri1-fbsd.ch.intel.com> User-Agent: StGit/0.16 MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Subject: [dpdk-dev] [PATCH] i40e: fix i40e_reset_tx_queue cmd_type_offset_bsz init X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 01 Oct 2014 21:55:14 -0000 Fix the descriptor initialization loop, so that it initializes the i40e_tx_desc::cmd_type_offset_bsz for the correct index into the tx_ring array. Previously it would use the index once to initialize the txd local variable, then again when setting cmd_type_offset_bsz. Signed-off-by: Jim Harris --- lib/librte_pmd_i40e/i40e_rxtx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/librte_pmd_i40e/i40e_rxtx.c b/lib/librte_pmd_i40e/i40e_rxtx.c index 7c5b6a8..2b53677 100644 --- a/lib/librte_pmd_i40e/i40e_rxtx.c +++ b/lib/librte_pmd_i40e/i40e_rxtx.c @@ -2072,7 +2072,7 @@ i40e_reset_tx_queue(struct i40e_tx_queue *txq) for (i = 0; i < txq->nb_tx_desc; i++) { volatile struct i40e_tx_desc *txd = &txq->tx_ring[i]; - txd[i].cmd_type_offset_bsz = + txd->cmd_type_offset_bsz = rte_cpu_to_le_64(I40E_TX_DESC_DTYPE_DESC_DONE); txe[i].mbuf = NULL; txe[i].last_id = i;