Skip to contentSkip to conversation

be2net: supress printing error when mac query fails for VF

PATCH Applied Ajit Khaparde 2 participants 3 messages Jul 23, 2010

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 5/7 be2net: supress printing error when mac query fails for VF

When a virtual function driver in initialized, the network mac query command can fail. Skip display of error message in that case.

---
 drivers/net/benet/be_cmds.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)
drivers/net/benet/be_cmds.c +2 -1
index 32ae324..cf3af05 100644
@@ -76,7 +76,8 @@ static int be_mcc_compl_process(struct be_adapter *adapter,
 						sizeof(resp->hw_stats));
 			netdev_stats_update(adapter);
 		}
-	} else if (compl_status != MCC_STATUS_NOT_SUPPORTED) {
+	} else if ((compl_status != MCC_STATUS_NOT_SUPPORTED) &&
+			(compl->tag0 != OPCODE_COMMON_NTWK_MAC_QUERY)) {
 		extd_status = (compl->status >> CQE_STATUS_EXTD_SHIFT) &
 				CQE_STATUS_EXTD_MASK;
 		dev_warn(&adapter->pdev->dev,
Signature · 1 line
1.7.0.4
maintainer
#1 lore raw

From: Ajit Khaparde <[email protected]>
Date: Fri, 23 Jul 2010 17:30:24 +0530

drivers/net/benet/be_cmds.c static int be_mcc_compl_process(struct be_adapter *adapter, · line 80

Quoted 3 lines
drivers/net/benet/be_cmds.c +2 -1
-	} else if (compl_status != MCC_STATUS_NOT_SUPPORTED) {
+	} else if ((compl_status != MCC_STATUS_NOT_SUPPORTED) &&
+			(compl->tag0 != OPCODE_COMMON_NTWK_MAC_QUERY)) {

I'll fix up this formatting when applying this patch but please be mindful of this in the future, it should look like:

	} else if ((compl_status != MCC_STATUS_NOT_SUPPORTED) &&
		   (compl->tag0 != OPCODE_COMMON_NTWK_MAC_QUERY)) {