Set the TRUFLOW Enable bit in bp->flags only if the value passed in
devargs was 1. Otherwise set it to 0.
Fixes:
313ac35ac701 ("net/bnxt: support ULP session manager init")
Cc: stable@dpdk.org
Signed-off-by: Somnath Kotur <somnath.kotur@broadcom.com>
Reviewed-by: Venkat Duvvuru <venkatkumar.duvvuru@broadcom.com>
Reviewed-by: Mike Baucom <michael.baucom@broadcom.com>
Reviewed-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
return -EINVAL;
}
- bp->flags |= BNXT_FLAG_TRUFLOW_EN;
- if (BNXT_TRUFLOW_EN(bp))
+ if (truflow) {
+ bp->flags |= BNXT_FLAG_TRUFLOW_EN;
PMD_DRV_LOG(INFO, "Host-based truflow feature enabled.\n");
+ } else {
+ bp->flags &= ~BNXT_FLAG_TRUFLOW_EN;
+ PMD_DRV_LOG(INFO, "Host-based truflow feature disabled.\n");
+ }
return 0;
}