From patchwork Fri Oct 1 13:40:05 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Nithin Dabilpuram X-Patchwork-Id: 100257 X-Patchwork-Delegate: jerinj@marvell.com Return-Path: X-Original-To: patchwork@inbox.dpdk.org Delivered-To: patchwork@inbox.dpdk.org Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 166CDA0032; Fri, 1 Oct 2021 15:41:50 +0200 (CEST) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 1E114411D3; Fri, 1 Oct 2021 15:41:01 +0200 (CEST) Received: from mx0b-0016f401.pphosted.com (mx0b-0016f401.pphosted.com [67.231.156.173]) by mails.dpdk.org (Postfix) with ESMTP id 039FE411D2 for ; Fri, 1 Oct 2021 15:40:59 +0200 (CEST) Received: from pps.filterd (m0045851.ppops.net [127.0.0.1]) by mx0b-0016f401.pphosted.com (8.16.1.2/8.16.1.2) with SMTP id 191A8GOm029756 for ; Fri, 1 Oct 2021 06:40:58 -0700 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=marvell.com; h=from : to : cc : subject : date : message-id : in-reply-to : references : mime-version : content-type; s=pfpt0220; bh=s3AEj0cVHOzn3ymUsKw5bj+A0OtVeJ3qurYPGVPmeLI=; b=Qb85BkB0pZSr/6rE8SXHHUvn+DRY55PbvefhHaQdppGLYSsb2O2A08JNuDH4BMHGXfLt xGmHsOHwViUNQd8ArWNUBMl008U91S9+L8wbUziSjFAYfct8l5mDCaAoTzgFbr+F4JsZ CVMW3cuZ+18+wF5sHEM4kIEuEZr70WbwVB65VbaowD2vcJY6tHz6FIxZ6OYmlsxyKb++ lcfgH5Sc1j3IASMHbeYzSkT3vidvyBwtam3DlXigKfYtSkuBpqpPXPho6BQWvp4osdWQ gmr/WRjp9rHi5clKhLv48pQFiS4IyHBbKq8NLw5GX4nyJMGW3DyxkcFUzufkI+QC5Kqa 7A== Received: from dc5-exch01.marvell.com ([199.233.59.181]) by mx0b-0016f401.pphosted.com with ESMTP id 3bdrxmhxam-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-SHA384 bits=256 verify=NOT) for ; Fri, 01 Oct 2021 06:40:58 -0700 Received: from DC5-EXCH02.marvell.com (10.69.176.39) by DC5-EXCH01.marvell.com (10.69.176.38) with Microsoft SMTP Server (TLS) id 15.0.1497.18; Fri, 1 Oct 2021 06:40:56 -0700 Received: from maili.marvell.com (10.69.176.80) by DC5-EXCH02.marvell.com (10.69.176.39) with Microsoft SMTP Server id 15.0.1497.18 via Frontend Transport; Fri, 1 Oct 2021 06:40:56 -0700 Received: from hyd1588t430.marvell.com (unknown [10.29.52.204]) by maili.marvell.com (Postfix) with ESMTP id AC0DA3F7041; Fri, 1 Oct 2021 06:40:54 -0700 (PDT) From: Nithin Dabilpuram To: , Nithin Dabilpuram , "Kiran Kumar K" , Sunil Kumar Kori , Satha Rao CC: Date: Fri, 1 Oct 2021 19:10:05 +0530 Message-ID: <20211001134022.22700-12-ndabilpuram@marvell.com> X-Mailer: git-send-email 2.8.4 In-Reply-To: <20211001134022.22700-1-ndabilpuram@marvell.com> References: <20210902021505.17607-1-ndabilpuram@marvell.com> <20211001134022.22700-1-ndabilpuram@marvell.com> MIME-Version: 1.0 X-Proofpoint-GUID: sXPgFOBjN1EBALLQCjiuMtLhPTSSOjUU X-Proofpoint-ORIG-GUID: sXPgFOBjN1EBALLQCjiuMtLhPTSSOjUU X-Proofpoint-Virus-Version: vendor=baseguard engine=ICAP:2.0.182.1,Aquarius:18.0.790,Hydra:6.0.391,FMLib:17.0.607.475 definitions=2021-10-01_02,2021-10-01_02,2020-04-07_01 Subject: [dpdk-dev] [PATCH v3 11/28] common/cnxk: restore NIX sqb pool limit before destroy X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" Restore SQB AURA/POOL limit before destroying SQB to be able to drain all the buffers from the aura. Signed-off-by: Nithin Dabilpuram --- drivers/common/cnxk/roc_nix_queue.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/drivers/common/cnxk/roc_nix_queue.c b/drivers/common/cnxk/roc_nix_queue.c index 41a1422..a8a713a 100644 --- a/drivers/common/cnxk/roc_nix_queue.c +++ b/drivers/common/cnxk/roc_nix_queue.c @@ -934,6 +934,11 @@ roc_nix_sq_fini(struct roc_nix_sq *sq) rc |= NIX_ERR_NDC_SYNC; rc |= nix_tm_sq_flush_post(sq); + + /* Restore limit to max SQB count that the pool was created + * for aura drain to succeed. + */ + roc_npa_aura_limit_modify(sq->aura_handle, NIX_MAX_SQB); rc |= roc_npa_pool_destroy(sq->aura_handle); plt_free(sq->fc); plt_free(sq->sqe_mem);