ethdev: fix last item detection on RSS flow expand
authorMatan Azrad <matan@mellanox.com>
Mon, 11 Nov 2019 10:42:05 +0000 (10:42 +0000)
committerFerruh Yigit <ferruh.yigit@intel.com>
Tue, 12 Nov 2019 00:55:26 +0000 (01:55 +0100)
commiteccc5d3237fc549ba647654a7f74f8b9e9dcaf6d
tree41cd0f098059a7c677349a550a9fd985687f4bc1
parent4a72909224527386b913bc04b4e535416b7ef5bb
ethdev: fix last item detection on RSS flow expand

There is a rte_flow API which expands a RSS flow pattern to multiple
patterns according to the RSS hash types in the RSS action
configuration.

As part of the expansion, detection of the last item of the flow uses
the "next proto" field of the last configured item in the pattern list.
Wrongly, the mask of this field was not considered in order to validate
the field.

Ignore "next proto" fields when their corresponded masks invalidate them.

Fixes: fc2dd8dd492f ("ethdev: fix expand RSS flows")
Cc: stable@dpdk.org
Signed-off-by: Matan Azrad <matan@mellanox.com>
Acked-by: Xiaoyu Min <jackmin@mellanox.com>
Acked-by: Ori Kam <orika@mellanox.com>
lib/librte_ethdev/rte_flow.c