From mboxrd@z Thu Jan  1 00:00:00 1970
Return-Path: <dev-bounces@dpdk.org>
Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124])
	by inbox.dpdk.org (Postfix) with ESMTP id 0FA89A0558;
	Mon,  5 Sep 2022 15:34:21 +0200 (CEST)
Received: from [217.70.189.124] (localhost [127.0.0.1])
	by mails.dpdk.org (Postfix) with ESMTP id E5F6E42B6F;
	Mon,  5 Sep 2022 15:33:37 +0200 (CEST)
Received: from mx0b-0016f401.pphosted.com (mx0b-0016f401.pphosted.com
 [67.231.156.173])
 by mails.dpdk.org (Postfix) with ESMTP id 3F72742B6F
 for <dev@dpdk.org>; Mon,  5 Sep 2022 15:33:36 +0200 (CEST)
Received: from pps.filterd (m0045851.ppops.net [127.0.0.1])
 by mx0b-0016f401.pphosted.com (8.17.1.5/8.17.1.5) with ESMTP id 285DAeOO009446
 for <dev@dpdk.org>; Mon, 5 Sep 2022 06:33:35 -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-transfer-encoding : content-type; s=pfpt0220;
 bh=U9/QMwoytioqR0/0EPXXVzJpncyHHQY9NvxnaXheg6I=;
 b=LPxDww7o5ld7ZfvrOKxP1NuR6I//OQtWohIBDZEX+AsaOK4xjU4/GJK7FYwGxU8vvuqJ
 qNfDUoIZpXIyXqztiKDgmA/y1NOkGtlNUCF/7lk79d9w9oKfVkE8I7KzIWHesxS5ujTD
 GQsCXaG6dc91j0BVZBU1/ImR3wSUT9ZP4MSMjuVskFxZAHhVnSMqWROFNhcMnHpY5Xwb
 UvxM9lKavp4Yc9hFieLJNhE1/y7hfFXZUQFOfF9rzXp574thkFY/xjxUK8URriZoUWOp
 4A2XfkUl/ahx0YXTydri4JCcH0eFlvn0Q1huJXHo6GGI1kf0huQ9rPLYPc2w2/GXoiks Fw== 
Received: from dc5-exch02.marvell.com ([199.233.59.182])
 by mx0b-0016f401.pphosted.com (PPS) with ESMTPS id 3jc6epnghq-1
 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-SHA384 bits=256 verify=NOT)
 for <dev@dpdk.org>; Mon, 05 Sep 2022 06:33:35 -0700
Received: from DC5-EXCH02.marvell.com (10.69.176.39) by DC5-EXCH02.marvell.com
 (10.69.176.39) with Microsoft SMTP Server (TLS) id 15.0.1497.18;
 Mon, 5 Sep 2022 06:33:33 -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; Mon, 5 Sep 2022 06:33:33 -0700
Received: from localhost.localdomain (unknown [10.29.52.204])
 by maili.marvell.com (Postfix) with ESMTP id 9E5DD5E6872;
 Mon,  5 Sep 2022 06:33:31 -0700 (PDT)
From: Nithin Dabilpuram <ndabilpuram@marvell.com>
To: Nithin Dabilpuram <ndabilpuram@marvell.com>, Kiran Kumar K
 <kirankumark@marvell.com>, Sunil Kumar Kori <skori@marvell.com>, Satha Rao
 <skoteshwar@marvell.com>
CC: <jerinj@marvell.com>, <dev@dpdk.org>
Subject: [PATCH v2 21/31] net/cnxk: skip PFC configuration on LBK
Date: Mon, 5 Sep 2022 19:02:18 +0530
Message-ID: <20220905133228.818616-21-ndabilpuram@marvell.com>
X-Mailer: git-send-email 2.25.1
In-Reply-To: <20220905133228.818616-1-ndabilpuram@marvell.com>
References: <20220809184908.24030-1-ndabilpuram@marvell.com>
 <20220905133228.818616-1-ndabilpuram@marvell.com>
MIME-Version: 1.0
Content-Transfer-Encoding: 8bit
Content-Type: text/plain
X-Proofpoint-ORIG-GUID: ImkMBbQnUX7vLCIMV-qGMwThtBvlAHdS
X-Proofpoint-GUID: ImkMBbQnUX7vLCIMV-qGMwThtBvlAHdS
X-Proofpoint-Virus-Version: vendor=baseguard
 engine=ICAP:2.0.205,Aquarius:18.0.895,Hydra:6.0.517,FMLib:17.11.122.1
 definitions=2022-09-05_09,2022-09-05_02,2022-06-22_01
X-BeenThere: dev@dpdk.org
X-Mailman-Version: 2.1.29
Precedence: list
List-Id: DPDK patches and discussions <dev.dpdk.org>
List-Unsubscribe: <https://mails.dpdk.org/options/dev>,
 <mailto:dev-request@dpdk.org?subject=unsubscribe>
List-Archive: <http://mails.dpdk.org/archives/dev/>
List-Post: <mailto:dev@dpdk.org>
List-Help: <mailto:dev-request@dpdk.org?subject=help>
List-Subscribe: <https://mails.dpdk.org/listinfo/dev>,
 <mailto:dev-request@dpdk.org?subject=subscribe>
Errors-To: dev-bounces@dpdk.org

From: Satha Rao <skoteshwar@marvell.com>

CNXK platforms do not support PFC on LBK so skipping
configuration on LBK interfaces.

Signed-off-by: Satha Rao <skoteshwar@marvell.com>
---
 drivers/net/cnxk/cnxk_ethdev.c     | 2 +-
 drivers/net/cnxk/cnxk_ethdev_ops.c | 4 ++--
 2 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/drivers/net/cnxk/cnxk_ethdev.c b/drivers/net/cnxk/cnxk_ethdev.c
index 85ad70e50b..0603d73a90 100644
--- a/drivers/net/cnxk/cnxk_ethdev.c
+++ b/drivers/net/cnxk/cnxk_ethdev.c
@@ -1860,7 +1860,7 @@ cnxk_eth_dev_uninit(struct rte_eth_dev *eth_dev, bool reset)
 		pfc_conf.tx_pause.rx_qid = i;
 		rc = cnxk_nix_priority_flow_ctrl_queue_config(eth_dev,
 							      &pfc_conf);
-		if (rc)
+		if (rc && rc != -ENOTSUP)
 			plt_err("Failed to reset PFC. error code(%d)", rc);
 	}
 
diff --git a/drivers/net/cnxk/cnxk_ethdev_ops.c b/drivers/net/cnxk/cnxk_ethdev_ops.c
index 1592971073..64beabdd12 100644
--- a/drivers/net/cnxk/cnxk_ethdev_ops.c
+++ b/drivers/net/cnxk/cnxk_ethdev_ops.c
@@ -356,8 +356,8 @@ cnxk_nix_priority_flow_ctrl_queue_config(struct rte_eth_dev *eth_dev,
 		return -ENOTSUP;
 	}
 
-	if (roc_nix_is_sdp(nix)) {
-		plt_err("Prio flow ctrl config is not allowed on SDP");
+	if (roc_nix_is_sdp(nix) || roc_nix_is_lbk(nix)) {
+		plt_nix_dbg("Prio flow ctrl config is not allowed on SDP/LBK");
 		return -ENOTSUP;
 	}
 
-- 
2.25.1