From: Mike Baucom Date: Thu, 12 Nov 2020 15:29:45 +0000 (-0800) Subject: net/bnxt: fix assignment instead of comparison X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=fcf681890a31a7396df2b85b2888074c5b939535;p=dpdk.git net/bnxt: fix assignment instead of comparison Use comparison operator instead of incorrectly using the assignment operator. Coverity issue: 363566, 36357 Fixes: 42c40f8902f7 ("net/bnxt: consolidate template table processing") Signed-off-by: Mike Baucom Reviewed-by: Ajit Khaparde --- diff --git a/drivers/net/bnxt/tf_ulp/ulp_mapper.c b/drivers/net/bnxt/tf_ulp/ulp_mapper.c index 29643232d8..429e7fcfee 100644 --- a/drivers/net/bnxt/tf_ulp/ulp_mapper.c +++ b/drivers/net/bnxt/tf_ulp/ulp_mapper.c @@ -2522,7 +2522,7 @@ ulp_mapper_tbls_process(struct bnxt_ulp_mapper_parms *parms, uint32_t tid) tbls = ulp_mapper_tbl_list_get(parms, tid, &num_tbls); if (!tbls || !num_tbls) { BNXT_TF_DBG(ERR, "No %s tables for %d:%d\n", - (parms->tmpl_type = BNXT_ULP_TEMPLATE_TYPE_CLASS) ? + (parms->tmpl_type == BNXT_ULP_TEMPLATE_TYPE_CLASS) ? "class" : "action", parms->dev_id, tid); return -EINVAL; } @@ -2569,7 +2569,7 @@ ulp_mapper_tbls_process(struct bnxt_ulp_mapper_parms *parms, uint32_t tid) return rc; error: BNXT_TF_DBG(ERR, "%s tables failed creation for %d:%d\n", - (parms->tmpl_type = BNXT_ULP_TEMPLATE_TYPE_CLASS) ? + (parms->tmpl_type == BNXT_ULP_TEMPLATE_TYPE_CLASS) ? "class" : "action", parms->dev_id, tid); return rc; }