net/iavf: support eCPRI flow patterns
authorSimei Su <simei.su@intel.com>
Mon, 14 Dec 2020 06:49:10 +0000 (14:49 +0800)
committerFerruh Yigit <ferruh.yigit@intel.com>
Fri, 8 Jan 2021 15:03:06 +0000 (16:03 +0100)
Add patterns support for eCPRI.
Added patterns are as follows:
        eth_ecpri
        eth_ipv4_ecpri

Signed-off-by: Simei Su <simei.su@intel.com>
Acked-by: Qi Zhang <qi.z.zhang@intel.com>
drivers/net/iavf/iavf_generic_flow.c
drivers/net/iavf/iavf_generic_flow.h

index 00e7f15..aabbcf3 100644 (file)
@@ -783,6 +783,21 @@ enum rte_flow_item_type iavf_pattern_eth_ipv6_pfcp[] = {
        RTE_FLOW_ITEM_TYPE_END,
 };
 
+/* ECPRI */
+enum rte_flow_item_type iavf_pattern_eth_ecpri[] = {
+       RTE_FLOW_ITEM_TYPE_ETH,
+       RTE_FLOW_ITEM_TYPE_ECPRI,
+       RTE_FLOW_ITEM_TYPE_END,
+};
+
+enum rte_flow_item_type iavf_pattern_eth_ipv4_ecpri[] = {
+       RTE_FLOW_ITEM_TYPE_ETH,
+       RTE_FLOW_ITEM_TYPE_IPV4,
+       RTE_FLOW_ITEM_TYPE_UDP,
+       RTE_FLOW_ITEM_TYPE_ECPRI,
+       RTE_FLOW_ITEM_TYPE_END,
+};
+
 typedef struct iavf_flow_engine * (*parse_engine_t)(struct iavf_adapter *ad,
                struct rte_flow *flow,
                struct iavf_parser_list *parser_list,
index efc7f22..9e518bd 100644 (file)
@@ -262,6 +262,9 @@ extern enum rte_flow_item_type iavf_pattern_eth_ipv6_l2tpv3[];
 extern enum rte_flow_item_type iavf_pattern_eth_ipv4_pfcp[];
 extern enum rte_flow_item_type iavf_pattern_eth_ipv6_pfcp[];
 
+/* ECPRI */
+extern enum rte_flow_item_type iavf_pattern_eth_ecpri[];
+extern enum rte_flow_item_type iavf_pattern_eth_ipv4_ecpri[];
 
 extern const struct rte_flow_ops iavf_flow_ops;