DPDK patches and discussions
 help / color / mirror / Atom feed
From: Zhirun Yan <zhirun.yan@intel.com>
To: dev@dpdk.org, qi.z.zhang@intel.com
Cc: haiyue.wang@intel.com, Zhirun Yan <zhirun.yan@intel.com>
Subject: [dpdk-dev] [PATCH v1] net/i40e: fix RX/TX setup when restart port
Date: Wed, 28 Nov 2018 16:51:52 +0000	[thread overview]
Message-ID: <20181128165152.78676-1-zhirun.yan@intel.com> (raw)

Before this patch, there are two functions that will clear RX/TX queues
number: rte_eth_dev_close() and i40e_dev_free_queues(). But if also
i40e_dev_free_queues() clear it, RX/TX queues will not set up correctly
when restart port.

Fixes: 6b4537128394 ("i40e: free queue memory when closing")

Signed-off-by: Zhirun Yan <zhirun.yan@intel.com>
Signed-off-by: Haiyue Wang <haiyue.wang@intel.com>
---
 drivers/net/i40e/i40e_rxtx.c | 2 --
 1 file changed, 2 deletions(-)

diff --git a/drivers/net/i40e/i40e_rxtx.c b/drivers/net/i40e/i40e_rxtx.c
index e1152ff0e..cc953ad58 100644
--- a/drivers/net/i40e/i40e_rxtx.c
+++ b/drivers/net/i40e/i40e_rxtx.c
@@ -2753,7 +2753,6 @@ i40e_dev_free_queues(struct rte_eth_dev *dev)
 		i40e_dev_rx_queue_release(dev->data->rx_queues[i]);
 		dev->data->rx_queues[i] = NULL;
 	}
-	dev->data->nb_rx_queues = 0;
 
 	for (i = 0; i < dev->data->nb_tx_queues; i++) {
 		if (!dev->data->tx_queues[i])
@@ -2761,7 +2760,6 @@ i40e_dev_free_queues(struct rte_eth_dev *dev)
 		i40e_dev_tx_queue_release(dev->data->tx_queues[i]);
 		dev->data->tx_queues[i] = NULL;
 	}
-	dev->data->nb_tx_queues = 0;
 }
 
 #define I40E_FDIR_NUM_TX_DESC  I40E_MIN_RING_DESC
-- 
2.17.1

             reply	other threads:[~2018-11-28  9:14 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-11-28 16:51 Zhirun Yan [this message]
     [not found] ` <CGME20181128093221eucas1p119d9c4741bb612ae7fc5700c64e8595a@eucas1p1.samsung.com>
2018-11-28  9:32   ` [dpdk-dev] [v1] " Ilya Maximets
2018-11-30  6:52     ` Yan, Zhirun
  -- strict thread matches above, loose matches on Subject: below --
2018-11-28 16:50 [dpdk-dev] [PATCH v1] " Zhirun Yan

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20181128165152.78676-1-zhirun.yan@intel.com \
    --to=zhirun.yan@intel.com \
    --cc=dev@dpdk.org \
    --cc=haiyue.wang@intel.com \
    --cc=qi.z.zhang@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).