net/bnxt: fix VXLAN decap offload
This patch fixes a couple of scenarios which were overlooked
by the patch which added VXLAN rte_flow offload support.
1. When a PMD application queries for flow counters, it could ask PMD
to reset the counters when the application is doing the counters
accumulation. In this case, PMD should not accumulate rather reset
the counter.
2. Some of the PMD applications may set the protocol field in the IPv4
spec but don't set the mask. So, consider the mask in the proto
value calculation.
4. The cached tunnel inner flow is not getting installed in the
context of tunnel outer flow create because of the wrong
error code check when tunnel outer flow is installed in the
hardware.
5. When a dpdk application offloads the same tunnel inner flow on
all the uplink ports, other than the first one the driver rejects
the rest of them. However, the first tunnel inner flow request
might not be of the correct physical port. This is fixed by
caching the tunnel inner flow entry for all the ports on which
the flow offload request has arrived on. The tunnel inner flows
which were cached on the irrelevant ports will eventually get
aged out as there won't be any traffic on these ports.
Fixes:
675e31d877b6 ("net/bnxt: support VXLAN decap offload")
Signed-off-by: Venkat Duvvuru <venkatkumar.duvvuru@broadcom.com>
Reviewed-by: Ajit Khaparde <ajit.khaparde@broadcom.com>
Reviewed-by: Somnath Kotur <somnath.kotur@broadcom.com>