From: Zhirun Yan Date: Tue, 2 Mar 2021 02:54:07 +0000 (+0800) Subject: net/ice: clean GTPU flow type for flow director X-Git-Url: http://git.droids-corp.org/?a=commitdiff_plain;h=1b05c5b2b4cb146ff9b08a060f746f7b66708d76;p=dpdk.git net/ice: clean GTPU flow type for flow director Currently, FDIR only support GTPU outer fields in PF. Clean the redundant GTPU inner info in flow type definition and align with shared code. Signed-off-by: Zhirun Yan Signed-off-by: Junfeng Guo Acked-by: Qi Zhang --- diff --git a/drivers/net/ice/ice_fdir_filter.c b/drivers/net/ice/ice_fdir_filter.c index 72836fca6c..3af5812660 100644 --- a/drivers/net/ice/ice_fdir_filter.c +++ b/drivers/net/ice/ice_fdir_filter.c @@ -954,26 +954,23 @@ ice_fdir_input_set_hdrs(enum ice_fltr_ptype flow, struct ice_flow_seg_info *seg) ICE_FLOW_SET_HDRS(seg, ICE_FLOW_SEG_HDR_IPV6 | ICE_FLOW_SEG_HDR_IPV_OTHER); break; - case ICE_FLTR_PTYPE_NONF_IPV4_GTPU_IPV4_UDP: - case ICE_FLTR_PTYPE_NONF_IPV4_GTPU_IPV4_TCP: - case ICE_FLTR_PTYPE_NONF_IPV4_GTPU_IPV4_ICMP: - case ICE_FLTR_PTYPE_NONF_IPV4_GTPU_IPV4_OTHER: + case ICE_FLTR_PTYPE_NONF_IPV4_GTPU: ICE_FLOW_SET_HDRS(seg, ICE_FLOW_SEG_HDR_GTPU_IP | ICE_FLOW_SEG_HDR_IPV4 | ICE_FLOW_SEG_HDR_IPV_OTHER); break; - case ICE_FLTR_PTYPE_NONF_IPV4_GTPU_EH_IPV4_OTHER: + case ICE_FLTR_PTYPE_NONF_IPV4_GTPU_EH: ICE_FLOW_SET_HDRS(seg, ICE_FLOW_SEG_HDR_GTPU_EH | ICE_FLOW_SEG_HDR_GTPU_IP | ICE_FLOW_SEG_HDR_IPV4 | ICE_FLOW_SEG_HDR_IPV_OTHER); break; - case ICE_FLTR_PTYPE_NONF_IPV6_GTPU_IPV6_OTHER: + case ICE_FLTR_PTYPE_NONF_IPV6_GTPU: ICE_FLOW_SET_HDRS(seg, ICE_FLOW_SEG_HDR_GTPU_IP | ICE_FLOW_SEG_HDR_IPV6 | ICE_FLOW_SEG_HDR_IPV_OTHER); break; - case ICE_FLTR_PTYPE_NONF_IPV6_GTPU_EH_IPV6_OTHER: + case ICE_FLTR_PTYPE_NONF_IPV6_GTPU_EH: ICE_FLOW_SET_HDRS(seg, ICE_FLOW_SEG_HDR_GTPU_EH | ICE_FLOW_SEG_HDR_GTPU_IP | ICE_FLOW_SEG_HDR_IPV6 | @@ -1958,16 +1955,16 @@ ice_fdir_parse_pattern(__rte_unused struct ice_adapter *ad, if (tunnel_type == ICE_FDIR_TUNNEL_TYPE_GTPU && flow_type == ICE_FLTR_PTYPE_NONF_IPV4_UDP) - flow_type = ICE_FLTR_PTYPE_NONF_IPV4_GTPU_IPV4_OTHER; + flow_type = ICE_FLTR_PTYPE_NONF_IPV4_GTPU; else if (tunnel_type == ICE_FDIR_TUNNEL_TYPE_GTPU_EH && flow_type == ICE_FLTR_PTYPE_NONF_IPV4_UDP) - flow_type = ICE_FLTR_PTYPE_NONF_IPV4_GTPU_EH_IPV4_OTHER; + flow_type = ICE_FLTR_PTYPE_NONF_IPV4_GTPU_EH; else if (tunnel_type == ICE_FDIR_TUNNEL_TYPE_GTPU && flow_type == ICE_FLTR_PTYPE_NONF_IPV6_UDP) - flow_type = ICE_FLTR_PTYPE_NONF_IPV6_GTPU_IPV6_OTHER; + flow_type = ICE_FLTR_PTYPE_NONF_IPV6_GTPU; else if (tunnel_type == ICE_FDIR_TUNNEL_TYPE_GTPU_EH && flow_type == ICE_FLTR_PTYPE_NONF_IPV6_UDP) - flow_type = ICE_FLTR_PTYPE_NONF_IPV6_GTPU_EH_IPV6_OTHER; + flow_type = ICE_FLTR_PTYPE_NONF_IPV6_GTPU_EH; filter->tunnel_type = tunnel_type; filter->input.flow_type = flow_type;