Such check is already done at an earlier point, in sfc_flow_parse_pattern(), so remove it from IPv4 item parser. Doing so should fix Coverity issue.
Coverity issue: 395526 Fixes: f79ce621e963 ("net/sfc: support IPv4 fragment matching in transfer rules") Cc: sta...@dpdk.org Signed-off-by: Ivan Malov <ivan.ma...@arknetworks.am> --- drivers/net/sfc/sfc_mae.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/sfc/sfc_mae.c b/drivers/net/sfc/sfc_mae.c index 63f6536243..60a54fd425 100644 --- a/drivers/net/sfc/sfc_mae.c +++ b/drivers/net/sfc/sfc_mae.c @@ -2331,7 +2331,7 @@ sfc_mae_rule_parse_item_ipv4(const struct rte_flow_item *item, if (ctx_mae->match_spec != ctx_mae->match_spec_action) supp_mask.hdr.fragment_offset = 0; - if (item != NULL && item->last != NULL) { + if (item->last != NULL) { last = item->last; item_dup.last = NULL; } -- 2.17.1