Skip to contentSkip to conversation

fixes to bnxt PMD

PATCH In review Ajit Khaparde 1 participant 4 messages Jul 30, 2021 Network drivers

lore
Share & tools
lore
#0 lore raw

cover fixes to bnxt PMD

Fixes to bnxt PMD to address compatibility issues with different FW versions.

Jay Ding (1):
net/bnxt: fix resource qcap list handling

Kishore Padmanabha (1):
net/bnxt: fix stats counter resource

 drivers/net/bnxt/tf_core/tf_msg.c                    | 12 ++++++------
 .../tf_ulp/generic_templates/ulp_template_db_tbl.c   |  4 ++--
 2 files changed, 8 insertions(+), 8 deletions(-)
Signature · 1 line
2.21.1 (Apple Git-122.3)
#1 lore raw

PATCH 1/2 net/bnxt: fix resource qcap list handling

From: Jay Ding <[email protected]>

The size of resource qcap list could be different when FW and application are not match. Application should be able to handle it when the FW is older and the size of qcap is smaller.

This patch is needed for backward compatibility on older firmware versions.

Fixes 873661aa641a1 ("net/bnxt: support shared session")
---
 drivers/net/bnxt/tf_core/tf_msg.c | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)
drivers/net/bnxt/tf_core/tf_msg.c +6 -6
index 6717710dbd..e07d9168be 100644
@@ -440,18 +440,18 @@ tf_msg_session_resc_qcaps(struct tf *tfp,
 	 * Should always get expected number of entries
 	 */
 	if (tfp_le_to_cpu_32(resp.size) != size) {
-		TFP_DRV_LOG(ERR,
-			    "%s: QCAPS message size error, rc:%s\n",
+		TFP_DRV_LOG(WARNING,
+			    "%s: QCAPS message size error, rc:%s, request %d vs response %d\n",
 			    tf_dir_2_str(dir),
-			    strerror(EINVAL));
-		rc = -EINVAL;
-		goto cleanup;
+			    strerror(EINVAL),
+			    size,
+			    resp.size);
 	}
 
 	/* Post process the response */
 	data = (struct tf_rm_resc_req_entry *)qcaps_buf.va_addr;
 
-	for (i = 0; i < size; i++) {
+	for (i = 0; i < resp.size; i++) {
 		query[i].type = tfp_le_to_cpu_32(data[i].type);
 		query[i].min = tfp_le_to_cpu_16(data[i].min);
 		query[i].max = tfp_le_to_cpu_16(data[i].max);
Signature · 1 line
2.21.1 (Apple Git-122.3)
#2 lore raw

PATCH 2/2 net/bnxt: fix stats counter resource

In reply to Ajit Khaparde

From: Kishore Padmanabha <[email protected]>

The flow counters is reduced from 8192 to 6912 for Whitney for compatibility with different versions of FW.

Fixes 6fad9115101c ("net/bnxt: reorganize ULP template directory structure")
---
 .../net/bnxt/tf_ulp/generic_templates/ulp_template_db_tbl.c   | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/net/bnxt/tf_ulp/generic_templates/ulp_template_db_tbl.c +2 -2
index 6664353764..7951de8a4e 100644
@@ -1154,7 +1154,7 @@ struct bnxt_ulp_resource_resv_info ulp_resource_resv_list[] = {
 	.direction               = TF_DIR_RX,
 	.resource_func           = BNXT_ULP_RESOURCE_FUNC_INDEX_TABLE,
 	.resource_type           = TF_TBL_TYPE_ACT_STATS_64,
-	.count                   = 8192
+	.count                   = 6912
 	},
 	{
 	.app_id                  = 0,
@@ -1298,7 +1298,7 @@ struct bnxt_ulp_resource_resv_info ulp_resource_resv_list[] = {
 	.direction               = TF_DIR_TX,
 	.resource_func           = BNXT_ULP_RESOURCE_FUNC_INDEX_TABLE,
 	.resource_type           = TF_TBL_TYPE_ACT_STATS_64,
-	.count                   = 8192
+	.count                   = 6912
 	},
 	{
 	.app_id                  = 0,
Signature · 1 line
2.21.1 (Apple Git-122.3)
#3 lore raw
In reply to Ajit Khaparde
Quoted 2 lines · Ajit Khaparde

Fixes to bnxt PMD to address compatibility issues with different FW versions.

Patches applied to dpdk-next-net-brcm.

Quoted 14 lines

Jay Ding (1):
net/bnxt: fix resource qcap list handling

Kishore Padmanabha (1):
net/bnxt: fix stats counter resource

 drivers/net/bnxt/tf_core/tf_msg.c                    | 12 ++++++------
 .../tf_ulp/generic_templates/ulp_template_db_tbl.c   |  4 ++--
 2 files changed, 8 insertions(+), 8 deletions(-)

--
2.21.1 (Apple Git-122.3)