From: Wei Zhao Date: Thu, 27 Apr 2017 06:34:05 +0000 (+0800) Subject: net/ixgbe: remove useless item type check X-Git-Tag: spdx-start~3340 X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=3d54a4d9cec1df1fa88fdffeda74d948fc1c2a6a;p=dpdk.git net/ixgbe: remove useless item type check Remove a useless item type check for fdir flow rule. Fixes: 11777435c72 ("net/ixgbe: parse flow director filter") Cc: stable@dpdk.org Signed-off-by: Wei Zhao Acked-by: Wenzhuo Lu --- diff --git a/drivers/net/ixgbe/ixgbe_flow.c b/drivers/net/ixgbe/ixgbe_flow.c index f96e24ae0f..566544f61b 100644 --- a/drivers/net/ixgbe/ixgbe_flow.c +++ b/drivers/net/ixgbe/ixgbe_flow.c @@ -2250,27 +2250,10 @@ ixgbe_parse_fdir_filter_tunnel(const struct rte_flow_attr *attr, rule->mask.vlan_tci_mask &= rte_cpu_to_be_16(0xEFFF); /* More than one tags are not supported. */ - /** - * Check if the next not void item is not vlan. - */ - index++; - NEXT_ITEM_OF_PATTERN(item, pattern, index); - if (item->type == RTE_FLOW_ITEM_TYPE_VLAN) { - memset(rule, 0, sizeof(struct ixgbe_fdir_rule)); - rte_flow_error_set(error, EINVAL, - RTE_FLOW_ERROR_TYPE_ITEM, - item, "Not supported by fdir filter"); - return -rte_errno; - } else if (item->type != RTE_FLOW_ITEM_TYPE_END) { - memset(rule, 0, sizeof(struct ixgbe_fdir_rule)); - rte_flow_error_set(error, EINVAL, - RTE_FLOW_ERROR_TYPE_ITEM, - item, "Not supported by fdir filter"); - return -rte_errno; - } /* check if the next not void item is END */ index++; NEXT_ITEM_OF_PATTERN(item, pattern, index); + if (item->type != RTE_FLOW_ITEM_TYPE_END) { memset(rule, 0, sizeof(struct ixgbe_fdir_rule)); rte_flow_error_set(error, EINVAL,