[10/10] net/bnxt: remove a useless check in validate flow routine
diff mbox series

Message ID 20191004050246.90165-11-ajit.khaparde@broadcom.com
State Accepted, archived
Delegated to: Ferruh Yigit
Headers show
Series
  • bnxt patchset with bug fixes
Related show

Checks

Context Check Description
ci/checkpatch success coding style OK
ci/Intel-compilation success Compilation OK

Commit Message

Ajit Khaparde Oct. 4, 2019, 5:02 a.m. UTC
From: Kalesh AP <kalesh-anakkur.purayil@broadcom.com>

Since vnic->rx_queue_cnt is already checked against non-zero,
removed the useless check from the inside condition check.

Fixes: 4be31562a4ba ("net/bnxt: allow flow creation when RSS is enabled")

Signed-off-by: Kalesh AP <kalesh-anakkur.purayil@broadcom.com>
Reviewed-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
---
 drivers/net/bnxt/bnxt_flow.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

Comments

Ferruh Yigit Oct. 8, 2019, 9:03 a.m. UTC | #1
On 10/4/2019 6:02 AM, Ajit Khaparde wrote:
> From: Kalesh AP <kalesh-anakkur.purayil@broadcom.com>
> 
> Since vnic->rx_queue_cnt is already checked against non-zero,
> removed the useless check from the inside condition check.
> 
> Fixes: 4be31562a4ba ("net/bnxt: allow flow creation when RSS is enabled")
> 
> Signed-off-by: Kalesh AP <kalesh-anakkur.purayil@broadcom.com>
> Reviewed-by: Ajit Khaparde <ajit.khaparde@broadcom.com>

Squashed into relevant commit in next-net, thanks.

(please send new version of the patchset on top of latest next-net)

Patch
diff mbox series

diff --git a/drivers/net/bnxt/bnxt_flow.c b/drivers/net/bnxt/bnxt_flow.c
index d753a334b9..5aeb001408 100644
--- a/drivers/net/bnxt/bnxt_flow.c
+++ b/drivers/net/bnxt/bnxt_flow.c
@@ -1067,8 +1067,7 @@  bnxt_validate_and_parse_flow(struct rte_eth_dev *dev,
 			goto ret;
 		}
 		if (vnic->rx_queue_cnt) {
-			if (vnic->rx_queue_cnt > 1 ||
-			    vnic->start_grp_id != act_q->index) {
+			if (vnic->start_grp_id != act_q->index) {
 				PMD_DRV_LOG(ERR,
 					    "VNIC already in use\n");
 				rte_flow_error_set(error,