From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 7E968A0352 for ; Mon, 4 Nov 2019 21:28:05 +0100 (CET) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 57454316B; Mon, 4 Nov 2019 21:28:05 +0100 (CET) Received: from mail-wr1-f68.google.com (mail-wr1-f68.google.com [209.85.221.68]) by dpdk.org (Postfix) with ESMTP id 6E906316B for ; Mon, 4 Nov 2019 21:28:04 +0100 (CET) Received: by mail-wr1-f68.google.com with SMTP id e6so16811540wrw.1 for ; Mon, 04 Nov 2019 12:28:04 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=M2nRTntGiu4TTthuOQ1BJ2zi3KXvs6/yIXcp//uqdaA=; b=Nh7X0Ipy3SB5bdjFOFvU2/rMXF3SBmT3aLpXU8Vya1G0Y54RE+2Tlzh2FVlvLLrFId lGdMicvYQ5VuTiZ71JL+ucN1/dWJU3Ti2HjvU3KZUwYcAqBFe9OxUxiJR2dX+XciYNSS BwNvLQFgPZS6PHYhTWc4p+1HXcwT6xSDXAsIg= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=M2nRTntGiu4TTthuOQ1BJ2zi3KXvs6/yIXcp//uqdaA=; b=ULUG0N2HlMG/xmZwbv1IQ7p6oSSPgeEgO6O9IhOIyHmP+JKJ6+itONmiUHA1slZ/oQ k5r0FGmAAI2cw+lbeUuxJnu9luX3dSBx5FBNwRRbxvO9Ku2TIDpcG2OXuBQjnGoWGA1+ xGU63WoImITj8oMxXwjzN85aIjgYbi6hPfDvTj+fK8hNlcZopSd+eHR1FFgDFGHM6w9O 2k60Oa5R0+6SzcM3Glom3qzujZVQthjJ2fCNsy/LnpZMks6xUgAzYDYSZg/scy7JhjgY EOCOhYqWXXXUjoBuoowxL5SJ4KuhQnl7CstjbvcCyqzKrHP0VRNco4h9T/6Af/LnCVee kmrw== X-Gm-Message-State: APjAAAWW0CeiJMjExQKsuhMLcbIxADlAX9Ymn1PSgdf3v0ICy+ykaOnG cBqfusyiFSTNddEf9O9MeJ8t604cjFE= X-Google-Smtp-Source: APXvYqwXqpADjvC0fMeioXH4ji2j6FCOBWTTtbWBMiiUCFc8TvnE3eb+UBG/W8WanP/YVxbVfRIf5Q== X-Received: by 2002:a05:6000:12c7:: with SMTP id l7mr7594068wrx.128.1572899284199; Mon, 04 Nov 2019 12:28:04 -0800 (PST) Received: from lrichardson-VirtualBox.dhcp.broadcom.net ([192.19.231.250]) by smtp.gmail.com with ESMTPSA id i3sm17995365wrw.69.2019.11.04.12.28.02 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 04 Nov 2019 12:28:03 -0800 (PST) From: Lance Richardson To: dev@dpdk.org Cc: ajit.khaparde@broadcom.com, ferruh.yigit@intel.com, Lance Richardson , stable@dpdk.org Date: Mon, 4 Nov 2019 15:27:45 -0500 Message-Id: <20191104202747.12897-3-lance.richardson@broadcom.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20191104202747.12897-1-lance.richardson@broadcom.com> References: <20191104202747.12897-1-lance.richardson@broadcom.com> Subject: [dpdk-stable] [PATCH 2/4] net/bnxt: keep consistent rxq start/stop state X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: stable-bounces@dpdk.org Sender: "stable" Receive queue state needs to reflect "started" state when rebuilding the RSS table for Thor-based NICs. Move state update so that receive queues being started are included in the RSS table. Fixes: 38412304b50a ("net/bnxt: enable RSS for thor-based controllers") Cc: stable@dpdk.org Signed-off-by: Lance Richardson Reviewed-by: Ajit Kumar Khaparde Signed-off-by: Ajit Khaparde --- drivers/net/bnxt/bnxt_rxq.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/drivers/net/bnxt/bnxt_rxq.c b/drivers/net/bnxt/bnxt_rxq.c index ab889c10e..e82eda9d7 100644 --- a/drivers/net/bnxt/bnxt_rxq.c +++ b/drivers/net/bnxt/bnxt_rxq.c @@ -444,6 +444,8 @@ int bnxt_rx_queue_start(struct rte_eth_dev *dev, uint16_t rx_queue_id) * If queue is it started, we do not post buffers for Rx. */ rxq->rx_started = true; + dev->data->rx_queue_state[rx_queue_id] = RTE_ETH_QUEUE_STATE_STARTED; + bnxt_free_hwrm_rx_ring(bp, rx_queue_id); rc = bnxt_alloc_hwrm_rx_ring(bp, rx_queue_id); if (rc) @@ -469,11 +471,11 @@ int bnxt_rx_queue_start(struct rte_eth_dev *dev, uint16_t rx_queue_id) rc = bnxt_vnic_rss_configure(bp, vnic); } - if (rc == 0) + if (rc != 0) { dev->data->rx_queue_state[rx_queue_id] = - RTE_ETH_QUEUE_STATE_STARTED; - else + RTE_ETH_QUEUE_STATE_STOPPED; rxq->rx_started = false; + } PMD_DRV_LOG(INFO, "queue %d, rx_deferred_start %d, state %d!\n", -- 2.17.1