1 /* SPDX-License-Identifier: BSD-3-Clause
2 * Copyright(c) 2020 Intel Corporation
13 #include <rte_debug.h>
14 #include <rte_ether.h>
15 #include <rte_ethdev_driver.h>
17 #include <rte_malloc.h>
18 #include <rte_eth_ctrl.h>
19 #include <rte_tailq.h>
20 #include <rte_flow_driver.h>
24 #include "iavf_generic_flow.h"
26 enum iavf_pattern_hint_type {
27 IAVF_PHINT_NONE = 0x00000000,
28 IAVF_PHINT_IPV4 = 0x00000001,
29 IAVF_PHINT_IPV4_UDP = 0x00000002,
30 IAVF_PHINT_IPV4_TCP = 0x00000004,
31 IAVF_PHINT_IPV4_SCTP = 0x00000008,
32 IAVF_PHINT_IPV6 = 0x00000010,
33 IAVF_PHINT_IPV6_UDP = 0x00000020,
34 IAVF_PHINT_IPV6_TCP = 0x00000040,
35 IAVF_PHINT_IPV6_SCTP = 0x00000080,
36 IAVF_PHINT_IPV4_GTPU_EH = 0x00000100,
37 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK = 0x00000200,
38 IAVF_PHINT_IPV4_GTPU_EH_UPLINK = 0x00000400,
41 #define IAVF_GTPU_EH_DWNLINK 0
42 #define IAVF_GTPU_EH_UPLINK 1
44 struct iavf_pattern_match_type {
45 uint64_t pattern_hint;
48 struct iavf_hash_match_type {
50 struct virtchnl_proto_hdrs *proto_hdrs;
51 uint64_t pattern_hint;
54 struct iavf_rss_meta {
55 struct virtchnl_proto_hdrs *proto_hdrs;
56 enum virtchnl_rss_algorithm rss_algorithm;
59 struct iavf_hash_flow_cfg {
60 struct virtchnl_rss_cfg *rss_cfg;
65 iavf_hash_init(struct iavf_adapter *ad);
67 iavf_hash_create(struct iavf_adapter *ad, struct rte_flow *flow, void *meta,
68 struct rte_flow_error *error);
70 iavf_hash_destroy(struct iavf_adapter *ad, struct rte_flow *flow,
71 struct rte_flow_error *error);
73 iavf_hash_uninit(struct iavf_adapter *ad);
75 iavf_hash_free(struct rte_flow *flow);
77 iavf_hash_parse_pattern_action(struct iavf_adapter *ad,
78 struct iavf_pattern_match_item *array,
80 const struct rte_flow_item pattern[],
81 const struct rte_flow_action actions[],
83 struct rte_flow_error *error);
85 static struct iavf_pattern_match_type phint_empty = {
87 static struct iavf_pattern_match_type phint_eth_ipv4 = {
89 static struct iavf_pattern_match_type phint_eth_ipv4_udp = {
91 static struct iavf_pattern_match_type phint_eth_ipv4_tcp = {
93 static struct iavf_pattern_match_type phint_eth_ipv4_sctp = {
94 IAVF_PHINT_IPV4_SCTP};
95 static struct iavf_pattern_match_type phint_eth_ipv4_gtpu_eh_ipv4 = {
97 static struct iavf_pattern_match_type phint_eth_ipv4_gtpu_eh_ipv4_udp = {
99 static struct iavf_pattern_match_type phint_eth_ipv4_gtpu_eh_ipv4_tcp = {
100 IAVF_PHINT_IPV4_TCP};
101 static struct iavf_pattern_match_type phint_eth_ipv4_esp = {
103 static struct iavf_pattern_match_type phint_eth_ipv4_ah = {
105 static struct iavf_pattern_match_type phint_eth_ipv4_l2tpv3 = {
107 static struct iavf_pattern_match_type phint_eth_ipv4_pfcp = {
108 IAVF_PHINT_IPV4_UDP};
109 static struct iavf_pattern_match_type phint_eth_vlan_ipv4 = {
111 static struct iavf_pattern_match_type phint_eth_vlan_ipv4_udp = {
112 IAVF_PHINT_IPV4_UDP};
113 static struct iavf_pattern_match_type phint_eth_vlan_ipv4_tcp = {
114 IAVF_PHINT_IPV4_TCP};
115 static struct iavf_pattern_match_type phint_eth_vlan_ipv4_sctp = {
116 IAVF_PHINT_IPV4_SCTP};
117 static struct iavf_pattern_match_type phint_eth_ipv6 = {
119 static struct iavf_pattern_match_type phint_eth_ipv6_udp = {
120 IAVF_PHINT_IPV6_UDP};
121 static struct iavf_pattern_match_type phint_eth_ipv6_tcp = {
122 IAVF_PHINT_IPV6_TCP};
123 static struct iavf_pattern_match_type phint_eth_ipv6_sctp = {
124 IAVF_PHINT_IPV6_SCTP};
125 static struct iavf_pattern_match_type phint_eth_ipv6_esp = {
127 static struct iavf_pattern_match_type phint_eth_ipv6_ah = {
129 static struct iavf_pattern_match_type phint_eth_ipv6_l2tpv3 = {
131 static struct iavf_pattern_match_type phint_eth_ipv6_pfcp = {
132 IAVF_PHINT_IPV6_UDP};
133 static struct iavf_pattern_match_type phint_eth_vlan_ipv6 = {
135 static struct iavf_pattern_match_type phint_eth_vlan_ipv6_udp = {
136 IAVF_PHINT_IPV6_UDP};
137 static struct iavf_pattern_match_type phint_eth_vlan_ipv6_tcp = {
138 IAVF_PHINT_IPV6_TCP};
139 static struct iavf_pattern_match_type phint_eth_vlan_ipv6_sctp = {
140 IAVF_PHINT_IPV6_SCTP};
143 * Supported pattern for hash.
144 * The first member is pattern item type,
145 * the second member is input set mask,
146 * the third member is pattern hint for hash.
148 static struct iavf_pattern_match_item iavf_hash_pattern_list[] = {
149 {iavf_pattern_eth_ipv4, IAVF_INSET_NONE, &phint_eth_ipv4},
150 {iavf_pattern_eth_ipv4_udp, IAVF_INSET_NONE, &phint_eth_ipv4_udp},
151 {iavf_pattern_eth_ipv4_tcp, IAVF_INSET_NONE, &phint_eth_ipv4_tcp},
152 {iavf_pattern_eth_ipv4_sctp, IAVF_INSET_NONE, &phint_eth_ipv4_sctp},
153 {iavf_pattern_eth_ipv4_gtpu_eh_ipv4, IAVF_INSET_NONE,
154 &phint_eth_ipv4_gtpu_eh_ipv4},
155 {iavf_pattern_eth_ipv4_gtpu_eh_ipv4_udp, IAVF_INSET_NONE,
156 &phint_eth_ipv4_gtpu_eh_ipv4_udp},
157 {iavf_pattern_eth_ipv4_gtpu_eh_ipv4_tcp, IAVF_INSET_NONE,
158 &phint_eth_ipv4_gtpu_eh_ipv4_tcp},
159 {iavf_pattern_eth_ipv4_esp, IAVF_INSET_NONE, &phint_eth_ipv4_esp},
160 {iavf_pattern_eth_ipv4_ah, IAVF_INSET_NONE, &phint_eth_ipv4_ah},
161 {iavf_pattern_eth_ipv4_l2tpv3, IAVF_INSET_NONE,
162 &phint_eth_ipv4_l2tpv3},
163 {iavf_pattern_eth_ipv4_pfcp, IAVF_INSET_NONE, &phint_eth_ipv4_pfcp},
164 {iavf_pattern_eth_vlan_ipv4, IAVF_INSET_NONE, &phint_eth_vlan_ipv4},
165 {iavf_pattern_eth_vlan_ipv4_udp, IAVF_INSET_NONE,
166 &phint_eth_vlan_ipv4_udp},
167 {iavf_pattern_eth_vlan_ipv4_tcp, IAVF_INSET_NONE,
168 &phint_eth_vlan_ipv4_tcp},
169 {iavf_pattern_eth_vlan_ipv4_sctp, IAVF_INSET_NONE,
170 &phint_eth_vlan_ipv4_sctp},
171 {iavf_pattern_eth_ipv6, IAVF_INSET_NONE, &phint_eth_ipv6},
172 {iavf_pattern_eth_ipv6_udp, IAVF_INSET_NONE, &phint_eth_ipv6_udp},
173 {iavf_pattern_eth_ipv6_tcp, IAVF_INSET_NONE, &phint_eth_ipv6_tcp},
174 {iavf_pattern_eth_ipv6_sctp, IAVF_INSET_NONE, &phint_eth_ipv6_sctp},
175 {iavf_pattern_eth_ipv6_esp, IAVF_INSET_NONE, &phint_eth_ipv6_esp},
176 {iavf_pattern_eth_ipv6_ah, IAVF_INSET_NONE, &phint_eth_ipv6_ah},
177 {iavf_pattern_eth_ipv6_l2tpv3, IAVF_INSET_NONE,
178 &phint_eth_ipv6_l2tpv3},
179 {iavf_pattern_eth_ipv6_pfcp, IAVF_INSET_NONE, &phint_eth_ipv6_pfcp},
180 {iavf_pattern_eth_vlan_ipv6, IAVF_INSET_NONE, &phint_eth_vlan_ipv6},
181 {iavf_pattern_eth_vlan_ipv6_udp, IAVF_INSET_NONE,
182 &phint_eth_vlan_ipv6_udp},
183 {iavf_pattern_eth_vlan_ipv6_tcp, IAVF_INSET_NONE,
184 &phint_eth_vlan_ipv6_tcp},
185 {iavf_pattern_eth_vlan_ipv6_sctp, IAVF_INSET_NONE,
186 &phint_eth_vlan_ipv6_sctp},
187 {iavf_pattern_empty, IAVF_INSET_NONE, &phint_empty},
190 #define TUNNEL_LEVEL_OUTER 0
191 #define TUNNEL_LEVEL_FIRST_INNER 1
193 #define PROTO_COUNT_ONE 1
194 #define PROTO_COUNT_TWO 2
195 #define PROTO_COUNT_THREE 3
197 #define BUFF_NOUSED 0
198 #define FIELD_FOR_PROTO_ONLY 0
200 #define FIELD_SELECTOR(proto_hdr_field) \
201 (1UL << ((proto_hdr_field) & PROTO_HDR_FIELD_MASK))
203 #define proto_hint_eth_src { \
204 VIRTCHNL_PROTO_HDR_ETH, FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_ETH_SRC), \
207 #define proto_hint_eth_dst { \
208 VIRTCHNL_PROTO_HDR_ETH, FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_ETH_DST), \
211 #define proto_hint_eth_only { \
212 VIRTCHNL_PROTO_HDR_ETH, FIELD_FOR_PROTO_ONLY, {BUFF_NOUSED } }
214 #define proto_hint_eth { \
215 VIRTCHNL_PROTO_HDR_ETH, \
216 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_ETH_SRC) | \
217 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_ETH_DST), {BUFF_NOUSED } }
219 #define proto_hint_svlan { \
220 VIRTCHNL_PROTO_HDR_S_VLAN, \
221 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_S_VLAN_ID), {BUFF_NOUSED } }
223 #define proto_hint_cvlan { \
224 VIRTCHNL_PROTO_HDR_C_VLAN, \
225 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_C_VLAN_ID), {BUFF_NOUSED } }
227 #define proto_hint_ipv4_src { \
228 VIRTCHNL_PROTO_HDR_IPV4, FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_IPV4_SRC), \
231 #define proto_hint_ipv4_dst { \
232 VIRTCHNL_PROTO_HDR_IPV4, FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_IPV4_DST), \
235 #define proto_hint_ipv4_only { \
236 VIRTCHNL_PROTO_HDR_IPV4, FIELD_FOR_PROTO_ONLY, {BUFF_NOUSED } }
238 #define proto_hint_ipv4 { \
239 VIRTCHNL_PROTO_HDR_IPV4, \
240 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_IPV4_SRC) | \
241 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_IPV4_DST), {BUFF_NOUSED } }
243 #define proto_hint_ipv4_src_prot { \
244 VIRTCHNL_PROTO_HDR_IPV4, \
245 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_IPV4_SRC) | \
246 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_IPV4_PROT), \
249 #define proto_hint_ipv4_dst_prot { \
250 VIRTCHNL_PROTO_HDR_IPV4, \
251 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_IPV4_DST) | \
252 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_IPV4_PROT), \
255 #define proto_hint_ipv4_only_prot { \
256 VIRTCHNL_PROTO_HDR_IPV4, \
257 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_IPV4_PROT), {BUFF_NOUSED } }
259 #define proto_hint_ipv4_prot { \
260 VIRTCHNL_PROTO_HDR_IPV4, \
261 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_IPV4_SRC) | \
262 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_IPV4_DST) | \
263 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_IPV4_PROT), {BUFF_NOUSED } }
265 #define proto_hint_udp_src_port { \
266 VIRTCHNL_PROTO_HDR_UDP, \
267 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_UDP_SRC_PORT), {BUFF_NOUSED } }
269 #define proto_hint_udp_dst_port { \
270 VIRTCHNL_PROTO_HDR_UDP, \
271 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_UDP_DST_PORT), {BUFF_NOUSED } }
273 #define proto_hint_udp_only { \
274 VIRTCHNL_PROTO_HDR_UDP, FIELD_FOR_PROTO_ONLY, {BUFF_NOUSED } }
276 #define proto_hint_udp { \
277 VIRTCHNL_PROTO_HDR_UDP, \
278 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_UDP_SRC_PORT) | \
279 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_UDP_DST_PORT), {BUFF_NOUSED } }
281 #define proto_hint_tcp_src_port { \
282 VIRTCHNL_PROTO_HDR_TCP, \
283 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_TCP_SRC_PORT), {BUFF_NOUSED } }
285 #define proto_hint_tcp_dst_port { \
286 VIRTCHNL_PROTO_HDR_TCP, \
287 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_TCP_DST_PORT), {BUFF_NOUSED } }
289 #define proto_hint_tcp_only { \
290 VIRTCHNL_PROTO_HDR_TCP, FIELD_FOR_PROTO_ONLY, {BUFF_NOUSED } }
292 #define proto_hint_tcp { \
293 VIRTCHNL_PROTO_HDR_TCP, \
294 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_TCP_SRC_PORT) | \
295 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_TCP_DST_PORT), {BUFF_NOUSED } }
297 #define proto_hint_sctp_src_port { \
298 VIRTCHNL_PROTO_HDR_SCTP, \
299 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_SCTP_SRC_PORT), {BUFF_NOUSED } }
301 #define proto_hint_sctp_dst_port { \
302 VIRTCHNL_PROTO_HDR_SCTP, \
303 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_SCTP_DST_PORT), {BUFF_NOUSED } }
305 #define proto_hint_sctp_only { \
306 VIRTCHNL_PROTO_HDR_SCTP, FIELD_FOR_PROTO_ONLY, {BUFF_NOUSED } }
308 #define proto_hint_sctp { \
309 VIRTCHNL_PROTO_HDR_SCTP, \
310 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_SCTP_SRC_PORT) | \
311 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_SCTP_DST_PORT), {BUFF_NOUSED } }
313 #define proto_hint_ipv6_src { \
314 VIRTCHNL_PROTO_HDR_IPV6, FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_IPV6_SRC), \
317 #define proto_hint_ipv6_dst { \
318 VIRTCHNL_PROTO_HDR_IPV6, FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_IPV6_DST), \
321 #define proto_hint_ipv6_only { \
322 VIRTCHNL_PROTO_HDR_IPV6, FIELD_FOR_PROTO_ONLY, {BUFF_NOUSED } }
324 #define proto_hint_ipv6 { \
325 VIRTCHNL_PROTO_HDR_IPV6, \
326 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_IPV6_SRC) | \
327 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_IPV6_DST), {BUFF_NOUSED } }
329 #define proto_hint_ipv6_src_prot { \
330 VIRTCHNL_PROTO_HDR_IPV6, \
331 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_IPV6_SRC) | \
332 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_IPV6_PROT), \
335 #define proto_hint_ipv6_dst_prot { \
336 VIRTCHNL_PROTO_HDR_IPV6, \
337 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_IPV6_DST) | \
338 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_IPV6_PROT), \
341 #define proto_hint_ipv6_only_prot { \
342 VIRTCHNL_PROTO_HDR_IPV6, \
343 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_IPV6_PROT), {BUFF_NOUSED } }
345 #define proto_hint_ipv6_prot { \
346 VIRTCHNL_PROTO_HDR_IPV6, \
347 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_IPV6_SRC) | \
348 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_IPV6_DST) | \
349 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_IPV6_PROT), {BUFF_NOUSED } }
351 #define proto_hint_gtpu_eh_only { \
352 VIRTCHNL_PROTO_HDR_GTPU_EH, \
353 FIELD_FOR_PROTO_ONLY, {BUFF_NOUSED } }
355 #define proto_hint_gtpu_up_only { \
356 VIRTCHNL_PROTO_HDR_GTPU_EH_PDU_UP, \
357 FIELD_FOR_PROTO_ONLY, {BUFF_NOUSED } }
359 #define proto_hint_gtpu_dwn_only { \
360 VIRTCHNL_PROTO_HDR_GTPU_EH_PDU_DWN, \
361 FIELD_FOR_PROTO_ONLY, {BUFF_NOUSED } }
363 #define proto_hint_esp { \
364 VIRTCHNL_PROTO_HDR_ESP, \
365 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_ESP_SPI), {BUFF_NOUSED } }
367 #define proto_hint_ah { \
368 VIRTCHNL_PROTO_HDR_AH, \
369 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_AH_SPI), {BUFF_NOUSED } }
371 #define proto_hint_l2tpv3 { \
372 VIRTCHNL_PROTO_HDR_L2TPV3, \
373 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_L2TPV3_SESS_ID), {BUFF_NOUSED } }
375 #define proto_hint_pfcp { \
376 VIRTCHNL_PROTO_HDR_PFCP, \
377 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_PFCP_SEID), {BUFF_NOUSED } }
381 struct virtchnl_proto_hdrs hdrs_hint_eth_src_ipv4 = {
382 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_eth_src,
383 proto_hint_ipv4_only }
386 struct virtchnl_proto_hdrs hdrs_hint_eth_src_ipv4_udp = {
387 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_eth_src,
388 proto_hint_ipv4_only, proto_hint_udp_only }
391 struct virtchnl_proto_hdrs hdrs_hint_eth_src_ipv4_tcp = {
392 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_eth_src,
393 proto_hint_ipv4_only, proto_hint_tcp_only }
396 struct virtchnl_proto_hdrs hdrs_hint_eth_src_ipv4_sctp = {
397 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_eth_src,
398 proto_hint_ipv4_only, proto_hint_sctp_only }
401 struct virtchnl_proto_hdrs hdrs_hint_eth_dst_ipv4 = {
402 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_eth_dst,
403 proto_hint_ipv4_only }
406 struct virtchnl_proto_hdrs hdrs_hint_eth_dst_ipv4_udp = {
407 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_eth_dst,
408 proto_hint_ipv4_only, proto_hint_udp_only }
411 struct virtchnl_proto_hdrs hdrs_hint_eth_dst_ipv4_tcp = {
412 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_eth_dst,
413 proto_hint_ipv4_only, proto_hint_tcp_only }
416 struct virtchnl_proto_hdrs hdrs_hint_eth_dst_ipv4_sctp = {
417 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_eth_dst,
418 proto_hint_ipv4_only, proto_hint_sctp_only }
421 struct virtchnl_proto_hdrs hdrs_hint_eth_ipv4 = {
422 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_eth,
423 proto_hint_ipv4_only }
426 struct virtchnl_proto_hdrs hdrs_hint_eth_ipv4_udp = {
427 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_eth,
428 proto_hint_ipv4_only, proto_hint_udp_only }
431 struct virtchnl_proto_hdrs hdrs_hint_eth_ipv4_tcp = {
432 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_eth,
433 proto_hint_ipv4_only, proto_hint_tcp_only }
436 struct virtchnl_proto_hdrs hdrs_hint_eth_ipv4_sctp = {
437 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_eth,
438 proto_hint_ipv4_only, proto_hint_sctp_only }
441 struct virtchnl_proto_hdrs hdrs_hint_svlan_ipv4 = {
442 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_svlan,
443 proto_hint_ipv4_only}
446 struct virtchnl_proto_hdrs hdrs_hint_svlan_ipv4_udp = {
447 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_svlan,
448 proto_hint_ipv4_only, proto_hint_udp_only}
451 struct virtchnl_proto_hdrs hdrs_hint_svlan_ipv4_tcp = {
452 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_svlan,
453 proto_hint_ipv4_only, proto_hint_tcp_only}
456 struct virtchnl_proto_hdrs hdrs_hint_svlan_ipv4_sctp = {
457 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_svlan,
458 proto_hint_ipv4_only, proto_hint_sctp_only}
461 struct virtchnl_proto_hdrs hdrs_hint_cvlan_ipv4 = {
462 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_cvlan,
463 proto_hint_ipv4_only}
466 struct virtchnl_proto_hdrs hdrs_hint_cvlan_ipv4_udp = {
467 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_cvlan,
468 proto_hint_ipv4_only, proto_hint_udp_only}
471 struct virtchnl_proto_hdrs hdrs_hint_cvlan_ipv4_tcp = {
472 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_cvlan,
473 proto_hint_ipv4_only, proto_hint_tcp_only}
476 struct virtchnl_proto_hdrs hdrs_hint_cvlan_ipv4_sctp = {
477 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_cvlan,
478 proto_hint_ipv4_only, proto_hint_sctp_only}
481 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src = {
482 TUNNEL_LEVEL_OUTER, PROTO_COUNT_ONE, {proto_hint_ipv4_src }
485 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst = {
486 TUNNEL_LEVEL_OUTER, PROTO_COUNT_ONE, {proto_hint_ipv4_dst }
489 struct virtchnl_proto_hdrs hdrs_hint_ipv4 = {
490 TUNNEL_LEVEL_OUTER, PROTO_COUNT_ONE, {proto_hint_ipv4 }
493 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_udp_src_port = {
494 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_src_prot,
495 proto_hint_udp_src_port }
498 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_udp_dst_port = {
499 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_src_prot,
500 proto_hint_udp_dst_port }
503 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_udp_src_port = {
504 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_dst_prot,
505 proto_hint_udp_src_port }
508 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_udp_dst_port = {
509 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_dst_prot,
510 proto_hint_udp_dst_port }
513 struct virtchnl_proto_hdrs hdrs_hint_ipv4_udp_src_port = {
514 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_only_prot,
515 proto_hint_udp_src_port }
518 struct virtchnl_proto_hdrs hdrs_hint_ipv4_udp_dst_port = {
519 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_only_prot,
520 proto_hint_udp_dst_port }
523 struct virtchnl_proto_hdrs hdrs_hint_ipv4_udp = {
524 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_prot,
528 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_tcp_src_port = {
529 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_src_prot,
530 proto_hint_tcp_src_port }
533 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_tcp_dst_port = {
534 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_src_prot,
535 proto_hint_tcp_dst_port }
538 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_tcp_src_port = {
539 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_dst_prot,
540 proto_hint_tcp_src_port }
543 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_tcp_dst_port = {
544 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_dst_prot,
545 proto_hint_tcp_dst_port }
548 struct virtchnl_proto_hdrs hdrs_hint_ipv4_tcp_src_port = {
549 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_only_prot,
550 proto_hint_tcp_src_port }
553 struct virtchnl_proto_hdrs hdrs_hint_ipv4_tcp_dst_port = {
554 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_only_prot,
555 proto_hint_tcp_dst_port }
558 struct virtchnl_proto_hdrs hdrs_hint_ipv4_tcp = {
559 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_prot,
563 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_sctp_src_port = {
564 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_src,
565 proto_hint_sctp_src_port }
568 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_sctp_dst_port = {
569 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_src,
570 proto_hint_sctp_dst_port }
573 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_sctp_src_port = {
574 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_dst,
575 proto_hint_sctp_src_port }
578 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_sctp_dst_port = {
579 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_dst,
580 proto_hint_sctp_dst_port }
583 struct virtchnl_proto_hdrs hdrs_hint_ipv4_sctp_src_port = {
584 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_only,
585 proto_hint_sctp_src_port }
588 struct virtchnl_proto_hdrs hdrs_hint_ipv4_sctp_dst_port = {
589 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_only,
590 proto_hint_sctp_dst_port }
593 struct virtchnl_proto_hdrs hdrs_hint_ipv4_sctp = {
594 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4,
598 struct virtchnl_proto_hdrs hdrs_hint_ipv4_esp = {
599 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_only,
603 struct virtchnl_proto_hdrs hdrs_hint_ipv4_ah = {
604 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_only,
608 struct virtchnl_proto_hdrs hdrs_hint_ipv4_l2tpv3 = {
609 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_only,
613 struct virtchnl_proto_hdrs hdrs_hint_ipv4_pfcp = {
614 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_only,
618 struct virtchnl_proto_hdrs hdrs_hint_ipv4_udp_esp = {
619 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_ipv4_only,
620 proto_hint_udp_only, proto_hint_esp }
625 struct virtchnl_proto_hdrs hdrs_hint_ipv4_udp_src_gtpu_eh = {
626 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_eh_only,
627 proto_hint_ipv4_only_prot, proto_hint_udp_src_port}
630 struct virtchnl_proto_hdrs hdrs_hint_ipv4_udp_dst_gtpu_eh = {
631 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_eh_only,
632 proto_hint_ipv4_only_prot, proto_hint_udp_dst_port}
635 struct virtchnl_proto_hdrs hdrs_hint_ipv4_tcp_src_gtpu_eh = {
636 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_eh_only,
637 proto_hint_ipv4_only_prot, proto_hint_tcp_src_port}
640 struct virtchnl_proto_hdrs hdrs_hint_ipv4_tcp_dst_gtpu_eh = {
641 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_eh_only,
642 proto_hint_ipv4_only_prot, proto_hint_tcp_dst_port}
645 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_gtpu_eh = {
646 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_eh_only,
647 proto_hint_ipv4_src }
650 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_udp_src_gtpu_eh = {
651 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_eh_only,
652 proto_hint_ipv4_src_prot, proto_hint_udp_src_port}
655 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_udp_dst_gtpu_eh = {
656 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_eh_only,
657 proto_hint_ipv4_src_prot, proto_hint_udp_dst_port}
660 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_tcp_src_gtpu_eh = {
661 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_eh_only,
662 proto_hint_ipv4_src_prot, proto_hint_tcp_src_port}
665 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_tcp_dst_gtpu_eh = {
666 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_eh_only,
667 proto_hint_ipv4_src_prot, proto_hint_tcp_dst_port}
670 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_gtpu_eh = {
671 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_eh_only,
672 proto_hint_ipv4_dst }
675 struct virtchnl_proto_hdrs hdrs_hint_ipv4_gtpu_eh = {
676 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_eh_only,
680 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_udp_src_gtpu_eh = {
681 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_eh_only,
682 proto_hint_ipv4_dst_prot, proto_hint_udp_src_port}
685 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_udp_dst_gtpu_eh = {
686 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_eh_only,
687 proto_hint_ipv4_dst_prot, proto_hint_udp_dst_port}
690 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_tcp_src_gtpu_eh = {
691 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_eh_only,
692 proto_hint_ipv4_dst_prot, proto_hint_tcp_src_port}
695 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_tcp_dst_gtpu_eh = {
696 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_eh_only,
697 proto_hint_ipv4_dst_prot, proto_hint_tcp_dst_port}
700 struct virtchnl_proto_hdrs hdrs_hint_ipv4_udp_gtpu_eh = {
701 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_eh_only,
702 proto_hint_ipv4_prot, proto_hint_udp}
705 struct virtchnl_proto_hdrs hdrs_hint_ipv4_tcp_gtpu_eh = {
706 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_eh_only,
707 proto_hint_ipv4_prot, proto_hint_tcp}
712 struct virtchnl_proto_hdrs hdrs_hint_ipv4_udp_src_gtpu_up = {
713 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_up_only,
714 proto_hint_ipv4_only_prot, proto_hint_udp_src_port}
717 struct virtchnl_proto_hdrs hdrs_hint_ipv4_udp_dst_gtpu_up = {
718 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_up_only,
719 proto_hint_ipv4_only_prot, proto_hint_udp_dst_port}
722 struct virtchnl_proto_hdrs hdrs_hint_ipv4_tcp_src_gtpu_up = {
723 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_up_only,
724 proto_hint_ipv4_only_prot, proto_hint_tcp_src_port}
727 struct virtchnl_proto_hdrs hdrs_hint_ipv4_tcp_dst_gtpu_up = {
728 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_up_only,
729 proto_hint_ipv4_only_prot, proto_hint_tcp_dst_port}
732 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_gtpu_up = {
733 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_up_only,
734 proto_hint_ipv4_src }
737 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_udp_src_gtpu_up = {
738 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_up_only,
739 proto_hint_ipv4_src_prot, proto_hint_udp_src_port}
742 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_udp_dst_gtpu_up = {
743 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_up_only,
744 proto_hint_ipv4_src_prot, proto_hint_udp_dst_port}
747 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_tcp_src_gtpu_up = {
748 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_up_only,
749 proto_hint_ipv4_src_prot, proto_hint_tcp_src_port}
752 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_tcp_dst_gtpu_up = {
753 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_up_only,
754 proto_hint_ipv4_src_prot, proto_hint_tcp_dst_port}
757 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_gtpu_up = {
758 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_up_only,
759 proto_hint_ipv4_dst }
762 struct virtchnl_proto_hdrs hdrs_hint_ipv4_gtpu_up = {
763 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_up_only,
767 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_udp_src_gtpu_up = {
768 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_up_only,
769 proto_hint_ipv4_dst_prot, proto_hint_udp_src_port}
772 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_udp_dst_gtpu_up = {
773 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_up_only,
774 proto_hint_ipv4_dst_prot, proto_hint_udp_dst_port}
777 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_tcp_src_gtpu_up = {
778 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_up_only,
779 proto_hint_ipv4_dst_prot, proto_hint_tcp_src_port}
782 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_tcp_dst_gtpu_up = {
783 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_up_only,
784 proto_hint_ipv4_dst_prot, proto_hint_tcp_dst_port}
787 struct virtchnl_proto_hdrs hdrs_hint_ipv4_udp_gtpu_up = {
788 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_up_only,
789 proto_hint_ipv4_prot, proto_hint_udp}
792 struct virtchnl_proto_hdrs hdrs_hint_ipv4_tcp_gtpu_up = {
793 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_up_only,
794 proto_hint_ipv4_prot, proto_hint_tcp}
799 struct virtchnl_proto_hdrs hdrs_hint_ipv4_udp_src_gtpu_dwn = {
800 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_dwn_only,
801 proto_hint_ipv4_only_prot, proto_hint_udp_src_port}
804 struct virtchnl_proto_hdrs hdrs_hint_ipv4_udp_dst_gtpu_dwn = {
805 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_dwn_only,
806 proto_hint_ipv4_only_prot, proto_hint_udp_dst_port}
809 struct virtchnl_proto_hdrs hdrs_hint_ipv4_tcp_src_gtpu_dwn = {
810 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_dwn_only,
811 proto_hint_ipv4_only_prot, proto_hint_tcp_src_port}
814 struct virtchnl_proto_hdrs hdrs_hint_ipv4_tcp_dst_gtpu_dwn = {
815 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_dwn_only,
816 proto_hint_ipv4_only_prot, proto_hint_tcp_dst_port}
819 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_gtpu_dwn = {
820 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_dwn_only,
821 proto_hint_ipv4_src }
824 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_udp_src_gtpu_dwn = {
825 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_dwn_only,
826 proto_hint_ipv4_src_prot, proto_hint_udp_src_port}
829 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_udp_dst_gtpu_dwn = {
830 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_dwn_only,
831 proto_hint_ipv4_src_prot, proto_hint_udp_dst_port}
834 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_tcp_src_gtpu_dwn = {
835 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_dwn_only,
836 proto_hint_ipv4_src_prot, proto_hint_tcp_src_port}
839 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_tcp_dst_gtpu_dwn = {
840 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_dwn_only,
841 proto_hint_ipv4_src_prot, proto_hint_tcp_dst_port}
844 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_gtpu_dwn = {
845 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_dwn_only,
846 proto_hint_ipv4_dst }
849 struct virtchnl_proto_hdrs hdrs_hint_ipv4_gtpu_dwn = {
850 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_dwn_only,
854 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_udp_src_gtpu_dwn = {
855 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_dwn_only,
856 proto_hint_ipv4_dst_prot, proto_hint_udp_src_port}
859 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_udp_dst_gtpu_dwn = {
860 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_dwn_only,
861 proto_hint_ipv4_dst_prot, proto_hint_udp_dst_port}
864 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_tcp_src_gtpu_dwn = {
865 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_dwn_only,
866 proto_hint_ipv4_dst_prot, proto_hint_tcp_src_port}
869 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_tcp_dst_gtpu_dwn = {
870 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_dwn_only,
871 proto_hint_ipv4_dst_prot, proto_hint_tcp_dst_port}
874 struct virtchnl_proto_hdrs hdrs_hint_ipv4_udp_gtpu_dwn = {
875 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_dwn_only,
876 proto_hint_ipv4_prot, proto_hint_udp}
879 struct virtchnl_proto_hdrs hdrs_hint_ipv4_tcp_gtpu_dwn = {
880 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_THREE, {proto_hint_gtpu_dwn_only,
881 proto_hint_ipv4_prot, proto_hint_tcp}
886 struct virtchnl_proto_hdrs hdrs_hint_eth_src_ipv6 = {
887 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_eth_src,
888 proto_hint_ipv6_only }
891 struct virtchnl_proto_hdrs hdrs_hint_eth_src_ipv6_udp = {
892 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_eth_src,
893 proto_hint_ipv6_only, proto_hint_udp_only }
896 struct virtchnl_proto_hdrs hdrs_hint_eth_src_ipv6_tcp = {
897 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_eth_src,
898 proto_hint_ipv6_only, proto_hint_tcp_only }
901 struct virtchnl_proto_hdrs hdrs_hint_eth_src_ipv6_sctp = {
902 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_eth_src,
903 proto_hint_ipv6_only, proto_hint_sctp_only }
906 struct virtchnl_proto_hdrs hdrs_hint_eth_dst_ipv6 = {
907 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_eth_dst,
908 proto_hint_ipv6_only }
911 struct virtchnl_proto_hdrs hdrs_hint_eth_dst_ipv6_udp = {
912 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_eth_dst,
913 proto_hint_ipv6_only, proto_hint_udp_only }
916 struct virtchnl_proto_hdrs hdrs_hint_eth_dst_ipv6_tcp = {
917 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_eth_dst,
918 proto_hint_ipv6_only, proto_hint_tcp_only }
921 struct virtchnl_proto_hdrs hdrs_hint_eth_dst_ipv6_sctp = {
922 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_eth_dst,
923 proto_hint_ipv6_only, proto_hint_sctp_only }
926 struct virtchnl_proto_hdrs hdrs_hint_eth_ipv6 = {
927 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_eth,
928 proto_hint_ipv6_only }
931 struct virtchnl_proto_hdrs hdrs_hint_eth_ipv6_udp = {
932 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_eth,
933 proto_hint_ipv6_only, proto_hint_udp_only }
936 struct virtchnl_proto_hdrs hdrs_hint_eth_ipv6_tcp = {
937 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_eth,
938 proto_hint_ipv6_only, proto_hint_tcp_only }
941 struct virtchnl_proto_hdrs hdrs_hint_eth_ipv6_sctp = {
942 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_eth,
943 proto_hint_ipv6_only, proto_hint_sctp_only }
946 struct virtchnl_proto_hdrs hdrs_hint_svlan_ipv6 = {
947 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_svlan,
948 proto_hint_ipv6_only}
951 struct virtchnl_proto_hdrs hdrs_hint_svlan_ipv6_udp = {
952 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_svlan,
953 proto_hint_ipv6_only, proto_hint_udp_only}
956 struct virtchnl_proto_hdrs hdrs_hint_svlan_ipv6_tcp = {
957 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_svlan,
958 proto_hint_ipv6_only, proto_hint_tcp_only}
961 struct virtchnl_proto_hdrs hdrs_hint_svlan_ipv6_sctp = {
962 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_svlan,
963 proto_hint_ipv6_only, proto_hint_sctp_only}
966 struct virtchnl_proto_hdrs hdrs_hint_cvlan_ipv6 = {
967 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_cvlan,
968 proto_hint_ipv6_only}
971 struct virtchnl_proto_hdrs hdrs_hint_cvlan_ipv6_udp = {
972 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_cvlan,
973 proto_hint_ipv6_only, proto_hint_udp_only}
976 struct virtchnl_proto_hdrs hdrs_hint_cvlan_ipv6_tcp = {
977 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_cvlan,
978 proto_hint_ipv6_only, proto_hint_tcp_only}
981 struct virtchnl_proto_hdrs hdrs_hint_cvlan_ipv6_sctp = {
982 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_cvlan,
983 proto_hint_ipv6_only, proto_hint_sctp_only}
986 struct virtchnl_proto_hdrs hdrs_hint_ipv6_src = {
987 TUNNEL_LEVEL_OUTER, PROTO_COUNT_ONE, {proto_hint_ipv6_src }
990 struct virtchnl_proto_hdrs hdrs_hint_ipv6_dst = {
991 TUNNEL_LEVEL_OUTER, PROTO_COUNT_ONE, {proto_hint_ipv6_dst }
994 struct virtchnl_proto_hdrs hdrs_hint_ipv6 = {
995 TUNNEL_LEVEL_OUTER, PROTO_COUNT_ONE, {proto_hint_ipv6 }
998 struct virtchnl_proto_hdrs hdrs_hint_ipv6_src_udp_src_port = {
999 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_src_prot,
1000 proto_hint_udp_src_port }
1003 struct virtchnl_proto_hdrs hdrs_hint_ipv6_src_udp_dst_port = {
1004 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_src_prot,
1005 proto_hint_udp_dst_port }
1008 struct virtchnl_proto_hdrs hdrs_hint_ipv6_dst_udp_src_port = {
1009 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_dst_prot,
1010 proto_hint_udp_src_port }
1013 struct virtchnl_proto_hdrs hdrs_hint_ipv6_dst_udp_dst_port = {
1014 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_dst_prot,
1015 proto_hint_udp_dst_port }
1018 struct virtchnl_proto_hdrs hdrs_hint_ipv6_udp_src_port = {
1019 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_only_prot,
1020 proto_hint_udp_src_port }
1023 struct virtchnl_proto_hdrs hdrs_hint_ipv6_udp_dst_port = {
1024 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_only_prot,
1025 proto_hint_udp_dst_port }
1028 struct virtchnl_proto_hdrs hdrs_hint_ipv6_udp = {
1029 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_prot,
1033 struct virtchnl_proto_hdrs hdrs_hint_ipv6_src_tcp_src_port = {
1034 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_src_prot,
1035 proto_hint_tcp_src_port }
1038 struct virtchnl_proto_hdrs hdrs_hint_ipv6_src_tcp_dst_port = {
1039 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_src_prot,
1040 proto_hint_tcp_dst_port }
1043 struct virtchnl_proto_hdrs hdrs_hint_ipv6_dst_tcp_src_port = {
1044 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_dst_prot,
1045 proto_hint_tcp_src_port }
1048 struct virtchnl_proto_hdrs hdrs_hint_ipv6_dst_tcp_dst_port = {
1049 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_dst_prot,
1050 proto_hint_tcp_dst_port }
1053 struct virtchnl_proto_hdrs hdrs_hint_ipv6_tcp_src_port = {
1054 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_only_prot,
1055 proto_hint_tcp_src_port }
1058 struct virtchnl_proto_hdrs hdrs_hint_ipv6_tcp_dst_port = {
1059 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_only_prot,
1060 proto_hint_tcp_dst_port }
1063 struct virtchnl_proto_hdrs hdrs_hint_ipv6_tcp = {
1064 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_prot,
1068 struct virtchnl_proto_hdrs hdrs_hint_ipv6_src_sctp_src_port = {
1069 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_src,
1070 proto_hint_sctp_src_port }
1073 struct virtchnl_proto_hdrs hdrs_hint_ipv6_src_sctp_dst_port = {
1074 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_src,
1075 proto_hint_sctp_dst_port }
1078 struct virtchnl_proto_hdrs hdrs_hint_ipv6_dst_sctp_src_port = {
1079 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_dst,
1080 proto_hint_sctp_src_port }
1083 struct virtchnl_proto_hdrs hdrs_hint_ipv6_dst_sctp_dst_port = {
1084 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_dst,
1085 proto_hint_sctp_dst_port }
1088 struct virtchnl_proto_hdrs hdrs_hint_ipv6_sctp_src_port = {
1089 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_only,
1090 proto_hint_sctp_src_port }
1093 struct virtchnl_proto_hdrs hdrs_hint_ipv6_sctp_dst_port = {
1094 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_only,
1095 proto_hint_sctp_dst_port }
1098 struct virtchnl_proto_hdrs hdrs_hint_ipv6_sctp = {
1099 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6,
1103 struct virtchnl_proto_hdrs hdrs_hint_ipv6_esp = {
1104 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_only,
1108 struct virtchnl_proto_hdrs hdrs_hint_ipv6_ah = {
1109 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_only,
1113 struct virtchnl_proto_hdrs hdrs_hint_ipv6_l2tpv3 = {
1114 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_only,
1118 struct virtchnl_proto_hdrs hdrs_hint_ipv6_pfcp = {
1119 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_only,
1123 struct virtchnl_proto_hdrs hdrs_hint_ipv6_udp_esp = {
1124 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_ipv6_only,
1125 proto_hint_udp_only, proto_hint_esp }
1128 struct iavf_hash_match_type iavf_hash_map_list[] = {
1130 {ETH_RSS_L2_SRC_ONLY,
1131 &hdrs_hint_eth_src_ipv4, IAVF_PHINT_IPV4},
1132 {ETH_RSS_L2_DST_ONLY,
1133 &hdrs_hint_eth_dst_ipv4, IAVF_PHINT_IPV4},
1135 &hdrs_hint_eth_ipv4, IAVF_PHINT_IPV4},
1136 {ETH_RSS_L3_SRC_ONLY,
1137 &hdrs_hint_ipv4_src, IAVF_PHINT_IPV4},
1138 {ETH_RSS_L3_DST_ONLY,
1139 &hdrs_hint_ipv4_dst, IAVF_PHINT_IPV4},
1140 {ETH_RSS_IPV4 | ETH_RSS_L3_SRC_ONLY,
1141 &hdrs_hint_ipv4_src, IAVF_PHINT_IPV4},
1142 {ETH_RSS_IPV4 | ETH_RSS_L3_DST_ONLY,
1143 &hdrs_hint_ipv4_dst, IAVF_PHINT_IPV4},
1145 &hdrs_hint_ipv4, IAVF_PHINT_IPV4},
1147 &hdrs_hint_ipv4_esp, IAVF_PHINT_IPV4},
1149 &hdrs_hint_ipv4_ah, IAVF_PHINT_IPV4},
1151 &hdrs_hint_ipv4_l2tpv3, IAVF_PHINT_IPV4},
1153 &hdrs_hint_svlan_ipv4, IAVF_PHINT_IPV4},
1155 &hdrs_hint_svlan_ipv4_udp, IAVF_PHINT_IPV4_UDP},
1157 &hdrs_hint_svlan_ipv4_tcp, IAVF_PHINT_IPV4_TCP},
1159 &hdrs_hint_svlan_ipv4_sctp, IAVF_PHINT_IPV4_SCTP},
1161 &hdrs_hint_cvlan_ipv4, IAVF_PHINT_IPV4},
1163 &hdrs_hint_cvlan_ipv4_udp, IAVF_PHINT_IPV4_UDP},
1165 &hdrs_hint_cvlan_ipv4_tcp, IAVF_PHINT_IPV4_TCP},
1167 &hdrs_hint_cvlan_ipv4_sctp, IAVF_PHINT_IPV4_SCTP},
1169 {ETH_RSS_L2_SRC_ONLY,
1170 &hdrs_hint_eth_src_ipv4_udp, IAVF_PHINT_IPV4_UDP},
1171 {ETH_RSS_L2_DST_ONLY,
1172 &hdrs_hint_eth_dst_ipv4_udp, IAVF_PHINT_IPV4_UDP},
1174 &hdrs_hint_eth_ipv4_udp, IAVF_PHINT_IPV4_UDP},
1175 {ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_SRC_ONLY,
1176 &hdrs_hint_ipv4_src_udp_src_port, IAVF_PHINT_IPV4_UDP},
1177 {ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_DST_ONLY,
1178 &hdrs_hint_ipv4_src_udp_dst_port, IAVF_PHINT_IPV4_UDP},
1179 {ETH_RSS_L3_SRC_ONLY,
1180 &hdrs_hint_ipv4_src, IAVF_PHINT_IPV4_UDP},
1181 {ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_SRC_ONLY,
1182 &hdrs_hint_ipv4_dst_udp_src_port, IAVF_PHINT_IPV4_UDP},
1183 {ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_DST_ONLY,
1184 &hdrs_hint_ipv4_dst_udp_dst_port, IAVF_PHINT_IPV4_UDP},
1185 {ETH_RSS_L3_DST_ONLY,
1186 &hdrs_hint_ipv4_dst, IAVF_PHINT_IPV4_UDP},
1187 {ETH_RSS_NONFRAG_IPV4_UDP |
1188 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_SRC_ONLY,
1189 &hdrs_hint_ipv4_src_udp_src_port, IAVF_PHINT_IPV4_UDP},
1190 {ETH_RSS_NONFRAG_IPV4_UDP |
1191 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_DST_ONLY,
1192 &hdrs_hint_ipv4_src_udp_dst_port, IAVF_PHINT_IPV4_UDP},
1193 {ETH_RSS_NONFRAG_IPV4_UDP |
1194 ETH_RSS_L3_SRC_ONLY, &hdrs_hint_ipv4_src,
1195 IAVF_PHINT_IPV4_UDP},
1196 {ETH_RSS_NONFRAG_IPV4_UDP |
1197 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_SRC_ONLY,
1198 &hdrs_hint_ipv4_dst_udp_src_port, IAVF_PHINT_IPV4_UDP},
1199 {ETH_RSS_NONFRAG_IPV4_UDP |
1200 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_DST_ONLY,
1201 &hdrs_hint_ipv4_dst_udp_dst_port, IAVF_PHINT_IPV4_UDP},
1202 {ETH_RSS_NONFRAG_IPV4_UDP |
1203 ETH_RSS_L3_DST_ONLY, &hdrs_hint_ipv4_dst,
1204 IAVF_PHINT_IPV4_UDP},
1205 {ETH_RSS_L4_SRC_ONLY,
1206 &hdrs_hint_ipv4_udp_src_port, IAVF_PHINT_IPV4_UDP},
1207 {ETH_RSS_L4_DST_ONLY,
1208 &hdrs_hint_ipv4_udp_dst_port, IAVF_PHINT_IPV4_UDP},
1209 {ETH_RSS_NONFRAG_IPV4_UDP | ETH_RSS_L4_SRC_ONLY,
1210 &hdrs_hint_ipv4_udp_src_port, IAVF_PHINT_IPV4_UDP},
1211 {ETH_RSS_NONFRAG_IPV4_UDP | ETH_RSS_L4_DST_ONLY,
1212 &hdrs_hint_ipv4_udp_dst_port, IAVF_PHINT_IPV4_UDP},
1214 &hdrs_hint_ipv4_pfcp, IAVF_PHINT_IPV4_UDP},
1216 &hdrs_hint_ipv4_udp_esp, IAVF_PHINT_IPV4_UDP},
1217 {ETH_RSS_NONFRAG_IPV4_UDP,
1218 &hdrs_hint_ipv4_udp, IAVF_PHINT_IPV4_UDP},
1220 {ETH_RSS_L2_SRC_ONLY,
1221 &hdrs_hint_eth_src_ipv4_tcp, IAVF_PHINT_IPV4_TCP},
1222 {ETH_RSS_L2_DST_ONLY,
1223 &hdrs_hint_eth_dst_ipv4_tcp, IAVF_PHINT_IPV4_TCP},
1225 &hdrs_hint_eth_ipv4_tcp, IAVF_PHINT_IPV4_TCP},
1226 {ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_SRC_ONLY,
1227 &hdrs_hint_ipv4_src_tcp_src_port, IAVF_PHINT_IPV4_TCP},
1228 {ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_DST_ONLY,
1229 &hdrs_hint_ipv4_src_tcp_dst_port, IAVF_PHINT_IPV4_TCP},
1230 {ETH_RSS_L3_SRC_ONLY,
1231 &hdrs_hint_ipv4_src, IAVF_PHINT_IPV4_TCP},
1232 {ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_SRC_ONLY,
1233 &hdrs_hint_ipv4_dst_tcp_src_port, IAVF_PHINT_IPV4_TCP},
1234 {ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_DST_ONLY,
1235 &hdrs_hint_ipv4_dst_tcp_dst_port, IAVF_PHINT_IPV4_TCP},
1236 {ETH_RSS_L3_DST_ONLY,
1237 &hdrs_hint_ipv4_dst, IAVF_PHINT_IPV4_TCP},
1238 {ETH_RSS_NONFRAG_IPV4_TCP |
1239 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_SRC_ONLY,
1240 &hdrs_hint_ipv4_src_tcp_src_port, IAVF_PHINT_IPV4_TCP},
1241 {ETH_RSS_NONFRAG_IPV4_TCP |
1242 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_DST_ONLY,
1243 &hdrs_hint_ipv4_src_tcp_dst_port, IAVF_PHINT_IPV4_TCP},
1244 {ETH_RSS_NONFRAG_IPV4_TCP |
1245 ETH_RSS_L3_SRC_ONLY, &hdrs_hint_ipv4_src,
1246 IAVF_PHINT_IPV4_TCP},
1247 {ETH_RSS_NONFRAG_IPV4_TCP |
1248 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_SRC_ONLY,
1249 &hdrs_hint_ipv4_dst_tcp_src_port, IAVF_PHINT_IPV4_TCP},
1250 {ETH_RSS_NONFRAG_IPV4_TCP |
1251 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_DST_ONLY,
1252 &hdrs_hint_ipv4_dst_tcp_dst_port, IAVF_PHINT_IPV4_TCP},
1253 {ETH_RSS_NONFRAG_IPV4_TCP |
1254 ETH_RSS_L3_DST_ONLY, &hdrs_hint_ipv4_dst,
1255 IAVF_PHINT_IPV4_TCP},
1256 {ETH_RSS_L4_SRC_ONLY,
1257 &hdrs_hint_ipv4_tcp_src_port, IAVF_PHINT_IPV4_TCP},
1258 {ETH_RSS_L4_DST_ONLY,
1259 &hdrs_hint_ipv4_tcp_dst_port, IAVF_PHINT_IPV4_TCP},
1260 {ETH_RSS_NONFRAG_IPV4_TCP | ETH_RSS_L4_SRC_ONLY,
1261 &hdrs_hint_ipv4_tcp_src_port, IAVF_PHINT_IPV4_TCP},
1262 {ETH_RSS_NONFRAG_IPV4_TCP | ETH_RSS_L4_DST_ONLY,
1263 &hdrs_hint_ipv4_tcp_dst_port, IAVF_PHINT_IPV4_TCP},
1264 {ETH_RSS_NONFRAG_IPV4_TCP,
1265 &hdrs_hint_ipv4_tcp, IAVF_PHINT_IPV4_TCP},
1267 {ETH_RSS_L2_SRC_ONLY,
1268 &hdrs_hint_eth_src_ipv4_sctp, IAVF_PHINT_IPV4_SCTP},
1269 {ETH_RSS_L2_DST_ONLY,
1270 &hdrs_hint_eth_dst_ipv4_sctp, IAVF_PHINT_IPV4_SCTP},
1272 &hdrs_hint_eth_ipv4_sctp, IAVF_PHINT_IPV4_SCTP},
1273 {ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_SRC_ONLY,
1274 &hdrs_hint_ipv4_src_sctp_src_port, IAVF_PHINT_IPV4_SCTP},
1275 {ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_DST_ONLY,
1276 &hdrs_hint_ipv4_src_sctp_dst_port, IAVF_PHINT_IPV4_SCTP},
1277 {ETH_RSS_L3_SRC_ONLY,
1278 &hdrs_hint_ipv4_src, IAVF_PHINT_IPV4_SCTP},
1279 {ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_SRC_ONLY,
1280 &hdrs_hint_ipv4_dst_sctp_src_port, IAVF_PHINT_IPV4_SCTP},
1281 {ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_DST_ONLY,
1282 &hdrs_hint_ipv4_dst_sctp_dst_port, IAVF_PHINT_IPV4_SCTP},
1283 {ETH_RSS_L3_DST_ONLY,
1284 &hdrs_hint_ipv4_dst, IAVF_PHINT_IPV4_SCTP},
1285 {ETH_RSS_NONFRAG_IPV4_SCTP |
1286 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_SRC_ONLY,
1287 &hdrs_hint_ipv4_src_sctp_src_port, IAVF_PHINT_IPV4_SCTP},
1288 {ETH_RSS_NONFRAG_IPV4_SCTP |
1289 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_DST_ONLY,
1290 &hdrs_hint_ipv4_src_sctp_dst_port, IAVF_PHINT_IPV4_SCTP},
1291 {ETH_RSS_NONFRAG_IPV4_SCTP |
1292 ETH_RSS_L3_SRC_ONLY, &hdrs_hint_ipv4_src,
1293 IAVF_PHINT_IPV4_SCTP},
1294 {ETH_RSS_NONFRAG_IPV4_SCTP |
1295 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_SRC_ONLY,
1296 &hdrs_hint_ipv4_dst_sctp_src_port, IAVF_PHINT_IPV4_SCTP},
1297 {ETH_RSS_NONFRAG_IPV4_SCTP |
1298 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_DST_ONLY,
1299 &hdrs_hint_ipv4_dst_sctp_dst_port, IAVF_PHINT_IPV4_SCTP},
1300 {ETH_RSS_NONFRAG_IPV4_SCTP |
1301 ETH_RSS_L3_DST_ONLY, &hdrs_hint_ipv4_dst,
1302 IAVF_PHINT_IPV4_SCTP},
1303 {ETH_RSS_L4_SRC_ONLY,
1304 &hdrs_hint_ipv4_sctp_src_port, IAVF_PHINT_IPV4_SCTP},
1305 {ETH_RSS_L4_DST_ONLY,
1306 &hdrs_hint_ipv4_sctp_dst_port, IAVF_PHINT_IPV4_SCTP},
1307 {ETH_RSS_NONFRAG_IPV4_SCTP | ETH_RSS_L4_SRC_ONLY,
1308 &hdrs_hint_ipv4_sctp_src_port, IAVF_PHINT_IPV4_SCTP},
1309 {ETH_RSS_NONFRAG_IPV4_SCTP | ETH_RSS_L4_DST_ONLY,
1310 &hdrs_hint_ipv4_sctp_dst_port, IAVF_PHINT_IPV4_SCTP},
1311 {ETH_RSS_NONFRAG_IPV4_SCTP,
1312 &hdrs_hint_ipv4_sctp, IAVF_PHINT_IPV4_SCTP},
1314 {ETH_RSS_L2_SRC_ONLY,
1315 &hdrs_hint_eth_src_ipv6, IAVF_PHINT_IPV6},
1316 {ETH_RSS_L2_DST_ONLY,
1317 &hdrs_hint_eth_dst_ipv6, IAVF_PHINT_IPV6},
1319 &hdrs_hint_eth_ipv6, IAVF_PHINT_IPV6},
1320 {ETH_RSS_L3_SRC_ONLY,
1321 &hdrs_hint_ipv6_src, IAVF_PHINT_IPV6},
1322 {ETH_RSS_L3_DST_ONLY,
1323 &hdrs_hint_ipv6_dst, IAVF_PHINT_IPV6},
1324 {ETH_RSS_IPV6 | ETH_RSS_L3_SRC_ONLY,
1325 &hdrs_hint_ipv6_src, IAVF_PHINT_IPV6},
1326 {ETH_RSS_IPV6 | ETH_RSS_L3_DST_ONLY,
1327 &hdrs_hint_ipv6_dst, IAVF_PHINT_IPV6},
1329 &hdrs_hint_ipv6, IAVF_PHINT_IPV6},
1331 &hdrs_hint_ipv6_esp, IAVF_PHINT_IPV6},
1333 &hdrs_hint_ipv6_ah, IAVF_PHINT_IPV6},
1335 &hdrs_hint_ipv6_l2tpv3, IAVF_PHINT_IPV6},
1337 {ETH_RSS_L2_SRC_ONLY,
1338 &hdrs_hint_eth_src_ipv6_udp, IAVF_PHINT_IPV6_UDP},
1339 {ETH_RSS_L2_DST_ONLY,
1340 &hdrs_hint_eth_dst_ipv6_udp, IAVF_PHINT_IPV6_UDP},
1342 &hdrs_hint_eth_ipv6_udp, IAVF_PHINT_IPV6_UDP},
1343 {ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_SRC_ONLY,
1344 &hdrs_hint_ipv6_src_udp_src_port, IAVF_PHINT_IPV6_UDP},
1345 {ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_DST_ONLY,
1346 &hdrs_hint_ipv6_src_udp_dst_port, IAVF_PHINT_IPV6_UDP},
1347 {ETH_RSS_L3_SRC_ONLY,
1348 &hdrs_hint_ipv6_src, IAVF_PHINT_IPV6_UDP},
1349 {ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_SRC_ONLY,
1350 &hdrs_hint_ipv6_dst_udp_src_port, IAVF_PHINT_IPV6_UDP},
1351 {ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_DST_ONLY,
1352 &hdrs_hint_ipv6_dst_udp_dst_port, IAVF_PHINT_IPV6_UDP},
1353 {ETH_RSS_L3_DST_ONLY,
1354 &hdrs_hint_ipv6_dst, IAVF_PHINT_IPV6_UDP},
1355 {ETH_RSS_NONFRAG_IPV6_UDP |
1356 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_SRC_ONLY,
1357 &hdrs_hint_ipv6_src_udp_src_port, IAVF_PHINT_IPV6_UDP},
1358 {ETH_RSS_NONFRAG_IPV6_UDP |
1359 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_DST_ONLY,
1360 &hdrs_hint_ipv6_src_udp_dst_port, IAVF_PHINT_IPV6_UDP},
1361 {ETH_RSS_NONFRAG_IPV6_UDP |
1362 ETH_RSS_L3_SRC_ONLY, &hdrs_hint_ipv6_src,
1363 IAVF_PHINT_IPV6_UDP},
1364 {ETH_RSS_NONFRAG_IPV6_UDP |
1365 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_SRC_ONLY,
1366 &hdrs_hint_ipv6_dst_udp_src_port, IAVF_PHINT_IPV6_UDP},
1367 {ETH_RSS_NONFRAG_IPV6_UDP |
1368 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_DST_ONLY,
1369 &hdrs_hint_ipv6_dst_udp_dst_port, IAVF_PHINT_IPV6_UDP},
1370 {ETH_RSS_NONFRAG_IPV6_UDP |
1371 ETH_RSS_L3_DST_ONLY, &hdrs_hint_ipv6_dst,
1372 IAVF_PHINT_IPV6_UDP},
1373 {ETH_RSS_L4_SRC_ONLY,
1374 &hdrs_hint_ipv6_udp_src_port, IAVF_PHINT_IPV6_UDP},
1375 {ETH_RSS_L4_DST_ONLY,
1376 &hdrs_hint_ipv6_udp_dst_port, IAVF_PHINT_IPV6_UDP},
1377 {ETH_RSS_NONFRAG_IPV6_UDP | ETH_RSS_L4_SRC_ONLY,
1378 &hdrs_hint_ipv6_udp_src_port, IAVF_PHINT_IPV6_UDP},
1379 {ETH_RSS_NONFRAG_IPV6_UDP | ETH_RSS_L4_DST_ONLY,
1380 &hdrs_hint_ipv6_udp_dst_port, IAVF_PHINT_IPV6_UDP},
1382 &hdrs_hint_ipv6_pfcp, IAVF_PHINT_IPV6_UDP},
1384 &hdrs_hint_ipv6_udp_esp, IAVF_PHINT_IPV6_UDP},
1385 {ETH_RSS_NONFRAG_IPV6_UDP,
1386 &hdrs_hint_ipv6_udp, IAVF_PHINT_IPV6_UDP},
1388 {ETH_RSS_L2_SRC_ONLY,
1389 &hdrs_hint_eth_src_ipv6_tcp, IAVF_PHINT_IPV6_TCP},
1390 {ETH_RSS_L2_DST_ONLY,
1391 &hdrs_hint_eth_dst_ipv6_tcp, IAVF_PHINT_IPV6_TCP},
1393 &hdrs_hint_eth_ipv6_tcp, IAVF_PHINT_IPV6_TCP},
1394 {ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_SRC_ONLY,
1395 &hdrs_hint_ipv6_src_tcp_src_port, IAVF_PHINT_IPV6_TCP},
1396 {ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_DST_ONLY,
1397 &hdrs_hint_ipv6_src_tcp_dst_port, IAVF_PHINT_IPV6_TCP},
1398 {ETH_RSS_L3_SRC_ONLY,
1399 &hdrs_hint_ipv6_src, IAVF_PHINT_IPV6_TCP},
1400 {ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_SRC_ONLY,
1401 &hdrs_hint_ipv6_dst_tcp_src_port, IAVF_PHINT_IPV6_TCP},
1402 {ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_DST_ONLY,
1403 &hdrs_hint_ipv6_dst_tcp_dst_port, IAVF_PHINT_IPV6_TCP},
1404 {ETH_RSS_L3_DST_ONLY,
1405 &hdrs_hint_ipv6_dst, IAVF_PHINT_IPV6_TCP},
1406 {ETH_RSS_NONFRAG_IPV6_TCP |
1407 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_SRC_ONLY,
1408 &hdrs_hint_ipv6_src_tcp_src_port, IAVF_PHINT_IPV6_TCP},
1409 {ETH_RSS_NONFRAG_IPV6_TCP |
1410 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_DST_ONLY,
1411 &hdrs_hint_ipv6_src_tcp_dst_port, IAVF_PHINT_IPV6_TCP},
1412 {ETH_RSS_NONFRAG_IPV6_TCP |
1413 ETH_RSS_L3_SRC_ONLY, &hdrs_hint_ipv6_src,
1414 IAVF_PHINT_IPV6_TCP},
1415 {ETH_RSS_NONFRAG_IPV6_TCP |
1416 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_SRC_ONLY,
1417 &hdrs_hint_ipv6_dst_tcp_src_port, IAVF_PHINT_IPV6_TCP},
1418 {ETH_RSS_NONFRAG_IPV6_TCP |
1419 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_DST_ONLY,
1420 &hdrs_hint_ipv6_dst_tcp_dst_port, IAVF_PHINT_IPV6_TCP},
1421 {ETH_RSS_NONFRAG_IPV6_TCP |
1422 ETH_RSS_L3_DST_ONLY, &hdrs_hint_ipv6_dst,
1423 IAVF_PHINT_IPV6_TCP},
1424 {ETH_RSS_L4_SRC_ONLY,
1425 &hdrs_hint_ipv6_tcp_src_port, IAVF_PHINT_IPV6_TCP},
1426 {ETH_RSS_L4_DST_ONLY,
1427 &hdrs_hint_ipv6_tcp_dst_port, IAVF_PHINT_IPV6_TCP},
1428 {ETH_RSS_NONFRAG_IPV6_TCP | ETH_RSS_L4_SRC_ONLY,
1429 &hdrs_hint_ipv6_tcp_src_port, IAVF_PHINT_IPV6_TCP},
1430 {ETH_RSS_NONFRAG_IPV6_TCP | ETH_RSS_L4_DST_ONLY,
1431 &hdrs_hint_ipv6_tcp_dst_port, IAVF_PHINT_IPV6_TCP},
1432 {ETH_RSS_NONFRAG_IPV6_TCP,
1433 &hdrs_hint_ipv6_tcp, IAVF_PHINT_IPV6_TCP},
1435 {ETH_RSS_L2_SRC_ONLY,
1436 &hdrs_hint_eth_src_ipv6_sctp, IAVF_PHINT_IPV6_SCTP},
1437 {ETH_RSS_L2_DST_ONLY,
1438 &hdrs_hint_eth_dst_ipv6_sctp, IAVF_PHINT_IPV6_SCTP},
1440 &hdrs_hint_eth_ipv6_sctp, IAVF_PHINT_IPV6_SCTP},
1441 {ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_SRC_ONLY,
1442 &hdrs_hint_ipv6_src_sctp_src_port, IAVF_PHINT_IPV6_SCTP},
1443 {ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_DST_ONLY,
1444 &hdrs_hint_ipv6_src_sctp_dst_port, IAVF_PHINT_IPV6_SCTP},
1445 {ETH_RSS_L3_SRC_ONLY,
1446 &hdrs_hint_ipv6_src, IAVF_PHINT_IPV6_SCTP},
1447 {ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_SRC_ONLY,
1448 &hdrs_hint_ipv6_dst_sctp_src_port, IAVF_PHINT_IPV6_SCTP},
1449 {ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_DST_ONLY,
1450 &hdrs_hint_ipv6_dst_sctp_dst_port, IAVF_PHINT_IPV6_SCTP},
1451 {ETH_RSS_L3_DST_ONLY,
1452 &hdrs_hint_ipv6_dst, IAVF_PHINT_IPV6_SCTP},
1453 {ETH_RSS_NONFRAG_IPV6_SCTP |
1454 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_SRC_ONLY,
1455 &hdrs_hint_ipv6_src_sctp_src_port, IAVF_PHINT_IPV6_SCTP},
1456 {ETH_RSS_NONFRAG_IPV6_SCTP |
1457 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_DST_ONLY,
1458 &hdrs_hint_ipv6_src_sctp_dst_port, IAVF_PHINT_IPV6_SCTP},
1459 {ETH_RSS_NONFRAG_IPV6_SCTP |
1460 ETH_RSS_L3_SRC_ONLY, &hdrs_hint_ipv6_src,
1461 IAVF_PHINT_IPV6_SCTP},
1462 {ETH_RSS_NONFRAG_IPV6_SCTP |
1463 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_SRC_ONLY,
1464 &hdrs_hint_ipv6_dst_sctp_src_port, IAVF_PHINT_IPV6_SCTP},
1465 {ETH_RSS_NONFRAG_IPV6_SCTP |
1466 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_DST_ONLY,
1467 &hdrs_hint_ipv6_dst_sctp_dst_port, IAVF_PHINT_IPV6_SCTP},
1468 {ETH_RSS_NONFRAG_IPV6_SCTP |
1469 ETH_RSS_L3_DST_ONLY, &hdrs_hint_ipv6_dst,
1470 IAVF_PHINT_IPV6_SCTP},
1471 {ETH_RSS_L4_SRC_ONLY,
1472 &hdrs_hint_ipv6_sctp_src_port, IAVF_PHINT_IPV6_SCTP},
1473 {ETH_RSS_L4_DST_ONLY,
1474 &hdrs_hint_ipv6_sctp_dst_port, IAVF_PHINT_IPV6_SCTP},
1475 {ETH_RSS_NONFRAG_IPV6_SCTP | ETH_RSS_L4_SRC_ONLY,
1476 &hdrs_hint_ipv6_sctp_src_port, IAVF_PHINT_IPV6_SCTP},
1477 {ETH_RSS_NONFRAG_IPV6_SCTP | ETH_RSS_L4_DST_ONLY,
1478 &hdrs_hint_ipv6_sctp_dst_port, IAVF_PHINT_IPV6_SCTP},
1479 {ETH_RSS_NONFRAG_IPV6_SCTP,
1480 &hdrs_hint_ipv6_sctp, IAVF_PHINT_IPV6_SCTP},
1482 &hdrs_hint_svlan_ipv6, IAVF_PHINT_IPV6},
1484 &hdrs_hint_svlan_ipv6_udp, IAVF_PHINT_IPV6_UDP},
1486 &hdrs_hint_svlan_ipv6_tcp, IAVF_PHINT_IPV6_TCP},
1488 &hdrs_hint_svlan_ipv6_sctp, IAVF_PHINT_IPV6_SCTP},
1490 &hdrs_hint_cvlan_ipv6, IAVF_PHINT_IPV6},
1492 &hdrs_hint_cvlan_ipv6_udp, IAVF_PHINT_IPV6_UDP},
1494 &hdrs_hint_cvlan_ipv6_tcp, IAVF_PHINT_IPV6_TCP},
1496 &hdrs_hint_cvlan_ipv6_sctp, IAVF_PHINT_IPV6_SCTP},
1499 struct iavf_hash_match_type iavf_gtpu_hash_map_list[] = {
1503 {ETH_RSS_L3_SRC_ONLY,
1504 &hdrs_hint_ipv4_src_gtpu_eh,
1505 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4},
1506 {ETH_RSS_L3_DST_ONLY,
1507 &hdrs_hint_ipv4_dst_gtpu_eh,
1508 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4},
1510 ETH_RSS_L3_SRC_ONLY,
1511 &hdrs_hint_ipv4_src_gtpu_eh,
1512 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4},
1514 ETH_RSS_L3_DST_ONLY,
1515 &hdrs_hint_ipv4_dst_gtpu_eh,
1516 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4},
1518 &hdrs_hint_ipv4_gtpu_eh,
1519 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4},
1520 /* Inner IPV4->UDP */
1521 {ETH_RSS_L3_SRC_ONLY |
1522 ETH_RSS_L4_SRC_ONLY,
1523 &hdrs_hint_ipv4_src_udp_src_gtpu_eh,
1524 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_UDP},
1525 {ETH_RSS_L3_SRC_ONLY |
1526 ETH_RSS_L4_DST_ONLY,
1527 &hdrs_hint_ipv4_src_udp_dst_gtpu_eh,
1528 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_UDP},
1529 {ETH_RSS_L3_SRC_ONLY,
1530 &hdrs_hint_ipv4_src_gtpu_eh,
1531 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_UDP},
1532 {ETH_RSS_L4_SRC_ONLY,
1533 &hdrs_hint_ipv4_udp_src_gtpu_eh,
1534 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_UDP},
1535 {ETH_RSS_L3_DST_ONLY |
1536 ETH_RSS_L4_SRC_ONLY,
1537 &hdrs_hint_ipv4_dst_udp_src_gtpu_eh,
1538 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_UDP},
1539 {ETH_RSS_L3_DST_ONLY |
1540 ETH_RSS_L4_DST_ONLY,
1541 &hdrs_hint_ipv4_dst_udp_dst_gtpu_eh,
1542 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_UDP},
1543 {ETH_RSS_L3_DST_ONLY,
1544 &hdrs_hint_ipv4_dst_gtpu_eh,
1545 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_UDP},
1546 {ETH_RSS_L4_DST_ONLY,
1547 &hdrs_hint_ipv4_udp_dst_gtpu_eh,
1548 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_UDP},
1549 {ETH_RSS_NONFRAG_IPV4_UDP |
1550 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_SRC_ONLY,
1551 &hdrs_hint_ipv4_src_udp_src_gtpu_eh,
1552 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_UDP},
1553 {ETH_RSS_NONFRAG_IPV4_UDP |
1554 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_DST_ONLY,
1555 &hdrs_hint_ipv4_src_udp_dst_gtpu_eh,
1556 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_UDP},
1557 {ETH_RSS_NONFRAG_IPV4_UDP |
1558 ETH_RSS_L3_SRC_ONLY,
1559 &hdrs_hint_ipv4_src_gtpu_eh,
1560 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_UDP},
1561 {ETH_RSS_NONFRAG_IPV4_UDP |
1562 ETH_RSS_L4_SRC_ONLY,
1563 &hdrs_hint_ipv4_udp_src_gtpu_eh,
1564 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_UDP},
1565 {ETH_RSS_NONFRAG_IPV4_UDP |
1566 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_SRC_ONLY,
1567 &hdrs_hint_ipv4_dst_udp_src_gtpu_eh,
1568 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_UDP},
1569 {ETH_RSS_NONFRAG_IPV4_UDP |
1570 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_DST_ONLY,
1571 &hdrs_hint_ipv4_dst_udp_dst_gtpu_eh,
1572 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_UDP},
1573 {ETH_RSS_NONFRAG_IPV4_UDP |
1574 ETH_RSS_L3_DST_ONLY,
1575 &hdrs_hint_ipv4_dst_gtpu_eh,
1576 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_UDP},
1577 {ETH_RSS_NONFRAG_IPV4_UDP |
1578 ETH_RSS_L4_DST_ONLY,
1579 &hdrs_hint_ipv4_udp_dst_gtpu_eh,
1580 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_UDP},
1581 {ETH_RSS_NONFRAG_IPV4_UDP,
1582 &hdrs_hint_ipv4_udp_gtpu_eh,
1583 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_UDP},
1584 /* Inner IPV4->TCP */
1585 {ETH_RSS_L3_SRC_ONLY |
1586 ETH_RSS_L4_SRC_ONLY,
1587 &hdrs_hint_ipv4_src_tcp_src_gtpu_eh,
1588 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_TCP},
1589 {ETH_RSS_L3_SRC_ONLY |
1590 ETH_RSS_L4_DST_ONLY,
1591 &hdrs_hint_ipv4_src_tcp_dst_gtpu_eh,
1592 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_TCP},
1593 {ETH_RSS_L3_SRC_ONLY,
1594 &hdrs_hint_ipv4_src_gtpu_eh,
1595 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_TCP},
1596 {ETH_RSS_L4_SRC_ONLY,
1597 &hdrs_hint_ipv4_tcp_src_gtpu_eh,
1598 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_TCP},
1599 {ETH_RSS_L3_DST_ONLY |
1600 ETH_RSS_L4_SRC_ONLY,
1601 &hdrs_hint_ipv4_dst_tcp_src_gtpu_eh,
1602 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_TCP},
1603 {ETH_RSS_L3_DST_ONLY |
1604 ETH_RSS_L4_DST_ONLY,
1605 &hdrs_hint_ipv4_dst_tcp_dst_gtpu_eh,
1606 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_TCP},
1607 {ETH_RSS_L3_DST_ONLY,
1608 &hdrs_hint_ipv4_dst_gtpu_eh,
1609 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_TCP},
1610 {ETH_RSS_L4_DST_ONLY,
1611 &hdrs_hint_ipv4_tcp_dst_gtpu_eh,
1612 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_TCP},
1613 {ETH_RSS_NONFRAG_IPV4_TCP |
1614 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_SRC_ONLY,
1615 &hdrs_hint_ipv4_src_tcp_src_gtpu_eh,
1616 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_TCP},
1617 {ETH_RSS_NONFRAG_IPV4_TCP |
1618 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_DST_ONLY,
1619 &hdrs_hint_ipv4_src_tcp_dst_gtpu_eh,
1620 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_TCP},
1621 {ETH_RSS_NONFRAG_IPV4_TCP |
1622 ETH_RSS_L3_SRC_ONLY,
1623 &hdrs_hint_ipv4_src_gtpu_eh,
1624 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_TCP},
1625 {ETH_RSS_NONFRAG_IPV4_TCP |
1626 ETH_RSS_L4_SRC_ONLY,
1627 &hdrs_hint_ipv4_tcp_src_gtpu_eh,
1628 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_TCP},
1629 {ETH_RSS_NONFRAG_IPV4_TCP |
1630 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_SRC_ONLY,
1631 &hdrs_hint_ipv4_dst_tcp_src_gtpu_eh,
1632 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_TCP},
1633 {ETH_RSS_NONFRAG_IPV4_TCP |
1634 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_DST_ONLY,
1635 &hdrs_hint_ipv4_dst_tcp_dst_gtpu_eh,
1636 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_TCP},
1637 {ETH_RSS_NONFRAG_IPV4_TCP |
1638 ETH_RSS_L3_DST_ONLY,
1639 &hdrs_hint_ipv4_dst_gtpu_eh,
1640 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_TCP},
1641 {ETH_RSS_NONFRAG_IPV4_TCP |
1642 ETH_RSS_L4_DST_ONLY,
1643 &hdrs_hint_ipv4_tcp_dst_gtpu_eh,
1644 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_TCP},
1645 {ETH_RSS_NONFRAG_IPV4_TCP,
1646 &hdrs_hint_ipv4_tcp_gtpu_eh,
1647 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_TCP},
1650 {ETH_RSS_L3_SRC_ONLY,
1651 &hdrs_hint_ipv4_src_gtpu_up,
1652 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4},
1653 {ETH_RSS_L3_DST_ONLY,
1654 &hdrs_hint_ipv4_dst_gtpu_up,
1655 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4},
1657 ETH_RSS_L3_SRC_ONLY,
1658 &hdrs_hint_ipv4_src_gtpu_up,
1659 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4},
1661 ETH_RSS_L3_DST_ONLY,
1662 &hdrs_hint_ipv4_dst_gtpu_up,
1663 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4},
1665 &hdrs_hint_ipv4_gtpu_up,
1666 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4},
1667 /* Inner IPV4->UDP */
1668 {ETH_RSS_L3_SRC_ONLY |
1669 ETH_RSS_L4_SRC_ONLY,
1670 &hdrs_hint_ipv4_src_udp_src_gtpu_up,
1671 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_UDP},
1672 {ETH_RSS_L3_SRC_ONLY |
1673 ETH_RSS_L4_DST_ONLY,
1674 &hdrs_hint_ipv4_src_udp_dst_gtpu_up,
1675 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_UDP},
1676 {ETH_RSS_L3_SRC_ONLY,
1677 &hdrs_hint_ipv4_src_gtpu_up,
1678 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_UDP},
1679 {ETH_RSS_L4_SRC_ONLY,
1680 &hdrs_hint_ipv4_udp_src_gtpu_up,
1681 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_UDP},
1682 {ETH_RSS_L3_DST_ONLY |
1683 ETH_RSS_L4_SRC_ONLY,
1684 &hdrs_hint_ipv4_dst_udp_src_gtpu_up,
1685 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_UDP},
1686 {ETH_RSS_L3_DST_ONLY |
1687 ETH_RSS_L4_DST_ONLY,
1688 &hdrs_hint_ipv4_dst_udp_dst_gtpu_up,
1689 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_UDP},
1690 {ETH_RSS_L3_DST_ONLY,
1691 &hdrs_hint_ipv4_dst_gtpu_up,
1692 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_UDP},
1693 {ETH_RSS_L4_DST_ONLY,
1694 &hdrs_hint_ipv4_udp_dst_gtpu_up,
1695 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_UDP},
1696 {ETH_RSS_NONFRAG_IPV4_UDP |
1697 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_SRC_ONLY,
1698 &hdrs_hint_ipv4_src_udp_src_gtpu_up,
1699 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_UDP},
1700 {ETH_RSS_NONFRAG_IPV4_UDP |
1701 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_DST_ONLY,
1702 &hdrs_hint_ipv4_src_udp_dst_gtpu_up,
1703 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_UDP},
1704 {ETH_RSS_NONFRAG_IPV4_UDP |
1705 ETH_RSS_L3_SRC_ONLY,
1706 &hdrs_hint_ipv4_src_gtpu_up,
1707 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_UDP},
1708 {ETH_RSS_NONFRAG_IPV4_UDP |
1709 ETH_RSS_L4_SRC_ONLY,
1710 &hdrs_hint_ipv4_udp_src_gtpu_up,
1711 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_UDP},
1712 {ETH_RSS_NONFRAG_IPV4_UDP |
1713 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_SRC_ONLY,
1714 &hdrs_hint_ipv4_dst_udp_src_gtpu_up,
1715 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_UDP},
1716 {ETH_RSS_NONFRAG_IPV4_UDP |
1717 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_DST_ONLY,
1718 &hdrs_hint_ipv4_dst_udp_dst_gtpu_up,
1719 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_UDP},
1720 {ETH_RSS_NONFRAG_IPV4_UDP |
1721 ETH_RSS_L3_DST_ONLY,
1722 &hdrs_hint_ipv4_dst_gtpu_up,
1723 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_UDP},
1724 {ETH_RSS_NONFRAG_IPV4_UDP |
1725 ETH_RSS_L4_DST_ONLY,
1726 &hdrs_hint_ipv4_udp_dst_gtpu_up,
1727 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_UDP},
1728 {ETH_RSS_NONFRAG_IPV4_UDP,
1729 &hdrs_hint_ipv4_udp_gtpu_up,
1730 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_UDP},
1731 /* Inner IPV4->TCP */
1732 {ETH_RSS_L3_SRC_ONLY |
1733 ETH_RSS_L4_SRC_ONLY,
1734 &hdrs_hint_ipv4_src_tcp_src_gtpu_up,
1735 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_TCP},
1736 {ETH_RSS_L3_SRC_ONLY |
1737 ETH_RSS_L4_DST_ONLY,
1738 &hdrs_hint_ipv4_src_tcp_dst_gtpu_up,
1739 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_TCP},
1740 {ETH_RSS_L3_SRC_ONLY,
1741 &hdrs_hint_ipv4_src_gtpu_up,
1742 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_TCP},
1743 {ETH_RSS_L4_SRC_ONLY,
1744 &hdrs_hint_ipv4_tcp_src_gtpu_up,
1745 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_TCP},
1746 {ETH_RSS_L3_DST_ONLY |
1747 ETH_RSS_L4_SRC_ONLY,
1748 &hdrs_hint_ipv4_dst_tcp_src_gtpu_up,
1749 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_TCP},
1750 {ETH_RSS_L3_DST_ONLY |
1751 ETH_RSS_L4_DST_ONLY,
1752 &hdrs_hint_ipv4_dst_tcp_dst_gtpu_up,
1753 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_TCP},
1754 {ETH_RSS_L3_DST_ONLY,
1755 &hdrs_hint_ipv4_dst_gtpu_up,
1756 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_TCP},
1757 {ETH_RSS_L4_DST_ONLY,
1758 &hdrs_hint_ipv4_tcp_dst_gtpu_up,
1759 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_TCP},
1760 {ETH_RSS_NONFRAG_IPV4_TCP |
1761 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_SRC_ONLY,
1762 &hdrs_hint_ipv4_src_tcp_src_gtpu_up,
1763 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_TCP},
1764 {ETH_RSS_NONFRAG_IPV4_TCP |
1765 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_DST_ONLY,
1766 &hdrs_hint_ipv4_src_tcp_dst_gtpu_up,
1767 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_TCP},
1768 {ETH_RSS_NONFRAG_IPV4_TCP |
1769 ETH_RSS_L3_SRC_ONLY,
1770 &hdrs_hint_ipv4_src_gtpu_up,
1771 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_TCP},
1772 {ETH_RSS_NONFRAG_IPV4_TCP |
1773 ETH_RSS_L4_SRC_ONLY,
1774 &hdrs_hint_ipv4_tcp_src_gtpu_up,
1775 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_TCP},
1776 {ETH_RSS_NONFRAG_IPV4_TCP |
1777 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_SRC_ONLY,
1778 &hdrs_hint_ipv4_dst_tcp_src_gtpu_up,
1779 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_TCP},
1780 {ETH_RSS_NONFRAG_IPV4_TCP |
1781 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_DST_ONLY,
1782 &hdrs_hint_ipv4_dst_tcp_dst_gtpu_up,
1783 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_TCP},
1784 {ETH_RSS_NONFRAG_IPV4_TCP |
1785 ETH_RSS_L3_DST_ONLY,
1786 &hdrs_hint_ipv4_dst_gtpu_up,
1787 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_TCP},
1788 {ETH_RSS_NONFRAG_IPV4_TCP |
1789 ETH_RSS_L4_DST_ONLY,
1790 &hdrs_hint_ipv4_tcp_dst_gtpu_up,
1791 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_TCP},
1792 {ETH_RSS_NONFRAG_IPV4_TCP,
1793 &hdrs_hint_ipv4_tcp_gtpu_up,
1794 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_TCP},
1797 {ETH_RSS_L3_SRC_ONLY,
1798 &hdrs_hint_ipv4_src_gtpu_dwn,
1799 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4},
1800 {ETH_RSS_L3_DST_ONLY,
1801 &hdrs_hint_ipv4_dst_gtpu_dwn,
1802 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4},
1804 ETH_RSS_L3_SRC_ONLY,
1805 &hdrs_hint_ipv4_src_gtpu_dwn,
1806 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4},
1808 ETH_RSS_L3_DST_ONLY,
1809 &hdrs_hint_ipv4_dst_gtpu_dwn,
1810 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4},
1812 &hdrs_hint_ipv4_gtpu_dwn,
1813 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4},
1814 /* Inner IPV4->UDP */
1815 {ETH_RSS_L3_SRC_ONLY |
1816 ETH_RSS_L4_SRC_ONLY,
1817 &hdrs_hint_ipv4_src_udp_src_gtpu_dwn,
1818 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_UDP},
1819 {ETH_RSS_L3_SRC_ONLY |
1820 ETH_RSS_L4_DST_ONLY,
1821 &hdrs_hint_ipv4_src_udp_dst_gtpu_dwn,
1822 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_UDP},
1823 {ETH_RSS_L3_SRC_ONLY,
1824 &hdrs_hint_ipv4_src_gtpu_dwn,
1825 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_UDP},
1826 {ETH_RSS_L4_SRC_ONLY,
1827 &hdrs_hint_ipv4_udp_src_gtpu_dwn,
1828 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_UDP},
1829 {ETH_RSS_L3_DST_ONLY |
1830 ETH_RSS_L4_SRC_ONLY,
1831 &hdrs_hint_ipv4_dst_udp_src_gtpu_dwn,
1832 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_UDP},
1833 {ETH_RSS_L3_DST_ONLY |
1834 ETH_RSS_L4_DST_ONLY,
1835 &hdrs_hint_ipv4_dst_udp_dst_gtpu_dwn,
1836 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_UDP},
1837 {ETH_RSS_L3_DST_ONLY,
1838 &hdrs_hint_ipv4_dst_gtpu_dwn,
1839 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_UDP},
1840 {ETH_RSS_L4_DST_ONLY,
1841 &hdrs_hint_ipv4_udp_dst_gtpu_dwn,
1842 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_UDP},
1843 {ETH_RSS_NONFRAG_IPV4_UDP |
1844 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_SRC_ONLY,
1845 &hdrs_hint_ipv4_src_udp_src_gtpu_dwn,
1846 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_UDP},
1847 {ETH_RSS_NONFRAG_IPV4_UDP |
1848 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_DST_ONLY,
1849 &hdrs_hint_ipv4_src_udp_dst_gtpu_dwn,
1850 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_UDP},
1851 {ETH_RSS_NONFRAG_IPV4_UDP |
1852 ETH_RSS_L3_SRC_ONLY,
1853 &hdrs_hint_ipv4_src_gtpu_dwn,
1854 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_UDP},
1855 {ETH_RSS_NONFRAG_IPV4_UDP |
1856 ETH_RSS_L4_SRC_ONLY,
1857 &hdrs_hint_ipv4_udp_src_gtpu_dwn,
1858 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_UDP},
1859 {ETH_RSS_NONFRAG_IPV4_UDP |
1860 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_SRC_ONLY,
1861 &hdrs_hint_ipv4_dst_udp_src_gtpu_dwn,
1862 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_UDP},
1863 {ETH_RSS_NONFRAG_IPV4_UDP |
1864 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_DST_ONLY,
1865 &hdrs_hint_ipv4_dst_udp_dst_gtpu_dwn,
1866 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_UDP},
1867 {ETH_RSS_NONFRAG_IPV4_UDP |
1868 ETH_RSS_L3_DST_ONLY,
1869 &hdrs_hint_ipv4_dst_gtpu_dwn,
1870 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_UDP},
1871 {ETH_RSS_NONFRAG_IPV4_UDP |
1872 ETH_RSS_L4_DST_ONLY,
1873 &hdrs_hint_ipv4_udp_dst_gtpu_dwn,
1874 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_UDP},
1875 {ETH_RSS_NONFRAG_IPV4_UDP,
1876 &hdrs_hint_ipv4_udp_gtpu_dwn,
1877 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_UDP},
1878 /* Inner IPV4->TCP */
1879 {ETH_RSS_L3_SRC_ONLY |
1880 ETH_RSS_L4_SRC_ONLY,
1881 &hdrs_hint_ipv4_src_tcp_src_gtpu_dwn,
1882 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_TCP},
1883 {ETH_RSS_L3_SRC_ONLY |
1884 ETH_RSS_L4_DST_ONLY,
1885 &hdrs_hint_ipv4_src_tcp_dst_gtpu_dwn,
1886 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_TCP},
1887 {ETH_RSS_L3_SRC_ONLY,
1888 &hdrs_hint_ipv4_src_gtpu_dwn,
1889 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_TCP},
1890 {ETH_RSS_L4_SRC_ONLY,
1891 &hdrs_hint_ipv4_tcp_src_gtpu_dwn,
1892 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_TCP},
1893 {ETH_RSS_L3_DST_ONLY |
1894 ETH_RSS_L4_SRC_ONLY,
1895 &hdrs_hint_ipv4_dst_tcp_src_gtpu_dwn,
1896 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_TCP},
1897 {ETH_RSS_L3_DST_ONLY |
1898 ETH_RSS_L4_DST_ONLY,
1899 &hdrs_hint_ipv4_dst_tcp_dst_gtpu_dwn,
1900 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_TCP},
1901 {ETH_RSS_L3_DST_ONLY,
1902 &hdrs_hint_ipv4_dst_gtpu_dwn,
1903 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_TCP},
1904 {ETH_RSS_L4_DST_ONLY,
1905 &hdrs_hint_ipv4_tcp_dst_gtpu_dwn,
1906 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_TCP},
1907 {ETH_RSS_NONFRAG_IPV4_TCP |
1908 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_SRC_ONLY,
1909 &hdrs_hint_ipv4_src_tcp_src_gtpu_dwn,
1910 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_TCP},
1911 {ETH_RSS_NONFRAG_IPV4_TCP |
1912 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_DST_ONLY,
1913 &hdrs_hint_ipv4_src_tcp_dst_gtpu_dwn,
1914 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_TCP},
1915 {ETH_RSS_NONFRAG_IPV4_TCP |
1916 ETH_RSS_L3_SRC_ONLY,
1917 &hdrs_hint_ipv4_src_gtpu_dwn,
1918 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_TCP},
1919 {ETH_RSS_NONFRAG_IPV4_TCP |
1920 ETH_RSS_L4_SRC_ONLY,
1921 &hdrs_hint_ipv4_tcp_src_gtpu_dwn,
1922 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_TCP},
1923 {ETH_RSS_NONFRAG_IPV4_TCP |
1924 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_SRC_ONLY,
1925 &hdrs_hint_ipv4_dst_tcp_src_gtpu_dwn,
1926 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_TCP},
1927 {ETH_RSS_NONFRAG_IPV4_TCP |
1928 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_DST_ONLY,
1929 &hdrs_hint_ipv4_dst_tcp_dst_gtpu_dwn,
1930 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_TCP},
1931 {ETH_RSS_NONFRAG_IPV4_TCP |
1932 ETH_RSS_L3_DST_ONLY,
1933 &hdrs_hint_ipv4_dst_gtpu_dwn,
1934 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_TCP},
1935 {ETH_RSS_NONFRAG_IPV4_TCP |
1936 ETH_RSS_L4_DST_ONLY,
1937 &hdrs_hint_ipv4_tcp_dst_gtpu_dwn,
1938 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_TCP},
1939 {ETH_RSS_NONFRAG_IPV4_TCP,
1940 &hdrs_hint_ipv4_tcp_gtpu_dwn,
1941 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_TCP},
1944 struct virtchnl_proto_hdrs *iavf_hash_default_hdrs[] = {
1946 &hdrs_hint_ipv4_udp,
1947 &hdrs_hint_ipv4_tcp,
1948 &hdrs_hint_ipv4_sctp,
1950 &hdrs_hint_ipv6_udp,
1951 &hdrs_hint_ipv6_tcp,
1952 &hdrs_hint_ipv6_sctp,
1955 static struct iavf_flow_engine iavf_hash_engine = {
1956 .init = iavf_hash_init,
1957 .create = iavf_hash_create,
1958 .destroy = iavf_hash_destroy,
1959 .uninit = iavf_hash_uninit,
1960 .free = iavf_hash_free,
1961 .type = IAVF_FLOW_ENGINE_HASH,
1964 /* Register parser for comms package. */
1965 static struct iavf_flow_parser iavf_hash_parser = {
1966 .engine = &iavf_hash_engine,
1967 .array = iavf_hash_pattern_list,
1968 .array_len = RTE_DIM(iavf_hash_pattern_list),
1969 .parse_pattern_action = iavf_hash_parse_pattern_action,
1970 .stage = IAVF_FLOW_STAGE_RSS,
1974 iavf_hash_default_set(struct iavf_adapter *ad, bool add)
1976 struct virtchnl_rss_cfg *rss_cfg;
1980 rss_cfg = rte_zmalloc("iavf rss rule",
1981 sizeof(struct virtchnl_rss_cfg), 0);
1985 for (i = 0; i < RTE_DIM(iavf_hash_default_hdrs); i++) {
1986 rss_cfg->proto_hdrs = *iavf_hash_default_hdrs[i];
1987 rss_cfg->rss_algorithm = VIRTCHNL_RSS_ALG_TOEPLITZ_ASYMMETRIC;
1989 ret = iavf_add_del_rss_cfg(ad, rss_cfg, add);
1991 PMD_DRV_LOG(ERR, "fail to %s RSS configure",
1992 add ? "add" : "delete");
2001 RTE_INIT(iavf_hash_engine_init)
2003 struct iavf_flow_engine *engine = &iavf_hash_engine;
2005 iavf_register_flow_engine(engine);
2009 iavf_hash_init(struct iavf_adapter *ad)
2011 struct iavf_info *vf = IAVF_DEV_PRIVATE_TO_VF(ad);
2012 struct iavf_flow_parser *parser;
2018 if (!(vf->vf_res->vf_cap_flags & VIRTCHNL_VF_OFFLOAD_ADV_RSS_PF))
2021 parser = &iavf_hash_parser;
2023 ret = iavf_register_parser(parser, ad);
2025 PMD_DRV_LOG(ERR, "fail to register hash parser");
2029 ret = iavf_hash_default_set(ad, true);
2031 PMD_DRV_LOG(ERR, "fail to set default RSS");
2032 iavf_unregister_parser(parser, ad);
2039 iavf_hash_parse_pattern(struct iavf_pattern_match_item *pattern_match_item,
2040 const struct rte_flow_item pattern[], uint64_t *phint,
2041 struct rte_flow_error *error)
2043 const struct rte_flow_item *item = pattern;
2044 const struct rte_flow_item_gtp_psc *psc;
2046 for (item = pattern; item->type != RTE_FLOW_ITEM_TYPE_END; item++) {
2048 rte_flow_error_set(error, EINVAL,
2049 RTE_FLOW_ERROR_TYPE_ITEM, item,
2050 "Not support range");
2054 switch (item->type) {
2055 case RTE_FLOW_ITEM_TYPE_GTP_PSC:
2058 *phint |= IAVF_PHINT_IPV4_GTPU_EH;
2059 else if (psc->pdu_type == IAVF_GTPU_EH_UPLINK)
2060 *phint |= IAVF_PHINT_IPV4_GTPU_EH_UPLINK;
2061 else if (psc->pdu_type == IAVF_GTPU_EH_DWNLINK)
2062 *phint |= IAVF_PHINT_IPV4_GTPU_EH_DWNLINK;
2069 /* update and restore pattern hint */
2070 *phint |= ((struct iavf_pattern_match_type *)
2071 (pattern_match_item->meta))->pattern_hint;
2077 iavf_hash_parse_action(const struct rte_flow_action actions[],
2078 uint64_t pattern_hint, void **meta,
2079 struct rte_flow_error *error)
2081 struct iavf_rss_meta *rss_meta = (struct iavf_rss_meta *)*meta;
2082 struct iavf_hash_match_type *hash_map_list;
2083 enum rte_flow_action_type action_type;
2084 const struct rte_flow_action_rss *rss;
2085 const struct rte_flow_action *action;
2087 bool item_found = false;
2091 /* Supported action is RSS. */
2092 for (action = actions; action->type !=
2093 RTE_FLOW_ACTION_TYPE_END; action++) {
2094 action_type = action->type;
2095 switch (action_type) {
2096 case RTE_FLOW_ACTION_TYPE_RSS:
2098 rss_type = rss->types;
2101 RTE_ETH_HASH_FUNCTION_SIMPLE_XOR){
2102 rss_meta->rss_algorithm =
2103 VIRTCHNL_RSS_ALG_XOR_ASYMMETRIC;
2104 } else if (rss->func ==
2105 RTE_ETH_HASH_FUNCTION_SYMMETRIC_TOEPLITZ) {
2106 rss_meta->rss_algorithm =
2107 VIRTCHNL_RSS_ALG_TOEPLITZ_SYMMETRIC;
2109 rss_meta->rss_algorithm =
2110 VIRTCHNL_RSS_ALG_TOEPLITZ_ASYMMETRIC;
2114 return rte_flow_error_set(error, ENOTSUP,
2115 RTE_FLOW_ERROR_TYPE_ACTION, action,
2116 "a nonzero RSS encapsulation level is not supported");
2119 return rte_flow_error_set(error, ENOTSUP,
2120 RTE_FLOW_ERROR_TYPE_ACTION, action,
2121 "a nonzero RSS key_len is not supported");
2124 return rte_flow_error_set(error, ENOTSUP,
2125 RTE_FLOW_ERROR_TYPE_ACTION, action,
2126 "a non-NULL RSS queue is not supported");
2129 * Check simultaneous use of SRC_ONLY and DST_ONLY
2130 * of the same level.
2132 rss_type = rte_eth_rss_hf_refine(rss_type);
2134 if ((pattern_hint & IAVF_PHINT_IPV4_GTPU_EH) ||
2135 (pattern_hint & IAVF_PHINT_IPV4_GTPU_EH_UPLINK) ||
2136 (pattern_hint & IAVF_PHINT_IPV4_GTPU_EH_DWNLINK)) {
2137 hash_map_list = iavf_gtpu_hash_map_list;
2138 mlist_len = RTE_DIM(iavf_gtpu_hash_map_list);
2140 hash_map_list = iavf_hash_map_list;
2141 mlist_len = RTE_DIM(iavf_hash_map_list);
2144 /* Find matched proto hdrs according to hash type. */
2145 for (i = 0; i < mlist_len; i++) {
2146 struct iavf_hash_match_type *ht_map =
2148 if (rss_type == ht_map->hash_type &&
2149 pattern_hint == ht_map->pattern_hint) {
2150 rss_meta->proto_hdrs =
2158 return rte_flow_error_set(error, ENOTSUP,
2159 RTE_FLOW_ERROR_TYPE_ACTION, action,
2160 "Not supported flow");
2163 case RTE_FLOW_ACTION_TYPE_END:
2167 rte_flow_error_set(error, EINVAL,
2168 RTE_FLOW_ERROR_TYPE_ACTION, action,
2178 iavf_hash_parse_pattern_action(__rte_unused struct iavf_adapter *ad,
2179 struct iavf_pattern_match_item *array,
2181 const struct rte_flow_item pattern[],
2182 const struct rte_flow_action actions[],
2184 struct rte_flow_error *error)
2186 struct iavf_pattern_match_item *pattern_match_item;
2187 struct iavf_rss_meta *rss_meta_ptr;
2188 uint64_t phint = IAVF_PHINT_NONE;
2191 rss_meta_ptr = rte_zmalloc(NULL, sizeof(*rss_meta_ptr), 0);
2192 if (!rss_meta_ptr) {
2193 rte_flow_error_set(error, EINVAL,
2194 RTE_FLOW_ERROR_TYPE_HANDLE, NULL,
2195 "No memory for rss_meta_ptr");
2199 /* Check rss supported pattern and find matched pattern. */
2200 pattern_match_item =
2201 iavf_search_pattern_match_item(pattern, array, array_len,
2203 if (!pattern_match_item) {
2208 ret = iavf_hash_parse_pattern(pattern_match_item, pattern, &phint,
2213 ret = iavf_hash_parse_action(actions, phint,
2214 (void **)&rss_meta_ptr, error);
2218 *meta = rss_meta_ptr;
2220 rte_free(rss_meta_ptr);
2222 rte_free(pattern_match_item);
2228 iavf_hash_create(__rte_unused struct iavf_adapter *ad,
2229 __rte_unused struct rte_flow *flow, void *meta,
2230 __rte_unused struct rte_flow_error *error)
2232 struct iavf_rss_meta *rss_meta = (struct iavf_rss_meta *)meta;
2233 struct virtchnl_rss_cfg *rss_cfg;
2236 rss_cfg = rte_zmalloc("iavf rss rule",
2237 sizeof(struct virtchnl_rss_cfg), 0);
2239 rte_flow_error_set(error, EINVAL,
2240 RTE_FLOW_ERROR_TYPE_HANDLE, NULL,
2241 "No memory for rss rule");
2245 rss_cfg->proto_hdrs = *rss_meta->proto_hdrs;
2246 rss_cfg->rss_algorithm = rss_meta->rss_algorithm;
2248 ret = iavf_add_del_rss_cfg(ad, rss_cfg, true);
2250 flow->rule = rss_cfg;
2252 PMD_DRV_LOG(ERR, "fail to add RSS configure");
2253 rte_flow_error_set(error, -ret,
2254 RTE_FLOW_ERROR_TYPE_HANDLE, NULL,
2255 "Failed to add rss rule.");
2266 iavf_hash_destroy(__rte_unused struct iavf_adapter *ad,
2267 struct rte_flow *flow,
2268 __rte_unused struct rte_flow_error *error)
2270 struct virtchnl_rss_cfg *rss_cfg;
2273 rss_cfg = (struct virtchnl_rss_cfg *)flow->rule;
2275 ret = iavf_add_del_rss_cfg(ad, rss_cfg, false);
2277 PMD_DRV_LOG(ERR, "fail to del RSS configure");
2278 rte_flow_error_set(error, -ret,
2279 RTE_FLOW_ERROR_TYPE_HANDLE, NULL,
2280 "Failed to delete rss rule.");
2287 iavf_hash_uninit(struct iavf_adapter *ad)
2289 if (iavf_hash_default_set(ad, false))
2290 PMD_DRV_LOG(ERR, "fail to delete default RSS");
2292 iavf_unregister_parser(&iavf_hash_parser, ad);
2296 iavf_hash_free(struct rte_flow *flow)
2298 rte_free(flow->rule);