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_udp_src_port { \
244 VIRTCHNL_PROTO_HDR_UDP, \
245 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_UDP_SRC_PORT), {BUFF_NOUSED } }
247 #define proto_hint_udp_dst_port { \
248 VIRTCHNL_PROTO_HDR_UDP, \
249 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_UDP_DST_PORT), {BUFF_NOUSED } }
251 #define proto_hint_udp_only { \
252 VIRTCHNL_PROTO_HDR_UDP, FIELD_FOR_PROTO_ONLY, {BUFF_NOUSED } }
254 #define proto_hint_udp { \
255 VIRTCHNL_PROTO_HDR_UDP, \
256 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_UDP_SRC_PORT) | \
257 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_UDP_DST_PORT), {BUFF_NOUSED } }
259 #define proto_hint_tcp_src_port { \
260 VIRTCHNL_PROTO_HDR_TCP, \
261 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_TCP_SRC_PORT), {BUFF_NOUSED } }
263 #define proto_hint_tcp_dst_port { \
264 VIRTCHNL_PROTO_HDR_TCP, \
265 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_TCP_DST_PORT), {BUFF_NOUSED } }
267 #define proto_hint_tcp_only { \
268 VIRTCHNL_PROTO_HDR_TCP, FIELD_FOR_PROTO_ONLY, {BUFF_NOUSED } }
270 #define proto_hint_tcp { \
271 VIRTCHNL_PROTO_HDR_TCP, \
272 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_TCP_SRC_PORT) | \
273 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_TCP_DST_PORT), {BUFF_NOUSED } }
275 #define proto_hint_sctp_src_port { \
276 VIRTCHNL_PROTO_HDR_SCTP, \
277 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_SCTP_SRC_PORT), {BUFF_NOUSED } }
279 #define proto_hint_sctp_dst_port { \
280 VIRTCHNL_PROTO_HDR_SCTP, \
281 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_SCTP_DST_PORT), {BUFF_NOUSED } }
283 #define proto_hint_sctp_only { \
284 VIRTCHNL_PROTO_HDR_SCTP, FIELD_FOR_PROTO_ONLY, {BUFF_NOUSED } }
286 #define proto_hint_sctp { \
287 VIRTCHNL_PROTO_HDR_SCTP, \
288 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_SCTP_SRC_PORT) | \
289 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_SCTP_DST_PORT), {BUFF_NOUSED } }
291 #define proto_hint_ipv6_src { \
292 VIRTCHNL_PROTO_HDR_IPV6, FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_IPV6_SRC), \
295 #define proto_hint_ipv6_dst { \
296 VIRTCHNL_PROTO_HDR_IPV6, FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_IPV6_DST), \
299 #define proto_hint_ipv6_only { \
300 VIRTCHNL_PROTO_HDR_IPV6, FIELD_FOR_PROTO_ONLY, {BUFF_NOUSED } }
302 #define proto_hint_ipv6 { \
303 VIRTCHNL_PROTO_HDR_IPV6, \
304 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_IPV6_SRC) | \
305 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_IPV6_DST), {BUFF_NOUSED } }
307 #define proto_hint_gtpu_eh_only { \
308 VIRTCHNL_PROTO_HDR_GTPU_EH, \
309 FIELD_FOR_PROTO_ONLY, {BUFF_NOUSED } }
311 #define proto_hint_gtpu_up_only { \
312 VIRTCHNL_PROTO_HDR_GTPU_EH_PDU_UP, \
313 FIELD_FOR_PROTO_ONLY, {BUFF_NOUSED } }
315 #define proto_hint_gtpu_dwn_only { \
316 VIRTCHNL_PROTO_HDR_GTPU_EH_PDU_DWN, \
317 FIELD_FOR_PROTO_ONLY, {BUFF_NOUSED } }
319 #define proto_hint_esp { \
320 VIRTCHNL_PROTO_HDR_ESP, \
321 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_ESP_SPI), {BUFF_NOUSED } }
323 #define proto_hint_ah { \
324 VIRTCHNL_PROTO_HDR_AH, \
325 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_AH_SPI), {BUFF_NOUSED } }
327 #define proto_hint_l2tpv3 { \
328 VIRTCHNL_PROTO_HDR_L2TPV3, \
329 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_L2TPV3_SESS_ID), {BUFF_NOUSED } }
331 #define proto_hint_pfcp { \
332 VIRTCHNL_PROTO_HDR_PFCP, \
333 FIELD_SELECTOR(VIRTCHNL_PROTO_HDR_PFCP_SEID), {BUFF_NOUSED } }
337 struct virtchnl_proto_hdrs hdrs_hint_eth_src_ipv4 = {
338 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_eth_src,
339 proto_hint_ipv4_only }
342 struct virtchnl_proto_hdrs hdrs_hint_eth_src_ipv4_udp = {
343 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_eth_src,
344 proto_hint_ipv4_only, proto_hint_udp_only }
347 struct virtchnl_proto_hdrs hdrs_hint_eth_src_ipv4_tcp = {
348 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_eth_src,
349 proto_hint_ipv4_only, proto_hint_tcp_only }
352 struct virtchnl_proto_hdrs hdrs_hint_eth_src_ipv4_sctp = {
353 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_eth_src,
354 proto_hint_ipv4_only, proto_hint_sctp_only }
357 struct virtchnl_proto_hdrs hdrs_hint_eth_dst_ipv4 = {
358 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_eth_dst,
359 proto_hint_ipv4_only }
362 struct virtchnl_proto_hdrs hdrs_hint_eth_dst_ipv4_udp = {
363 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_eth_dst,
364 proto_hint_ipv4_only, proto_hint_udp_only }
367 struct virtchnl_proto_hdrs hdrs_hint_eth_dst_ipv4_tcp = {
368 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_eth_dst,
369 proto_hint_ipv4_only, proto_hint_tcp_only }
372 struct virtchnl_proto_hdrs hdrs_hint_eth_dst_ipv4_sctp = {
373 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_eth_dst,
374 proto_hint_ipv4_only, proto_hint_sctp_only }
377 struct virtchnl_proto_hdrs hdrs_hint_eth_ipv4 = {
378 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_eth,
379 proto_hint_ipv4_only }
382 struct virtchnl_proto_hdrs hdrs_hint_eth_ipv4_udp = {
383 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_eth,
384 proto_hint_ipv4_only, proto_hint_udp_only }
387 struct virtchnl_proto_hdrs hdrs_hint_eth_ipv4_tcp = {
388 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_eth,
389 proto_hint_ipv4_only, proto_hint_tcp_only }
392 struct virtchnl_proto_hdrs hdrs_hint_eth_ipv4_sctp = {
393 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_eth,
394 proto_hint_ipv4_only, proto_hint_sctp_only }
397 struct virtchnl_proto_hdrs hdrs_hint_svlan_ipv4 = {
398 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_svlan,
399 proto_hint_ipv4_only}
402 struct virtchnl_proto_hdrs hdrs_hint_svlan_ipv4_udp = {
403 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_svlan,
404 proto_hint_ipv4_only, proto_hint_udp_only}
407 struct virtchnl_proto_hdrs hdrs_hint_svlan_ipv4_tcp = {
408 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_svlan,
409 proto_hint_ipv4_only, proto_hint_tcp_only}
412 struct virtchnl_proto_hdrs hdrs_hint_svlan_ipv4_sctp = {
413 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_svlan,
414 proto_hint_ipv4_only, proto_hint_sctp_only}
417 struct virtchnl_proto_hdrs hdrs_hint_cvlan_ipv4 = {
418 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_cvlan,
419 proto_hint_ipv4_only}
422 struct virtchnl_proto_hdrs hdrs_hint_cvlan_ipv4_udp = {
423 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_cvlan,
424 proto_hint_ipv4_only, proto_hint_udp_only}
427 struct virtchnl_proto_hdrs hdrs_hint_cvlan_ipv4_tcp = {
428 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_cvlan,
429 proto_hint_ipv4_only, proto_hint_tcp_only}
432 struct virtchnl_proto_hdrs hdrs_hint_cvlan_ipv4_sctp = {
433 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_cvlan,
434 proto_hint_ipv4_only, proto_hint_sctp_only}
437 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src = {
438 TUNNEL_LEVEL_OUTER, PROTO_COUNT_ONE, {proto_hint_ipv4_src }
441 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst = {
442 TUNNEL_LEVEL_OUTER, PROTO_COUNT_ONE, {proto_hint_ipv4_dst }
445 struct virtchnl_proto_hdrs hdrs_hint_ipv4 = {
446 TUNNEL_LEVEL_OUTER, PROTO_COUNT_ONE, {proto_hint_ipv4 }
449 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_udp_src_port = {
450 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_src,
451 proto_hint_udp_src_port }
454 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_udp_dst_port = {
455 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_src,
456 proto_hint_udp_dst_port }
459 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_udp_src_port = {
460 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_dst,
461 proto_hint_udp_src_port }
464 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_udp_dst_port = {
465 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_dst,
466 proto_hint_udp_dst_port }
469 struct virtchnl_proto_hdrs hdrs_hint_ipv4_udp_src_port = {
470 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_only,
471 proto_hint_udp_src_port }
474 struct virtchnl_proto_hdrs hdrs_hint_ipv4_udp_dst_port = {
475 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_only,
476 proto_hint_udp_dst_port }
479 struct virtchnl_proto_hdrs hdrs_hint_ipv4_udp = {
480 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4,
484 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_tcp_src_port = {
485 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_src,
486 proto_hint_tcp_src_port }
489 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_tcp_dst_port = {
490 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_src,
491 proto_hint_tcp_dst_port }
494 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_tcp_src_port = {
495 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_dst,
496 proto_hint_tcp_src_port }
499 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_tcp_dst_port = {
500 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_dst,
501 proto_hint_tcp_dst_port }
504 struct virtchnl_proto_hdrs hdrs_hint_ipv4_tcp_src_port = {
505 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_only,
506 proto_hint_tcp_src_port }
509 struct virtchnl_proto_hdrs hdrs_hint_ipv4_tcp_dst_port = {
510 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_only,
511 proto_hint_tcp_dst_port }
514 struct virtchnl_proto_hdrs hdrs_hint_ipv4_tcp = {
515 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4,
519 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_sctp_src_port = {
520 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_src,
521 proto_hint_sctp_src_port }
524 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_sctp_dst_port = {
525 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_src,
526 proto_hint_sctp_dst_port }
529 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_sctp_src_port = {
530 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_dst,
531 proto_hint_sctp_src_port }
534 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_sctp_dst_port = {
535 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_dst,
536 proto_hint_sctp_dst_port }
539 struct virtchnl_proto_hdrs hdrs_hint_ipv4_sctp_src_port = {
540 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_only,
541 proto_hint_sctp_src_port }
544 struct virtchnl_proto_hdrs hdrs_hint_ipv4_sctp_dst_port = {
545 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_only,
546 proto_hint_sctp_dst_port }
549 struct virtchnl_proto_hdrs hdrs_hint_ipv4_sctp = {
550 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4,
554 struct virtchnl_proto_hdrs hdrs_hint_ipv4_esp = {
555 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_only,
559 struct virtchnl_proto_hdrs hdrs_hint_ipv4_ah = {
560 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_only,
564 struct virtchnl_proto_hdrs hdrs_hint_ipv4_l2tpv3 = {
565 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_only,
569 struct virtchnl_proto_hdrs hdrs_hint_ipv4_pfcp = {
570 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv4_only,
574 struct virtchnl_proto_hdrs hdrs_hint_ipv4_udp_esp = {
575 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_ipv4_only,
576 proto_hint_udp_only, proto_hint_esp }
581 struct virtchnl_proto_hdrs hdrs_hint_ipv4_udp_src_gtpu_eh = {
582 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_eh_only,
583 proto_hint_udp_src_port}
586 struct virtchnl_proto_hdrs hdrs_hint_ipv4_udp_dst_gtpu_eh = {
587 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_eh_only,
588 proto_hint_udp_dst_port}
591 struct virtchnl_proto_hdrs hdrs_hint_ipv4_tcp_src_gtpu_eh = {
592 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_eh_only,
593 proto_hint_tcp_src_port}
596 struct virtchnl_proto_hdrs hdrs_hint_ipv4_tcp_dst_gtpu_eh = {
597 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_eh_only,
598 proto_hint_tcp_dst_port}
601 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_gtpu_eh = {
602 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_eh_only,
603 proto_hint_ipv4_src }
606 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_udp_src_gtpu_eh = {
607 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_eh_only,
608 proto_hint_udp_src_port}
611 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_udp_dst_gtpu_eh = {
612 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_eh_only,
613 proto_hint_udp_dst_port}
616 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_tcp_src_gtpu_eh = {
617 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_eh_only,
618 proto_hint_tcp_src_port}
621 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_tcp_dst_gtpu_eh = {
622 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_eh_only,
623 proto_hint_tcp_dst_port}
626 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_gtpu_eh = {
627 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_eh_only,
628 proto_hint_ipv4_dst }
631 struct virtchnl_proto_hdrs hdrs_hint_ipv4_gtpu_eh = {
632 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_eh_only,
636 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_udp_src_gtpu_eh = {
637 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_eh_only,
638 proto_hint_udp_src_port}
641 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_udp_dst_gtpu_eh = {
642 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_eh_only,
643 proto_hint_udp_dst_port}
646 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_tcp_src_gtpu_eh = {
647 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_eh_only,
648 proto_hint_tcp_src_port}
651 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_tcp_dst_gtpu_eh = {
652 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_eh_only,
653 proto_hint_tcp_dst_port}
656 struct virtchnl_proto_hdrs hdrs_hint_ipv4_udp_gtpu_eh = {
657 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_eh_only,
661 struct virtchnl_proto_hdrs hdrs_hint_ipv4_tcp_gtpu_eh = {
662 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_eh_only,
668 struct virtchnl_proto_hdrs hdrs_hint_ipv4_udp_src_gtpu_up = {
669 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_up_only,
670 proto_hint_udp_src_port}
673 struct virtchnl_proto_hdrs hdrs_hint_ipv4_udp_dst_gtpu_up = {
674 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_up_only,
675 proto_hint_udp_dst_port}
678 struct virtchnl_proto_hdrs hdrs_hint_ipv4_tcp_src_gtpu_up = {
679 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_up_only,
680 proto_hint_tcp_src_port}
683 struct virtchnl_proto_hdrs hdrs_hint_ipv4_tcp_dst_gtpu_up = {
684 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_up_only,
685 proto_hint_tcp_dst_port}
688 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_gtpu_up = {
689 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_up_only,
690 proto_hint_ipv4_src }
693 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_udp_src_gtpu_up = {
694 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_up_only,
695 proto_hint_udp_src_port}
698 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_udp_dst_gtpu_up = {
699 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_up_only,
700 proto_hint_udp_dst_port}
703 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_tcp_src_gtpu_up = {
704 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_up_only,
705 proto_hint_tcp_src_port}
708 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_tcp_dst_gtpu_up = {
709 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_up_only,
710 proto_hint_tcp_dst_port}
713 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_gtpu_up = {
714 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_up_only,
715 proto_hint_ipv4_dst }
718 struct virtchnl_proto_hdrs hdrs_hint_ipv4_gtpu_up = {
719 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_up_only,
723 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_udp_src_gtpu_up = {
724 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_up_only,
725 proto_hint_udp_src_port}
728 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_udp_dst_gtpu_up = {
729 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_up_only,
730 proto_hint_udp_dst_port}
733 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_tcp_src_gtpu_up = {
734 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_up_only,
735 proto_hint_tcp_src_port}
738 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_tcp_dst_gtpu_up = {
739 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_up_only,
740 proto_hint_tcp_dst_port}
743 struct virtchnl_proto_hdrs hdrs_hint_ipv4_udp_gtpu_up = {
744 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_up_only,
748 struct virtchnl_proto_hdrs hdrs_hint_ipv4_tcp_gtpu_up = {
749 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_up_only,
755 struct virtchnl_proto_hdrs hdrs_hint_ipv4_udp_src_gtpu_dwn = {
756 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_dwn_only,
757 proto_hint_udp_src_port}
760 struct virtchnl_proto_hdrs hdrs_hint_ipv4_udp_dst_gtpu_dwn = {
761 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_dwn_only,
762 proto_hint_udp_dst_port}
765 struct virtchnl_proto_hdrs hdrs_hint_ipv4_tcp_src_gtpu_dwn = {
766 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_dwn_only,
767 proto_hint_tcp_src_port}
770 struct virtchnl_proto_hdrs hdrs_hint_ipv4_tcp_dst_gtpu_dwn = {
771 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_dwn_only,
772 proto_hint_tcp_dst_port}
775 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_gtpu_dwn = {
776 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_dwn_only,
777 proto_hint_ipv4_src }
780 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_udp_src_gtpu_dwn = {
781 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_dwn_only,
782 proto_hint_udp_src_port}
785 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_udp_dst_gtpu_dwn = {
786 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_dwn_only,
787 proto_hint_udp_dst_port}
790 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_tcp_src_gtpu_dwn = {
791 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_dwn_only,
792 proto_hint_tcp_src_port}
795 struct virtchnl_proto_hdrs hdrs_hint_ipv4_src_tcp_dst_gtpu_dwn = {
796 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_dwn_only,
797 proto_hint_tcp_dst_port}
800 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_gtpu_dwn = {
801 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_dwn_only,
802 proto_hint_ipv4_dst }
805 struct virtchnl_proto_hdrs hdrs_hint_ipv4_gtpu_dwn = {
806 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_dwn_only,
810 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_udp_src_gtpu_dwn = {
811 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_dwn_only,
812 proto_hint_udp_src_port}
815 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_udp_dst_gtpu_dwn = {
816 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_dwn_only,
817 proto_hint_udp_dst_port}
820 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_tcp_src_gtpu_dwn = {
821 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_dwn_only,
822 proto_hint_tcp_src_port}
825 struct virtchnl_proto_hdrs hdrs_hint_ipv4_dst_tcp_dst_gtpu_dwn = {
826 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_dwn_only,
827 proto_hint_tcp_dst_port}
830 struct virtchnl_proto_hdrs hdrs_hint_ipv4_udp_gtpu_dwn = {
831 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_dwn_only,
835 struct virtchnl_proto_hdrs hdrs_hint_ipv4_tcp_gtpu_dwn = {
836 TUNNEL_LEVEL_FIRST_INNER, PROTO_COUNT_TWO, {proto_hint_gtpu_dwn_only,
842 struct virtchnl_proto_hdrs hdrs_hint_eth_src_ipv6 = {
843 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_eth_src,
844 proto_hint_ipv6_only }
847 struct virtchnl_proto_hdrs hdrs_hint_eth_src_ipv6_udp = {
848 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_eth_src,
849 proto_hint_ipv6_only, proto_hint_udp_only }
852 struct virtchnl_proto_hdrs hdrs_hint_eth_src_ipv6_tcp = {
853 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_eth_src,
854 proto_hint_ipv6_only, proto_hint_tcp_only }
857 struct virtchnl_proto_hdrs hdrs_hint_eth_src_ipv6_sctp = {
858 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_eth_src,
859 proto_hint_ipv6_only, proto_hint_sctp_only }
862 struct virtchnl_proto_hdrs hdrs_hint_eth_dst_ipv6 = {
863 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_eth_dst,
864 proto_hint_ipv6_only }
867 struct virtchnl_proto_hdrs hdrs_hint_eth_dst_ipv6_udp = {
868 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_eth_dst,
869 proto_hint_ipv6_only, proto_hint_udp_only }
872 struct virtchnl_proto_hdrs hdrs_hint_eth_dst_ipv6_tcp = {
873 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_eth_dst,
874 proto_hint_ipv6_only, proto_hint_tcp_only }
877 struct virtchnl_proto_hdrs hdrs_hint_eth_dst_ipv6_sctp = {
878 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_eth_dst,
879 proto_hint_ipv6_only, proto_hint_sctp_only }
882 struct virtchnl_proto_hdrs hdrs_hint_eth_ipv6 = {
883 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_eth,
884 proto_hint_ipv6_only }
887 struct virtchnl_proto_hdrs hdrs_hint_eth_ipv6_udp = {
888 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_eth,
889 proto_hint_ipv6_only, proto_hint_udp_only }
892 struct virtchnl_proto_hdrs hdrs_hint_eth_ipv6_tcp = {
893 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_eth,
894 proto_hint_ipv6_only, proto_hint_tcp_only }
897 struct virtchnl_proto_hdrs hdrs_hint_eth_ipv6_sctp = {
898 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_eth,
899 proto_hint_ipv6_only, proto_hint_sctp_only }
902 struct virtchnl_proto_hdrs hdrs_hint_svlan_ipv6 = {
903 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_svlan,
904 proto_hint_ipv6_only}
907 struct virtchnl_proto_hdrs hdrs_hint_svlan_ipv6_udp = {
908 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_svlan,
909 proto_hint_ipv6_only, proto_hint_udp_only}
912 struct virtchnl_proto_hdrs hdrs_hint_svlan_ipv6_tcp = {
913 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_svlan,
914 proto_hint_ipv6_only, proto_hint_tcp_only}
917 struct virtchnl_proto_hdrs hdrs_hint_svlan_ipv6_sctp = {
918 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_svlan,
919 proto_hint_ipv6_only, proto_hint_sctp_only}
922 struct virtchnl_proto_hdrs hdrs_hint_cvlan_ipv6 = {
923 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_cvlan,
924 proto_hint_ipv6_only}
927 struct virtchnl_proto_hdrs hdrs_hint_cvlan_ipv6_udp = {
928 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_cvlan,
929 proto_hint_ipv6_only, proto_hint_udp_only}
932 struct virtchnl_proto_hdrs hdrs_hint_cvlan_ipv6_tcp = {
933 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_cvlan,
934 proto_hint_ipv6_only, proto_hint_tcp_only}
937 struct virtchnl_proto_hdrs hdrs_hint_cvlan_ipv6_sctp = {
938 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_cvlan,
939 proto_hint_ipv6_only, proto_hint_sctp_only}
942 struct virtchnl_proto_hdrs hdrs_hint_ipv6_src = {
943 TUNNEL_LEVEL_OUTER, PROTO_COUNT_ONE, {proto_hint_ipv6_src }
946 struct virtchnl_proto_hdrs hdrs_hint_ipv6_dst = {
947 TUNNEL_LEVEL_OUTER, PROTO_COUNT_ONE, {proto_hint_ipv6_dst }
950 struct virtchnl_proto_hdrs hdrs_hint_ipv6 = {
951 TUNNEL_LEVEL_OUTER, PROTO_COUNT_ONE, {proto_hint_ipv6 }
954 struct virtchnl_proto_hdrs hdrs_hint_ipv6_src_udp_src_port = {
955 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_src,
956 proto_hint_udp_src_port }
959 struct virtchnl_proto_hdrs hdrs_hint_ipv6_src_udp_dst_port = {
960 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_src,
961 proto_hint_udp_dst_port }
964 struct virtchnl_proto_hdrs hdrs_hint_ipv6_dst_udp_src_port = {
965 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_dst,
966 proto_hint_udp_src_port }
969 struct virtchnl_proto_hdrs hdrs_hint_ipv6_dst_udp_dst_port = {
970 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_dst,
971 proto_hint_udp_dst_port }
974 struct virtchnl_proto_hdrs hdrs_hint_ipv6_udp_src_port = {
975 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_only,
976 proto_hint_udp_src_port }
979 struct virtchnl_proto_hdrs hdrs_hint_ipv6_udp_dst_port = {
980 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_only,
981 proto_hint_udp_dst_port }
984 struct virtchnl_proto_hdrs hdrs_hint_ipv6_udp = {
985 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6,
989 struct virtchnl_proto_hdrs hdrs_hint_ipv6_src_tcp_src_port = {
990 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_src,
991 proto_hint_tcp_src_port }
994 struct virtchnl_proto_hdrs hdrs_hint_ipv6_src_tcp_dst_port = {
995 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_src,
996 proto_hint_tcp_dst_port }
999 struct virtchnl_proto_hdrs hdrs_hint_ipv6_dst_tcp_src_port = {
1000 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_dst,
1001 proto_hint_tcp_src_port }
1004 struct virtchnl_proto_hdrs hdrs_hint_ipv6_dst_tcp_dst_port = {
1005 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_dst,
1006 proto_hint_tcp_dst_port }
1009 struct virtchnl_proto_hdrs hdrs_hint_ipv6_tcp_src_port = {
1010 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_only,
1011 proto_hint_tcp_src_port }
1014 struct virtchnl_proto_hdrs hdrs_hint_ipv6_tcp_dst_port = {
1015 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_only,
1016 proto_hint_tcp_dst_port }
1019 struct virtchnl_proto_hdrs hdrs_hint_ipv6_tcp = {
1020 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6,
1024 struct virtchnl_proto_hdrs hdrs_hint_ipv6_src_sctp_src_port = {
1025 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_src,
1026 proto_hint_sctp_src_port }
1029 struct virtchnl_proto_hdrs hdrs_hint_ipv6_src_sctp_dst_port = {
1030 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_src,
1031 proto_hint_sctp_dst_port }
1034 struct virtchnl_proto_hdrs hdrs_hint_ipv6_dst_sctp_src_port = {
1035 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_dst,
1036 proto_hint_sctp_src_port }
1039 struct virtchnl_proto_hdrs hdrs_hint_ipv6_dst_sctp_dst_port = {
1040 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_dst,
1041 proto_hint_sctp_dst_port }
1044 struct virtchnl_proto_hdrs hdrs_hint_ipv6_sctp_src_port = {
1045 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_only,
1046 proto_hint_sctp_src_port }
1049 struct virtchnl_proto_hdrs hdrs_hint_ipv6_sctp_dst_port = {
1050 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_only,
1051 proto_hint_sctp_dst_port }
1054 struct virtchnl_proto_hdrs hdrs_hint_ipv6_sctp = {
1055 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6,
1059 struct virtchnl_proto_hdrs hdrs_hint_ipv6_esp = {
1060 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_only,
1064 struct virtchnl_proto_hdrs hdrs_hint_ipv6_ah = {
1065 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_only,
1069 struct virtchnl_proto_hdrs hdrs_hint_ipv6_l2tpv3 = {
1070 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_only,
1074 struct virtchnl_proto_hdrs hdrs_hint_ipv6_pfcp = {
1075 TUNNEL_LEVEL_OUTER, PROTO_COUNT_TWO, {proto_hint_ipv6_only,
1079 struct virtchnl_proto_hdrs hdrs_hint_ipv6_udp_esp = {
1080 TUNNEL_LEVEL_OUTER, PROTO_COUNT_THREE, {proto_hint_ipv6_only,
1081 proto_hint_udp_only, proto_hint_esp }
1084 struct iavf_hash_match_type iavf_hash_map_list[] = {
1086 {ETH_RSS_L2_SRC_ONLY,
1087 &hdrs_hint_eth_src_ipv4, IAVF_PHINT_IPV4},
1088 {ETH_RSS_L2_DST_ONLY,
1089 &hdrs_hint_eth_dst_ipv4, IAVF_PHINT_IPV4},
1091 &hdrs_hint_eth_ipv4, IAVF_PHINT_IPV4},
1092 {ETH_RSS_L3_SRC_ONLY,
1093 &hdrs_hint_ipv4_src, IAVF_PHINT_IPV4},
1094 {ETH_RSS_L3_DST_ONLY,
1095 &hdrs_hint_ipv4_dst, IAVF_PHINT_IPV4},
1096 {ETH_RSS_IPV4 | ETH_RSS_L3_SRC_ONLY,
1097 &hdrs_hint_ipv4_src, IAVF_PHINT_IPV4},
1098 {ETH_RSS_IPV4 | ETH_RSS_L3_DST_ONLY,
1099 &hdrs_hint_ipv4_dst, IAVF_PHINT_IPV4},
1101 &hdrs_hint_ipv4, IAVF_PHINT_IPV4},
1103 &hdrs_hint_ipv4_esp, IAVF_PHINT_IPV4},
1105 &hdrs_hint_ipv4_ah, IAVF_PHINT_IPV4},
1107 &hdrs_hint_ipv4_l2tpv3, IAVF_PHINT_IPV4},
1109 &hdrs_hint_svlan_ipv4, IAVF_PHINT_IPV4},
1111 &hdrs_hint_svlan_ipv4_udp, IAVF_PHINT_IPV4_UDP},
1113 &hdrs_hint_svlan_ipv4_tcp, IAVF_PHINT_IPV4_TCP},
1115 &hdrs_hint_svlan_ipv4_sctp, IAVF_PHINT_IPV4_SCTP},
1117 &hdrs_hint_cvlan_ipv4, IAVF_PHINT_IPV4},
1119 &hdrs_hint_cvlan_ipv4_udp, IAVF_PHINT_IPV4_UDP},
1121 &hdrs_hint_cvlan_ipv4_tcp, IAVF_PHINT_IPV4_TCP},
1123 &hdrs_hint_cvlan_ipv4_sctp, IAVF_PHINT_IPV4_SCTP},
1125 {ETH_RSS_L2_SRC_ONLY,
1126 &hdrs_hint_eth_src_ipv4_udp, IAVF_PHINT_IPV4_UDP},
1127 {ETH_RSS_L2_DST_ONLY,
1128 &hdrs_hint_eth_dst_ipv4_udp, IAVF_PHINT_IPV4_UDP},
1130 &hdrs_hint_eth_ipv4_udp, IAVF_PHINT_IPV4_UDP},
1131 {ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_SRC_ONLY,
1132 &hdrs_hint_ipv4_src_udp_src_port, IAVF_PHINT_IPV4_UDP},
1133 {ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_DST_ONLY,
1134 &hdrs_hint_ipv4_src_udp_dst_port, IAVF_PHINT_IPV4_UDP},
1135 {ETH_RSS_L3_SRC_ONLY,
1136 &hdrs_hint_ipv4_src, IAVF_PHINT_IPV4_UDP},
1137 {ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_SRC_ONLY,
1138 &hdrs_hint_ipv4_dst_udp_src_port, IAVF_PHINT_IPV4_UDP},
1139 {ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_DST_ONLY,
1140 &hdrs_hint_ipv4_dst_udp_dst_port, IAVF_PHINT_IPV4_UDP},
1141 {ETH_RSS_L3_DST_ONLY,
1142 &hdrs_hint_ipv4_dst, IAVF_PHINT_IPV4_UDP},
1143 {ETH_RSS_NONFRAG_IPV4_UDP |
1144 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_SRC_ONLY,
1145 &hdrs_hint_ipv4_src_udp_src_port, IAVF_PHINT_IPV4_UDP},
1146 {ETH_RSS_NONFRAG_IPV4_UDP |
1147 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_DST_ONLY,
1148 &hdrs_hint_ipv4_src_udp_dst_port, IAVF_PHINT_IPV4_UDP},
1149 {ETH_RSS_NONFRAG_IPV4_UDP |
1150 ETH_RSS_L3_SRC_ONLY, &hdrs_hint_ipv4_src,
1151 IAVF_PHINT_IPV4_UDP},
1152 {ETH_RSS_NONFRAG_IPV4_UDP |
1153 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_SRC_ONLY,
1154 &hdrs_hint_ipv4_dst_udp_src_port, IAVF_PHINT_IPV4_UDP},
1155 {ETH_RSS_NONFRAG_IPV4_UDP |
1156 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_DST_ONLY,
1157 &hdrs_hint_ipv4_dst_udp_dst_port, IAVF_PHINT_IPV4_UDP},
1158 {ETH_RSS_NONFRAG_IPV4_UDP |
1159 ETH_RSS_L3_DST_ONLY, &hdrs_hint_ipv4_dst,
1160 IAVF_PHINT_IPV4_UDP},
1161 {ETH_RSS_L4_SRC_ONLY,
1162 &hdrs_hint_ipv4_udp_src_port, IAVF_PHINT_IPV4_UDP},
1163 {ETH_RSS_L4_DST_ONLY,
1164 &hdrs_hint_ipv4_udp_dst_port, IAVF_PHINT_IPV4_UDP},
1165 {ETH_RSS_NONFRAG_IPV4_UDP | ETH_RSS_L4_SRC_ONLY,
1166 &hdrs_hint_ipv4_udp_src_port, IAVF_PHINT_IPV4_UDP},
1167 {ETH_RSS_NONFRAG_IPV4_UDP | ETH_RSS_L4_DST_ONLY,
1168 &hdrs_hint_ipv4_udp_dst_port, IAVF_PHINT_IPV4_UDP},
1170 &hdrs_hint_ipv4_pfcp, IAVF_PHINT_IPV4_UDP},
1172 &hdrs_hint_ipv4_udp_esp, IAVF_PHINT_IPV4_UDP},
1173 {ETH_RSS_NONFRAG_IPV4_UDP,
1174 &hdrs_hint_ipv4_udp, IAVF_PHINT_IPV4_UDP},
1176 {ETH_RSS_L2_SRC_ONLY,
1177 &hdrs_hint_eth_src_ipv4_tcp, IAVF_PHINT_IPV4_TCP},
1178 {ETH_RSS_L2_DST_ONLY,
1179 &hdrs_hint_eth_dst_ipv4_tcp, IAVF_PHINT_IPV4_TCP},
1181 &hdrs_hint_eth_ipv4_tcp, IAVF_PHINT_IPV4_TCP},
1182 {ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_SRC_ONLY,
1183 &hdrs_hint_ipv4_src_tcp_src_port, IAVF_PHINT_IPV4_TCP},
1184 {ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_DST_ONLY,
1185 &hdrs_hint_ipv4_src_tcp_dst_port, IAVF_PHINT_IPV4_TCP},
1186 {ETH_RSS_L3_SRC_ONLY,
1187 &hdrs_hint_ipv4_src, IAVF_PHINT_IPV4_TCP},
1188 {ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_SRC_ONLY,
1189 &hdrs_hint_ipv4_dst_tcp_src_port, IAVF_PHINT_IPV4_TCP},
1190 {ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_DST_ONLY,
1191 &hdrs_hint_ipv4_dst_tcp_dst_port, IAVF_PHINT_IPV4_TCP},
1192 {ETH_RSS_L3_DST_ONLY,
1193 &hdrs_hint_ipv4_dst, IAVF_PHINT_IPV4_TCP},
1194 {ETH_RSS_NONFRAG_IPV4_TCP |
1195 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_SRC_ONLY,
1196 &hdrs_hint_ipv4_src_tcp_src_port, IAVF_PHINT_IPV4_TCP},
1197 {ETH_RSS_NONFRAG_IPV4_TCP |
1198 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_DST_ONLY,
1199 &hdrs_hint_ipv4_src_tcp_dst_port, IAVF_PHINT_IPV4_TCP},
1200 {ETH_RSS_NONFRAG_IPV4_TCP |
1201 ETH_RSS_L3_SRC_ONLY, &hdrs_hint_ipv4_src,
1202 IAVF_PHINT_IPV4_TCP},
1203 {ETH_RSS_NONFRAG_IPV4_TCP |
1204 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_SRC_ONLY,
1205 &hdrs_hint_ipv4_dst_tcp_src_port, IAVF_PHINT_IPV4_TCP},
1206 {ETH_RSS_NONFRAG_IPV4_TCP |
1207 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_DST_ONLY,
1208 &hdrs_hint_ipv4_dst_tcp_dst_port, IAVF_PHINT_IPV4_TCP},
1209 {ETH_RSS_NONFRAG_IPV4_TCP |
1210 ETH_RSS_L3_DST_ONLY, &hdrs_hint_ipv4_dst,
1211 IAVF_PHINT_IPV4_TCP},
1212 {ETH_RSS_L4_SRC_ONLY,
1213 &hdrs_hint_ipv4_tcp_src_port, IAVF_PHINT_IPV4_TCP},
1214 {ETH_RSS_L4_DST_ONLY,
1215 &hdrs_hint_ipv4_tcp_dst_port, IAVF_PHINT_IPV4_TCP},
1216 {ETH_RSS_NONFRAG_IPV4_TCP | ETH_RSS_L4_SRC_ONLY,
1217 &hdrs_hint_ipv4_tcp_src_port, IAVF_PHINT_IPV4_TCP},
1218 {ETH_RSS_NONFRAG_IPV4_TCP | ETH_RSS_L4_DST_ONLY,
1219 &hdrs_hint_ipv4_tcp_dst_port, IAVF_PHINT_IPV4_TCP},
1220 {ETH_RSS_NONFRAG_IPV4_TCP,
1221 &hdrs_hint_ipv4_tcp, IAVF_PHINT_IPV4_TCP},
1223 {ETH_RSS_L2_SRC_ONLY,
1224 &hdrs_hint_eth_src_ipv4_sctp, IAVF_PHINT_IPV4_SCTP},
1225 {ETH_RSS_L2_DST_ONLY,
1226 &hdrs_hint_eth_dst_ipv4_sctp, IAVF_PHINT_IPV4_SCTP},
1228 &hdrs_hint_eth_ipv4_sctp, IAVF_PHINT_IPV4_SCTP},
1229 {ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_SRC_ONLY,
1230 &hdrs_hint_ipv4_src_sctp_src_port, IAVF_PHINT_IPV4_SCTP},
1231 {ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_DST_ONLY,
1232 &hdrs_hint_ipv4_src_sctp_dst_port, IAVF_PHINT_IPV4_SCTP},
1233 {ETH_RSS_L3_SRC_ONLY,
1234 &hdrs_hint_ipv4_src, IAVF_PHINT_IPV4_SCTP},
1235 {ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_SRC_ONLY,
1236 &hdrs_hint_ipv4_dst_sctp_src_port, IAVF_PHINT_IPV4_SCTP},
1237 {ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_DST_ONLY,
1238 &hdrs_hint_ipv4_dst_sctp_dst_port, IAVF_PHINT_IPV4_SCTP},
1239 {ETH_RSS_L3_DST_ONLY,
1240 &hdrs_hint_ipv4_dst, IAVF_PHINT_IPV4_SCTP},
1241 {ETH_RSS_NONFRAG_IPV4_SCTP |
1242 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_SRC_ONLY,
1243 &hdrs_hint_ipv4_src_sctp_src_port, IAVF_PHINT_IPV4_SCTP},
1244 {ETH_RSS_NONFRAG_IPV4_SCTP |
1245 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_DST_ONLY,
1246 &hdrs_hint_ipv4_src_sctp_dst_port, IAVF_PHINT_IPV4_SCTP},
1247 {ETH_RSS_NONFRAG_IPV4_SCTP |
1248 ETH_RSS_L3_SRC_ONLY, &hdrs_hint_ipv4_src,
1249 IAVF_PHINT_IPV4_SCTP},
1250 {ETH_RSS_NONFRAG_IPV4_SCTP |
1251 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_SRC_ONLY,
1252 &hdrs_hint_ipv4_dst_sctp_src_port, IAVF_PHINT_IPV4_SCTP},
1253 {ETH_RSS_NONFRAG_IPV4_SCTP |
1254 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_DST_ONLY,
1255 &hdrs_hint_ipv4_dst_sctp_dst_port, IAVF_PHINT_IPV4_SCTP},
1256 {ETH_RSS_NONFRAG_IPV4_SCTP |
1257 ETH_RSS_L3_DST_ONLY, &hdrs_hint_ipv4_dst,
1258 IAVF_PHINT_IPV4_SCTP},
1259 {ETH_RSS_L4_SRC_ONLY,
1260 &hdrs_hint_ipv4_sctp_src_port, IAVF_PHINT_IPV4_SCTP},
1261 {ETH_RSS_L4_DST_ONLY,
1262 &hdrs_hint_ipv4_sctp_dst_port, IAVF_PHINT_IPV4_SCTP},
1263 {ETH_RSS_NONFRAG_IPV4_SCTP | ETH_RSS_L4_SRC_ONLY,
1264 &hdrs_hint_ipv4_sctp_src_port, IAVF_PHINT_IPV4_SCTP},
1265 {ETH_RSS_NONFRAG_IPV4_SCTP | ETH_RSS_L4_DST_ONLY,
1266 &hdrs_hint_ipv4_sctp_dst_port, IAVF_PHINT_IPV4_SCTP},
1267 {ETH_RSS_NONFRAG_IPV4_SCTP,
1268 &hdrs_hint_ipv4_sctp, IAVF_PHINT_IPV4_SCTP},
1270 {ETH_RSS_L2_SRC_ONLY,
1271 &hdrs_hint_eth_src_ipv6, IAVF_PHINT_IPV6},
1272 {ETH_RSS_L2_DST_ONLY,
1273 &hdrs_hint_eth_dst_ipv6, IAVF_PHINT_IPV6},
1275 &hdrs_hint_eth_ipv6, IAVF_PHINT_IPV6},
1276 {ETH_RSS_L3_SRC_ONLY,
1277 &hdrs_hint_ipv6_src, IAVF_PHINT_IPV6},
1278 {ETH_RSS_L3_DST_ONLY,
1279 &hdrs_hint_ipv6_dst, IAVF_PHINT_IPV6},
1280 {ETH_RSS_IPV6 | ETH_RSS_L3_SRC_ONLY,
1281 &hdrs_hint_ipv6_src, IAVF_PHINT_IPV6},
1282 {ETH_RSS_IPV6 | ETH_RSS_L3_DST_ONLY,
1283 &hdrs_hint_ipv6_dst, IAVF_PHINT_IPV6},
1285 &hdrs_hint_ipv6, IAVF_PHINT_IPV6},
1287 &hdrs_hint_ipv6_esp, IAVF_PHINT_IPV6},
1289 &hdrs_hint_ipv6_ah, IAVF_PHINT_IPV6},
1291 &hdrs_hint_ipv6_l2tpv3, IAVF_PHINT_IPV6},
1293 {ETH_RSS_L2_SRC_ONLY,
1294 &hdrs_hint_eth_src_ipv6_udp, IAVF_PHINT_IPV6_UDP},
1295 {ETH_RSS_L2_DST_ONLY,
1296 &hdrs_hint_eth_dst_ipv6_udp, IAVF_PHINT_IPV6_UDP},
1298 &hdrs_hint_eth_ipv6_udp, IAVF_PHINT_IPV6_UDP},
1299 {ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_SRC_ONLY,
1300 &hdrs_hint_ipv6_src_udp_src_port, IAVF_PHINT_IPV6_UDP},
1301 {ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_DST_ONLY,
1302 &hdrs_hint_ipv6_src_udp_dst_port, IAVF_PHINT_IPV6_UDP},
1303 {ETH_RSS_L3_SRC_ONLY,
1304 &hdrs_hint_ipv6_src, IAVF_PHINT_IPV6_UDP},
1305 {ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_SRC_ONLY,
1306 &hdrs_hint_ipv6_dst_udp_src_port, IAVF_PHINT_IPV6_UDP},
1307 {ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_DST_ONLY,
1308 &hdrs_hint_ipv6_dst_udp_dst_port, IAVF_PHINT_IPV6_UDP},
1309 {ETH_RSS_L3_DST_ONLY,
1310 &hdrs_hint_ipv6_dst, IAVF_PHINT_IPV6_UDP},
1311 {ETH_RSS_NONFRAG_IPV6_UDP |
1312 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_SRC_ONLY,
1313 &hdrs_hint_ipv6_src_udp_src_port, IAVF_PHINT_IPV6_UDP},
1314 {ETH_RSS_NONFRAG_IPV6_UDP |
1315 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_DST_ONLY,
1316 &hdrs_hint_ipv6_src_udp_dst_port, IAVF_PHINT_IPV6_UDP},
1317 {ETH_RSS_NONFRAG_IPV6_UDP |
1318 ETH_RSS_L3_SRC_ONLY, &hdrs_hint_ipv6_src,
1319 IAVF_PHINT_IPV6_UDP},
1320 {ETH_RSS_NONFRAG_IPV6_UDP |
1321 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_SRC_ONLY,
1322 &hdrs_hint_ipv6_dst_udp_src_port, IAVF_PHINT_IPV6_UDP},
1323 {ETH_RSS_NONFRAG_IPV6_UDP |
1324 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_DST_ONLY,
1325 &hdrs_hint_ipv6_dst_udp_dst_port, IAVF_PHINT_IPV6_UDP},
1326 {ETH_RSS_NONFRAG_IPV6_UDP |
1327 ETH_RSS_L3_DST_ONLY, &hdrs_hint_ipv6_dst,
1328 IAVF_PHINT_IPV6_UDP},
1329 {ETH_RSS_L4_SRC_ONLY,
1330 &hdrs_hint_ipv6_udp_src_port, IAVF_PHINT_IPV6_UDP},
1331 {ETH_RSS_L4_DST_ONLY,
1332 &hdrs_hint_ipv6_udp_dst_port, IAVF_PHINT_IPV6_UDP},
1333 {ETH_RSS_NONFRAG_IPV6_UDP | ETH_RSS_L4_SRC_ONLY,
1334 &hdrs_hint_ipv6_udp_src_port, IAVF_PHINT_IPV6_UDP},
1335 {ETH_RSS_NONFRAG_IPV6_UDP | ETH_RSS_L4_DST_ONLY,
1336 &hdrs_hint_ipv6_udp_dst_port, IAVF_PHINT_IPV6_UDP},
1338 &hdrs_hint_ipv6_pfcp, IAVF_PHINT_IPV6_UDP},
1340 &hdrs_hint_ipv6_udp_esp, IAVF_PHINT_IPV6_UDP},
1341 {ETH_RSS_NONFRAG_IPV6_UDP,
1342 &hdrs_hint_ipv6_udp, IAVF_PHINT_IPV6_UDP},
1344 {ETH_RSS_L2_SRC_ONLY,
1345 &hdrs_hint_eth_src_ipv6_tcp, IAVF_PHINT_IPV6_TCP},
1346 {ETH_RSS_L2_DST_ONLY,
1347 &hdrs_hint_eth_dst_ipv6_tcp, IAVF_PHINT_IPV6_TCP},
1349 &hdrs_hint_eth_ipv6_tcp, IAVF_PHINT_IPV6_TCP},
1350 {ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_SRC_ONLY,
1351 &hdrs_hint_ipv6_src_tcp_src_port, IAVF_PHINT_IPV6_TCP},
1352 {ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_DST_ONLY,
1353 &hdrs_hint_ipv6_src_tcp_dst_port, IAVF_PHINT_IPV6_TCP},
1354 {ETH_RSS_L3_SRC_ONLY,
1355 &hdrs_hint_ipv6_src, IAVF_PHINT_IPV6_TCP},
1356 {ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_SRC_ONLY,
1357 &hdrs_hint_ipv6_dst_tcp_src_port, IAVF_PHINT_IPV6_TCP},
1358 {ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_DST_ONLY,
1359 &hdrs_hint_ipv6_dst_tcp_dst_port, IAVF_PHINT_IPV6_TCP},
1360 {ETH_RSS_L3_DST_ONLY,
1361 &hdrs_hint_ipv6_dst, IAVF_PHINT_IPV6_TCP},
1362 {ETH_RSS_NONFRAG_IPV6_TCP |
1363 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_SRC_ONLY,
1364 &hdrs_hint_ipv6_src_tcp_src_port, IAVF_PHINT_IPV6_TCP},
1365 {ETH_RSS_NONFRAG_IPV6_TCP |
1366 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_DST_ONLY,
1367 &hdrs_hint_ipv6_src_tcp_dst_port, IAVF_PHINT_IPV6_TCP},
1368 {ETH_RSS_NONFRAG_IPV6_TCP |
1369 ETH_RSS_L3_SRC_ONLY, &hdrs_hint_ipv6_src,
1370 IAVF_PHINT_IPV6_TCP},
1371 {ETH_RSS_NONFRAG_IPV6_TCP |
1372 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_SRC_ONLY,
1373 &hdrs_hint_ipv6_dst_tcp_src_port, IAVF_PHINT_IPV6_TCP},
1374 {ETH_RSS_NONFRAG_IPV6_TCP |
1375 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_DST_ONLY,
1376 &hdrs_hint_ipv6_dst_tcp_dst_port, IAVF_PHINT_IPV6_TCP},
1377 {ETH_RSS_NONFRAG_IPV6_TCP |
1378 ETH_RSS_L3_DST_ONLY, &hdrs_hint_ipv6_dst,
1379 IAVF_PHINT_IPV6_TCP},
1380 {ETH_RSS_L4_SRC_ONLY,
1381 &hdrs_hint_ipv6_tcp_src_port, IAVF_PHINT_IPV6_TCP},
1382 {ETH_RSS_L4_DST_ONLY,
1383 &hdrs_hint_ipv6_tcp_dst_port, IAVF_PHINT_IPV6_TCP},
1384 {ETH_RSS_NONFRAG_IPV6_TCP | ETH_RSS_L4_SRC_ONLY,
1385 &hdrs_hint_ipv6_tcp_src_port, IAVF_PHINT_IPV6_TCP},
1386 {ETH_RSS_NONFRAG_IPV6_TCP | ETH_RSS_L4_DST_ONLY,
1387 &hdrs_hint_ipv6_tcp_dst_port, IAVF_PHINT_IPV6_TCP},
1388 {ETH_RSS_NONFRAG_IPV6_TCP,
1389 &hdrs_hint_ipv6_tcp, IAVF_PHINT_IPV6_TCP},
1391 {ETH_RSS_L2_SRC_ONLY,
1392 &hdrs_hint_eth_src_ipv6_sctp, IAVF_PHINT_IPV6_SCTP},
1393 {ETH_RSS_L2_DST_ONLY,
1394 &hdrs_hint_eth_dst_ipv6_sctp, IAVF_PHINT_IPV6_SCTP},
1396 &hdrs_hint_eth_ipv6_sctp, IAVF_PHINT_IPV6_SCTP},
1397 {ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_SRC_ONLY,
1398 &hdrs_hint_ipv6_src_sctp_src_port, IAVF_PHINT_IPV6_SCTP},
1399 {ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_DST_ONLY,
1400 &hdrs_hint_ipv6_src_sctp_dst_port, IAVF_PHINT_IPV6_SCTP},
1401 {ETH_RSS_L3_SRC_ONLY,
1402 &hdrs_hint_ipv6_src, IAVF_PHINT_IPV6_SCTP},
1403 {ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_SRC_ONLY,
1404 &hdrs_hint_ipv6_dst_sctp_src_port, IAVF_PHINT_IPV6_SCTP},
1405 {ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_DST_ONLY,
1406 &hdrs_hint_ipv6_dst_sctp_dst_port, IAVF_PHINT_IPV6_SCTP},
1407 {ETH_RSS_L3_DST_ONLY,
1408 &hdrs_hint_ipv6_dst, IAVF_PHINT_IPV6_SCTP},
1409 {ETH_RSS_NONFRAG_IPV6_SCTP |
1410 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_SRC_ONLY,
1411 &hdrs_hint_ipv6_src_sctp_src_port, IAVF_PHINT_IPV6_SCTP},
1412 {ETH_RSS_NONFRAG_IPV6_SCTP |
1413 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_DST_ONLY,
1414 &hdrs_hint_ipv6_src_sctp_dst_port, IAVF_PHINT_IPV6_SCTP},
1415 {ETH_RSS_NONFRAG_IPV6_SCTP |
1416 ETH_RSS_L3_SRC_ONLY, &hdrs_hint_ipv6_src,
1417 IAVF_PHINT_IPV6_SCTP},
1418 {ETH_RSS_NONFRAG_IPV6_SCTP |
1419 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_SRC_ONLY,
1420 &hdrs_hint_ipv6_dst_sctp_src_port, IAVF_PHINT_IPV6_SCTP},
1421 {ETH_RSS_NONFRAG_IPV6_SCTP |
1422 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_DST_ONLY,
1423 &hdrs_hint_ipv6_dst_sctp_dst_port, IAVF_PHINT_IPV6_SCTP},
1424 {ETH_RSS_NONFRAG_IPV6_SCTP |
1425 ETH_RSS_L3_DST_ONLY, &hdrs_hint_ipv6_dst,
1426 IAVF_PHINT_IPV6_SCTP},
1427 {ETH_RSS_L4_SRC_ONLY,
1428 &hdrs_hint_ipv6_sctp_src_port, IAVF_PHINT_IPV6_SCTP},
1429 {ETH_RSS_L4_DST_ONLY,
1430 &hdrs_hint_ipv6_sctp_dst_port, IAVF_PHINT_IPV6_SCTP},
1431 {ETH_RSS_NONFRAG_IPV6_SCTP | ETH_RSS_L4_SRC_ONLY,
1432 &hdrs_hint_ipv6_sctp_src_port, IAVF_PHINT_IPV6_SCTP},
1433 {ETH_RSS_NONFRAG_IPV6_SCTP | ETH_RSS_L4_DST_ONLY,
1434 &hdrs_hint_ipv6_sctp_dst_port, IAVF_PHINT_IPV6_SCTP},
1435 {ETH_RSS_NONFRAG_IPV6_SCTP,
1436 &hdrs_hint_ipv6_sctp, IAVF_PHINT_IPV6_SCTP},
1438 &hdrs_hint_svlan_ipv6, IAVF_PHINT_IPV6},
1440 &hdrs_hint_svlan_ipv6_udp, IAVF_PHINT_IPV6_UDP},
1442 &hdrs_hint_svlan_ipv6_tcp, IAVF_PHINT_IPV6_TCP},
1444 &hdrs_hint_svlan_ipv6_sctp, IAVF_PHINT_IPV6_SCTP},
1446 &hdrs_hint_cvlan_ipv6, IAVF_PHINT_IPV6},
1448 &hdrs_hint_cvlan_ipv6_udp, IAVF_PHINT_IPV6_UDP},
1450 &hdrs_hint_cvlan_ipv6_tcp, IAVF_PHINT_IPV6_TCP},
1452 &hdrs_hint_cvlan_ipv6_sctp, IAVF_PHINT_IPV6_SCTP},
1455 struct iavf_hash_match_type iavf_gtpu_hash_map_list[] = {
1459 {ETH_RSS_L3_SRC_ONLY,
1460 &hdrs_hint_ipv4_src_gtpu_eh,
1461 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4},
1462 {ETH_RSS_L3_DST_ONLY,
1463 &hdrs_hint_ipv4_dst_gtpu_eh,
1464 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4},
1466 ETH_RSS_L3_SRC_ONLY,
1467 &hdrs_hint_ipv4_src_gtpu_eh,
1468 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4},
1470 ETH_RSS_L3_DST_ONLY,
1471 &hdrs_hint_ipv4_dst_gtpu_eh,
1472 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4},
1474 &hdrs_hint_ipv4_gtpu_eh,
1475 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4},
1476 /* Inner IPV4->UDP */
1477 {ETH_RSS_L3_SRC_ONLY |
1478 ETH_RSS_L4_SRC_ONLY,
1479 &hdrs_hint_ipv4_src_udp_src_gtpu_eh,
1480 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_UDP},
1481 {ETH_RSS_L3_SRC_ONLY |
1482 ETH_RSS_L4_DST_ONLY,
1483 &hdrs_hint_ipv4_src_udp_dst_gtpu_eh,
1484 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_UDP},
1485 {ETH_RSS_L3_SRC_ONLY,
1486 &hdrs_hint_ipv4_src_gtpu_eh,
1487 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_UDP},
1488 {ETH_RSS_L4_SRC_ONLY,
1489 &hdrs_hint_ipv4_udp_src_gtpu_eh,
1490 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_UDP},
1491 {ETH_RSS_L3_DST_ONLY |
1492 ETH_RSS_L4_SRC_ONLY,
1493 &hdrs_hint_ipv4_dst_udp_src_gtpu_eh,
1494 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_UDP},
1495 {ETH_RSS_L3_DST_ONLY |
1496 ETH_RSS_L4_DST_ONLY,
1497 &hdrs_hint_ipv4_dst_udp_dst_gtpu_eh,
1498 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_UDP},
1499 {ETH_RSS_L3_DST_ONLY,
1500 &hdrs_hint_ipv4_dst_gtpu_eh,
1501 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_UDP},
1502 {ETH_RSS_L4_DST_ONLY,
1503 &hdrs_hint_ipv4_udp_dst_gtpu_eh,
1504 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_UDP},
1505 {ETH_RSS_NONFRAG_IPV4_UDP |
1506 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_SRC_ONLY,
1507 &hdrs_hint_ipv4_src_udp_src_gtpu_eh,
1508 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_UDP},
1509 {ETH_RSS_NONFRAG_IPV4_UDP |
1510 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_DST_ONLY,
1511 &hdrs_hint_ipv4_src_udp_dst_gtpu_eh,
1512 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_UDP},
1513 {ETH_RSS_NONFRAG_IPV4_UDP |
1514 ETH_RSS_L3_SRC_ONLY,
1515 &hdrs_hint_ipv4_src_gtpu_eh,
1516 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_UDP},
1517 {ETH_RSS_NONFRAG_IPV4_UDP |
1518 ETH_RSS_L4_SRC_ONLY,
1519 &hdrs_hint_ipv4_udp_src_gtpu_eh,
1520 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_UDP},
1521 {ETH_RSS_NONFRAG_IPV4_UDP |
1522 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_SRC_ONLY,
1523 &hdrs_hint_ipv4_dst_udp_src_gtpu_eh,
1524 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_UDP},
1525 {ETH_RSS_NONFRAG_IPV4_UDP |
1526 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_DST_ONLY,
1527 &hdrs_hint_ipv4_dst_udp_dst_gtpu_eh,
1528 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_UDP},
1529 {ETH_RSS_NONFRAG_IPV4_UDP |
1530 ETH_RSS_L3_DST_ONLY,
1531 &hdrs_hint_ipv4_dst_gtpu_eh,
1532 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_UDP},
1533 {ETH_RSS_NONFRAG_IPV4_UDP |
1534 ETH_RSS_L4_DST_ONLY,
1535 &hdrs_hint_ipv4_udp_dst_gtpu_eh,
1536 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_UDP},
1537 {ETH_RSS_NONFRAG_IPV4_UDP,
1538 &hdrs_hint_ipv4_udp_gtpu_eh,
1539 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_UDP},
1540 /* Inner IPV4->TCP */
1541 {ETH_RSS_L3_SRC_ONLY |
1542 ETH_RSS_L4_SRC_ONLY,
1543 &hdrs_hint_ipv4_src_tcp_src_gtpu_eh,
1544 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_TCP},
1545 {ETH_RSS_L3_SRC_ONLY |
1546 ETH_RSS_L4_DST_ONLY,
1547 &hdrs_hint_ipv4_src_tcp_dst_gtpu_eh,
1548 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_TCP},
1549 {ETH_RSS_L3_SRC_ONLY,
1550 &hdrs_hint_ipv4_src_gtpu_eh,
1551 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_TCP},
1552 {ETH_RSS_L4_SRC_ONLY,
1553 &hdrs_hint_ipv4_tcp_src_gtpu_eh,
1554 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_TCP},
1555 {ETH_RSS_L3_DST_ONLY |
1556 ETH_RSS_L4_SRC_ONLY,
1557 &hdrs_hint_ipv4_dst_tcp_src_gtpu_eh,
1558 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_TCP},
1559 {ETH_RSS_L3_DST_ONLY |
1560 ETH_RSS_L4_DST_ONLY,
1561 &hdrs_hint_ipv4_dst_tcp_dst_gtpu_eh,
1562 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_TCP},
1563 {ETH_RSS_L3_DST_ONLY,
1564 &hdrs_hint_ipv4_dst_gtpu_eh,
1565 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_TCP},
1566 {ETH_RSS_L4_DST_ONLY,
1567 &hdrs_hint_ipv4_tcp_dst_gtpu_eh,
1568 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_TCP},
1569 {ETH_RSS_NONFRAG_IPV4_TCP |
1570 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_SRC_ONLY,
1571 &hdrs_hint_ipv4_src_tcp_src_gtpu_eh,
1572 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_TCP},
1573 {ETH_RSS_NONFRAG_IPV4_TCP |
1574 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_DST_ONLY,
1575 &hdrs_hint_ipv4_src_tcp_dst_gtpu_eh,
1576 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_TCP},
1577 {ETH_RSS_NONFRAG_IPV4_TCP |
1578 ETH_RSS_L3_SRC_ONLY,
1579 &hdrs_hint_ipv4_src_gtpu_eh,
1580 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_TCP},
1581 {ETH_RSS_NONFRAG_IPV4_TCP |
1582 ETH_RSS_L4_SRC_ONLY,
1583 &hdrs_hint_ipv4_tcp_src_gtpu_eh,
1584 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_TCP},
1585 {ETH_RSS_NONFRAG_IPV4_TCP |
1586 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_SRC_ONLY,
1587 &hdrs_hint_ipv4_dst_tcp_src_gtpu_eh,
1588 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_TCP},
1589 {ETH_RSS_NONFRAG_IPV4_TCP |
1590 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_DST_ONLY,
1591 &hdrs_hint_ipv4_dst_tcp_dst_gtpu_eh,
1592 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_TCP},
1593 {ETH_RSS_NONFRAG_IPV4_TCP |
1594 ETH_RSS_L3_DST_ONLY,
1595 &hdrs_hint_ipv4_dst_gtpu_eh,
1596 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_TCP},
1597 {ETH_RSS_NONFRAG_IPV4_TCP |
1598 ETH_RSS_L4_DST_ONLY,
1599 &hdrs_hint_ipv4_tcp_dst_gtpu_eh,
1600 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_TCP},
1601 {ETH_RSS_NONFRAG_IPV4_TCP,
1602 &hdrs_hint_ipv4_tcp_gtpu_eh,
1603 IAVF_PHINT_IPV4_GTPU_EH | IAVF_PHINT_IPV4_TCP},
1606 {ETH_RSS_L3_SRC_ONLY,
1607 &hdrs_hint_ipv4_src_gtpu_up,
1608 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4},
1609 {ETH_RSS_L3_DST_ONLY,
1610 &hdrs_hint_ipv4_dst_gtpu_up,
1611 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4},
1613 ETH_RSS_L3_SRC_ONLY,
1614 &hdrs_hint_ipv4_src_gtpu_up,
1615 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4},
1617 ETH_RSS_L3_DST_ONLY,
1618 &hdrs_hint_ipv4_dst_gtpu_up,
1619 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4},
1621 &hdrs_hint_ipv4_gtpu_up,
1622 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4},
1623 /* Inner IPV4->UDP */
1624 {ETH_RSS_L3_SRC_ONLY |
1625 ETH_RSS_L4_SRC_ONLY,
1626 &hdrs_hint_ipv4_src_udp_src_gtpu_up,
1627 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_UDP},
1628 {ETH_RSS_L3_SRC_ONLY |
1629 ETH_RSS_L4_DST_ONLY,
1630 &hdrs_hint_ipv4_src_udp_dst_gtpu_up,
1631 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_UDP},
1632 {ETH_RSS_L3_SRC_ONLY,
1633 &hdrs_hint_ipv4_src_gtpu_up,
1634 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_UDP},
1635 {ETH_RSS_L4_SRC_ONLY,
1636 &hdrs_hint_ipv4_udp_src_gtpu_up,
1637 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_UDP},
1638 {ETH_RSS_L3_DST_ONLY |
1639 ETH_RSS_L4_SRC_ONLY,
1640 &hdrs_hint_ipv4_dst_udp_src_gtpu_up,
1641 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_UDP},
1642 {ETH_RSS_L3_DST_ONLY |
1643 ETH_RSS_L4_DST_ONLY,
1644 &hdrs_hint_ipv4_dst_udp_dst_gtpu_up,
1645 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_UDP},
1646 {ETH_RSS_L3_DST_ONLY,
1647 &hdrs_hint_ipv4_dst_gtpu_up,
1648 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_UDP},
1649 {ETH_RSS_L4_DST_ONLY,
1650 &hdrs_hint_ipv4_udp_dst_gtpu_up,
1651 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_UDP},
1652 {ETH_RSS_NONFRAG_IPV4_UDP |
1653 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_SRC_ONLY,
1654 &hdrs_hint_ipv4_src_udp_src_gtpu_up,
1655 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_UDP},
1656 {ETH_RSS_NONFRAG_IPV4_UDP |
1657 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_DST_ONLY,
1658 &hdrs_hint_ipv4_src_udp_dst_gtpu_up,
1659 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_UDP},
1660 {ETH_RSS_NONFRAG_IPV4_UDP |
1661 ETH_RSS_L3_SRC_ONLY,
1662 &hdrs_hint_ipv4_src_gtpu_up,
1663 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_UDP},
1664 {ETH_RSS_NONFRAG_IPV4_UDP |
1665 ETH_RSS_L4_SRC_ONLY,
1666 &hdrs_hint_ipv4_udp_src_gtpu_up,
1667 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_UDP},
1668 {ETH_RSS_NONFRAG_IPV4_UDP |
1669 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_SRC_ONLY,
1670 &hdrs_hint_ipv4_dst_udp_src_gtpu_up,
1671 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_UDP},
1672 {ETH_RSS_NONFRAG_IPV4_UDP |
1673 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_DST_ONLY,
1674 &hdrs_hint_ipv4_dst_udp_dst_gtpu_up,
1675 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_UDP},
1676 {ETH_RSS_NONFRAG_IPV4_UDP |
1677 ETH_RSS_L3_DST_ONLY,
1678 &hdrs_hint_ipv4_dst_gtpu_up,
1679 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_UDP},
1680 {ETH_RSS_NONFRAG_IPV4_UDP |
1681 ETH_RSS_L4_DST_ONLY,
1682 &hdrs_hint_ipv4_udp_dst_gtpu_up,
1683 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_UDP},
1684 {ETH_RSS_NONFRAG_IPV4_UDP,
1685 &hdrs_hint_ipv4_udp_gtpu_up,
1686 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_UDP},
1687 /* Inner IPV4->TCP */
1688 {ETH_RSS_L3_SRC_ONLY |
1689 ETH_RSS_L4_SRC_ONLY,
1690 &hdrs_hint_ipv4_src_tcp_src_gtpu_up,
1691 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_TCP},
1692 {ETH_RSS_L3_SRC_ONLY |
1693 ETH_RSS_L4_DST_ONLY,
1694 &hdrs_hint_ipv4_src_tcp_dst_gtpu_up,
1695 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_TCP},
1696 {ETH_RSS_L3_SRC_ONLY,
1697 &hdrs_hint_ipv4_src_gtpu_up,
1698 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_TCP},
1699 {ETH_RSS_L4_SRC_ONLY,
1700 &hdrs_hint_ipv4_tcp_src_gtpu_up,
1701 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_TCP},
1702 {ETH_RSS_L3_DST_ONLY |
1703 ETH_RSS_L4_SRC_ONLY,
1704 &hdrs_hint_ipv4_dst_tcp_src_gtpu_up,
1705 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_TCP},
1706 {ETH_RSS_L3_DST_ONLY |
1707 ETH_RSS_L4_DST_ONLY,
1708 &hdrs_hint_ipv4_dst_tcp_dst_gtpu_up,
1709 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_TCP},
1710 {ETH_RSS_L3_DST_ONLY,
1711 &hdrs_hint_ipv4_dst_gtpu_up,
1712 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_TCP},
1713 {ETH_RSS_L4_DST_ONLY,
1714 &hdrs_hint_ipv4_tcp_dst_gtpu_up,
1715 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_TCP},
1716 {ETH_RSS_NONFRAG_IPV4_TCP |
1717 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_SRC_ONLY,
1718 &hdrs_hint_ipv4_src_tcp_src_gtpu_up,
1719 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_TCP},
1720 {ETH_RSS_NONFRAG_IPV4_TCP |
1721 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_DST_ONLY,
1722 &hdrs_hint_ipv4_src_tcp_dst_gtpu_up,
1723 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_TCP},
1724 {ETH_RSS_NONFRAG_IPV4_TCP |
1725 ETH_RSS_L3_SRC_ONLY,
1726 &hdrs_hint_ipv4_src_gtpu_up,
1727 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_TCP},
1728 {ETH_RSS_NONFRAG_IPV4_TCP |
1729 ETH_RSS_L4_SRC_ONLY,
1730 &hdrs_hint_ipv4_tcp_src_gtpu_up,
1731 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_TCP},
1732 {ETH_RSS_NONFRAG_IPV4_TCP |
1733 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_SRC_ONLY,
1734 &hdrs_hint_ipv4_dst_tcp_src_gtpu_up,
1735 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_TCP},
1736 {ETH_RSS_NONFRAG_IPV4_TCP |
1737 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_DST_ONLY,
1738 &hdrs_hint_ipv4_dst_tcp_dst_gtpu_up,
1739 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_TCP},
1740 {ETH_RSS_NONFRAG_IPV4_TCP |
1741 ETH_RSS_L3_DST_ONLY,
1742 &hdrs_hint_ipv4_dst_gtpu_up,
1743 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_TCP},
1744 {ETH_RSS_NONFRAG_IPV4_TCP |
1745 ETH_RSS_L4_DST_ONLY,
1746 &hdrs_hint_ipv4_tcp_dst_gtpu_up,
1747 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_TCP},
1748 {ETH_RSS_NONFRAG_IPV4_TCP,
1749 &hdrs_hint_ipv4_tcp_gtpu_up,
1750 IAVF_PHINT_IPV4_GTPU_EH_UPLINK | IAVF_PHINT_IPV4_TCP},
1753 {ETH_RSS_L3_SRC_ONLY,
1754 &hdrs_hint_ipv4_src_gtpu_dwn,
1755 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4},
1756 {ETH_RSS_L3_DST_ONLY,
1757 &hdrs_hint_ipv4_dst_gtpu_dwn,
1758 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4},
1760 ETH_RSS_L3_SRC_ONLY,
1761 &hdrs_hint_ipv4_src_gtpu_dwn,
1762 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4},
1764 ETH_RSS_L3_DST_ONLY,
1765 &hdrs_hint_ipv4_dst_gtpu_dwn,
1766 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4},
1768 &hdrs_hint_ipv4_gtpu_dwn,
1769 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4},
1770 /* Inner IPV4->UDP */
1771 {ETH_RSS_L3_SRC_ONLY |
1772 ETH_RSS_L4_SRC_ONLY,
1773 &hdrs_hint_ipv4_src_udp_src_gtpu_dwn,
1774 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_UDP},
1775 {ETH_RSS_L3_SRC_ONLY |
1776 ETH_RSS_L4_DST_ONLY,
1777 &hdrs_hint_ipv4_src_udp_dst_gtpu_dwn,
1778 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_UDP},
1779 {ETH_RSS_L3_SRC_ONLY,
1780 &hdrs_hint_ipv4_src_gtpu_dwn,
1781 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_UDP},
1782 {ETH_RSS_L4_SRC_ONLY,
1783 &hdrs_hint_ipv4_udp_src_gtpu_dwn,
1784 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_UDP},
1785 {ETH_RSS_L3_DST_ONLY |
1786 ETH_RSS_L4_SRC_ONLY,
1787 &hdrs_hint_ipv4_dst_udp_src_gtpu_dwn,
1788 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_UDP},
1789 {ETH_RSS_L3_DST_ONLY |
1790 ETH_RSS_L4_DST_ONLY,
1791 &hdrs_hint_ipv4_dst_udp_dst_gtpu_dwn,
1792 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_UDP},
1793 {ETH_RSS_L3_DST_ONLY,
1794 &hdrs_hint_ipv4_dst_gtpu_dwn,
1795 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_UDP},
1796 {ETH_RSS_L4_DST_ONLY,
1797 &hdrs_hint_ipv4_udp_dst_gtpu_dwn,
1798 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_UDP},
1799 {ETH_RSS_NONFRAG_IPV4_UDP |
1800 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_SRC_ONLY,
1801 &hdrs_hint_ipv4_src_udp_src_gtpu_dwn,
1802 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_UDP},
1803 {ETH_RSS_NONFRAG_IPV4_UDP |
1804 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_DST_ONLY,
1805 &hdrs_hint_ipv4_src_udp_dst_gtpu_dwn,
1806 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_UDP},
1807 {ETH_RSS_NONFRAG_IPV4_UDP |
1808 ETH_RSS_L3_SRC_ONLY,
1809 &hdrs_hint_ipv4_src_gtpu_dwn,
1810 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_UDP},
1811 {ETH_RSS_NONFRAG_IPV4_UDP |
1812 ETH_RSS_L4_SRC_ONLY,
1813 &hdrs_hint_ipv4_udp_src_gtpu_dwn,
1814 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_UDP},
1815 {ETH_RSS_NONFRAG_IPV4_UDP |
1816 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_SRC_ONLY,
1817 &hdrs_hint_ipv4_dst_udp_src_gtpu_dwn,
1818 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_UDP},
1819 {ETH_RSS_NONFRAG_IPV4_UDP |
1820 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_DST_ONLY,
1821 &hdrs_hint_ipv4_dst_udp_dst_gtpu_dwn,
1822 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_UDP},
1823 {ETH_RSS_NONFRAG_IPV4_UDP |
1824 ETH_RSS_L3_DST_ONLY,
1825 &hdrs_hint_ipv4_dst_gtpu_dwn,
1826 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_UDP},
1827 {ETH_RSS_NONFRAG_IPV4_UDP |
1828 ETH_RSS_L4_DST_ONLY,
1829 &hdrs_hint_ipv4_udp_dst_gtpu_dwn,
1830 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_UDP},
1831 {ETH_RSS_NONFRAG_IPV4_UDP,
1832 &hdrs_hint_ipv4_udp_gtpu_dwn,
1833 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_UDP},
1834 /* Inner IPV4->TCP */
1835 {ETH_RSS_L3_SRC_ONLY |
1836 ETH_RSS_L4_SRC_ONLY,
1837 &hdrs_hint_ipv4_src_tcp_src_gtpu_dwn,
1838 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_TCP},
1839 {ETH_RSS_L3_SRC_ONLY |
1840 ETH_RSS_L4_DST_ONLY,
1841 &hdrs_hint_ipv4_src_tcp_dst_gtpu_dwn,
1842 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_TCP},
1843 {ETH_RSS_L3_SRC_ONLY,
1844 &hdrs_hint_ipv4_src_gtpu_dwn,
1845 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_TCP},
1846 {ETH_RSS_L4_SRC_ONLY,
1847 &hdrs_hint_ipv4_tcp_src_gtpu_dwn,
1848 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_TCP},
1849 {ETH_RSS_L3_DST_ONLY |
1850 ETH_RSS_L4_SRC_ONLY,
1851 &hdrs_hint_ipv4_dst_tcp_src_gtpu_dwn,
1852 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_TCP},
1853 {ETH_RSS_L3_DST_ONLY |
1854 ETH_RSS_L4_DST_ONLY,
1855 &hdrs_hint_ipv4_dst_tcp_dst_gtpu_dwn,
1856 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_TCP},
1857 {ETH_RSS_L3_DST_ONLY,
1858 &hdrs_hint_ipv4_dst_gtpu_dwn,
1859 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_TCP},
1860 {ETH_RSS_L4_DST_ONLY,
1861 &hdrs_hint_ipv4_tcp_dst_gtpu_dwn,
1862 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_TCP},
1863 {ETH_RSS_NONFRAG_IPV4_TCP |
1864 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_SRC_ONLY,
1865 &hdrs_hint_ipv4_src_tcp_src_gtpu_dwn,
1866 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_TCP},
1867 {ETH_RSS_NONFRAG_IPV4_TCP |
1868 ETH_RSS_L3_SRC_ONLY | ETH_RSS_L4_DST_ONLY,
1869 &hdrs_hint_ipv4_src_tcp_dst_gtpu_dwn,
1870 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_TCP},
1871 {ETH_RSS_NONFRAG_IPV4_TCP |
1872 ETH_RSS_L3_SRC_ONLY,
1873 &hdrs_hint_ipv4_src_gtpu_dwn,
1874 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_TCP},
1875 {ETH_RSS_NONFRAG_IPV4_TCP |
1876 ETH_RSS_L4_SRC_ONLY,
1877 &hdrs_hint_ipv4_tcp_src_gtpu_dwn,
1878 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_TCP},
1879 {ETH_RSS_NONFRAG_IPV4_TCP |
1880 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_SRC_ONLY,
1881 &hdrs_hint_ipv4_dst_tcp_src_gtpu_dwn,
1882 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_TCP},
1883 {ETH_RSS_NONFRAG_IPV4_TCP |
1884 ETH_RSS_L3_DST_ONLY | ETH_RSS_L4_DST_ONLY,
1885 &hdrs_hint_ipv4_dst_tcp_dst_gtpu_dwn,
1886 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_TCP},
1887 {ETH_RSS_NONFRAG_IPV4_TCP |
1888 ETH_RSS_L3_DST_ONLY,
1889 &hdrs_hint_ipv4_dst_gtpu_dwn,
1890 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_TCP},
1891 {ETH_RSS_NONFRAG_IPV4_TCP |
1892 ETH_RSS_L4_DST_ONLY,
1893 &hdrs_hint_ipv4_tcp_dst_gtpu_dwn,
1894 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_TCP},
1895 {ETH_RSS_NONFRAG_IPV4_TCP,
1896 &hdrs_hint_ipv4_tcp_gtpu_dwn,
1897 IAVF_PHINT_IPV4_GTPU_EH_DWNLINK | IAVF_PHINT_IPV4_TCP},
1900 struct virtchnl_proto_hdrs *iavf_hash_default_hdrs[] = {
1902 &hdrs_hint_ipv4_udp,
1903 &hdrs_hint_ipv4_tcp,
1904 &hdrs_hint_ipv4_sctp,
1906 &hdrs_hint_ipv6_udp,
1907 &hdrs_hint_ipv6_tcp,
1908 &hdrs_hint_ipv6_sctp,
1911 static struct iavf_flow_engine iavf_hash_engine = {
1912 .init = iavf_hash_init,
1913 .create = iavf_hash_create,
1914 .destroy = iavf_hash_destroy,
1915 .uninit = iavf_hash_uninit,
1916 .free = iavf_hash_free,
1917 .type = IAVF_FLOW_ENGINE_HASH,
1920 /* Register parser for comms package. */
1921 static struct iavf_flow_parser iavf_hash_parser = {
1922 .engine = &iavf_hash_engine,
1923 .array = iavf_hash_pattern_list,
1924 .array_len = RTE_DIM(iavf_hash_pattern_list),
1925 .parse_pattern_action = iavf_hash_parse_pattern_action,
1926 .stage = IAVF_FLOW_STAGE_RSS,
1930 iavf_hash_default_set(struct iavf_adapter *ad, bool add)
1932 struct virtchnl_rss_cfg *rss_cfg;
1936 rss_cfg = rte_zmalloc("iavf rss rule",
1937 sizeof(struct virtchnl_rss_cfg), 0);
1941 for (i = 0; i < RTE_DIM(iavf_hash_default_hdrs); i++) {
1942 rss_cfg->proto_hdrs = *iavf_hash_default_hdrs[i];
1943 rss_cfg->rss_algorithm = VIRTCHNL_RSS_ALG_TOEPLITZ_ASYMMETRIC;
1945 ret = iavf_add_del_rss_cfg(ad, rss_cfg, add);
1947 PMD_DRV_LOG(ERR, "fail to %s RSS configure",
1948 add ? "add" : "delete");
1957 RTE_INIT(iavf_hash_engine_init)
1959 struct iavf_flow_engine *engine = &iavf_hash_engine;
1961 iavf_register_flow_engine(engine);
1965 iavf_hash_init(struct iavf_adapter *ad)
1967 struct iavf_info *vf = IAVF_DEV_PRIVATE_TO_VF(ad);
1968 struct iavf_flow_parser *parser;
1974 if (!(vf->vf_res->vf_cap_flags & VIRTCHNL_VF_OFFLOAD_ADV_RSS_PF))
1977 parser = &iavf_hash_parser;
1979 ret = iavf_register_parser(parser, ad);
1981 PMD_DRV_LOG(ERR, "fail to register hash parser");
1985 ret = iavf_hash_default_set(ad, true);
1987 PMD_DRV_LOG(ERR, "fail to set default RSS");
1988 iavf_unregister_parser(parser, ad);
1995 iavf_hash_parse_pattern(struct iavf_pattern_match_item *pattern_match_item,
1996 const struct rte_flow_item pattern[], uint64_t *phint,
1997 struct rte_flow_error *error)
1999 const struct rte_flow_item *item = pattern;
2000 const struct rte_flow_item_gtp_psc *psc;
2002 for (item = pattern; item->type != RTE_FLOW_ITEM_TYPE_END; item++) {
2004 rte_flow_error_set(error, EINVAL,
2005 RTE_FLOW_ERROR_TYPE_ITEM, item,
2006 "Not support range");
2010 switch (item->type) {
2011 case RTE_FLOW_ITEM_TYPE_GTP_PSC:
2014 *phint |= IAVF_PHINT_IPV4_GTPU_EH;
2015 else if (psc->pdu_type == IAVF_GTPU_EH_UPLINK)
2016 *phint |= IAVF_PHINT_IPV4_GTPU_EH_UPLINK;
2017 else if (psc->pdu_type == IAVF_GTPU_EH_DWNLINK)
2018 *phint |= IAVF_PHINT_IPV4_GTPU_EH_DWNLINK;
2025 /* update and restore pattern hint */
2026 *phint |= ((struct iavf_pattern_match_type *)
2027 (pattern_match_item->meta))->pattern_hint;
2033 iavf_hash_parse_action(const struct rte_flow_action actions[],
2034 uint64_t pattern_hint, void **meta,
2035 struct rte_flow_error *error)
2037 struct iavf_rss_meta *rss_meta = (struct iavf_rss_meta *)*meta;
2038 struct iavf_hash_match_type *hash_map_list;
2039 enum rte_flow_action_type action_type;
2040 const struct rte_flow_action_rss *rss;
2041 const struct rte_flow_action *action;
2043 bool item_found = false;
2047 /* Supported action is RSS. */
2048 for (action = actions; action->type !=
2049 RTE_FLOW_ACTION_TYPE_END; action++) {
2050 action_type = action->type;
2051 switch (action_type) {
2052 case RTE_FLOW_ACTION_TYPE_RSS:
2054 rss_type = rss->types;
2057 RTE_ETH_HASH_FUNCTION_SIMPLE_XOR){
2058 rss_meta->rss_algorithm =
2059 VIRTCHNL_RSS_ALG_XOR_ASYMMETRIC;
2060 } else if (rss->func ==
2061 RTE_ETH_HASH_FUNCTION_SYMMETRIC_TOEPLITZ) {
2062 rss_meta->rss_algorithm =
2063 VIRTCHNL_RSS_ALG_TOEPLITZ_SYMMETRIC;
2065 rss_meta->rss_algorithm =
2066 VIRTCHNL_RSS_ALG_TOEPLITZ_ASYMMETRIC;
2070 return rte_flow_error_set(error, ENOTSUP,
2071 RTE_FLOW_ERROR_TYPE_ACTION, action,
2072 "a nonzero RSS encapsulation level is not supported");
2075 return rte_flow_error_set(error, ENOTSUP,
2076 RTE_FLOW_ERROR_TYPE_ACTION, action,
2077 "a nonzero RSS key_len is not supported");
2080 return rte_flow_error_set(error, ENOTSUP,
2081 RTE_FLOW_ERROR_TYPE_ACTION, action,
2082 "a non-NULL RSS queue is not supported");
2085 * Check simultaneous use of SRC_ONLY and DST_ONLY
2086 * of the same level.
2088 rss_type = rte_eth_rss_hf_refine(rss_type);
2090 if ((pattern_hint & IAVF_PHINT_IPV4_GTPU_EH) ||
2091 (pattern_hint & IAVF_PHINT_IPV4_GTPU_EH_UPLINK) ||
2092 (pattern_hint & IAVF_PHINT_IPV4_GTPU_EH_DWNLINK)) {
2093 hash_map_list = iavf_gtpu_hash_map_list;
2094 mlist_len = RTE_DIM(iavf_gtpu_hash_map_list);
2096 hash_map_list = iavf_hash_map_list;
2097 mlist_len = RTE_DIM(iavf_hash_map_list);
2100 /* Find matched proto hdrs according to hash type. */
2101 for (i = 0; i < mlist_len; i++) {
2102 struct iavf_hash_match_type *ht_map =
2104 if (rss_type == ht_map->hash_type &&
2105 pattern_hint == ht_map->pattern_hint) {
2106 rss_meta->proto_hdrs =
2114 return rte_flow_error_set(error, ENOTSUP,
2115 RTE_FLOW_ERROR_TYPE_ACTION, action,
2116 "Not supported flow");
2119 case RTE_FLOW_ACTION_TYPE_END:
2123 rte_flow_error_set(error, EINVAL,
2124 RTE_FLOW_ERROR_TYPE_ACTION, action,
2134 iavf_hash_parse_pattern_action(__rte_unused struct iavf_adapter *ad,
2135 struct iavf_pattern_match_item *array,
2137 const struct rte_flow_item pattern[],
2138 const struct rte_flow_action actions[],
2140 struct rte_flow_error *error)
2142 struct iavf_pattern_match_item *pattern_match_item;
2143 struct iavf_rss_meta *rss_meta_ptr;
2144 uint64_t phint = IAVF_PHINT_NONE;
2147 rss_meta_ptr = rte_zmalloc(NULL, sizeof(*rss_meta_ptr), 0);
2148 if (!rss_meta_ptr) {
2149 rte_flow_error_set(error, EINVAL,
2150 RTE_FLOW_ERROR_TYPE_HANDLE, NULL,
2151 "No memory for rss_meta_ptr");
2155 /* Check rss supported pattern and find matched pattern. */
2156 pattern_match_item =
2157 iavf_search_pattern_match_item(pattern, array, array_len,
2159 if (!pattern_match_item) {
2164 ret = iavf_hash_parse_pattern(pattern_match_item, pattern, &phint,
2169 ret = iavf_hash_parse_action(actions, phint,
2170 (void **)&rss_meta_ptr, error);
2174 *meta = rss_meta_ptr;
2176 rte_free(rss_meta_ptr);
2178 rte_free(pattern_match_item);
2184 iavf_hash_create(__rte_unused struct iavf_adapter *ad,
2185 __rte_unused struct rte_flow *flow, void *meta,
2186 __rte_unused struct rte_flow_error *error)
2188 struct iavf_rss_meta *rss_meta = (struct iavf_rss_meta *)meta;
2189 struct virtchnl_rss_cfg *rss_cfg;
2192 rss_cfg = rte_zmalloc("iavf rss rule",
2193 sizeof(struct virtchnl_rss_cfg), 0);
2195 rte_flow_error_set(error, EINVAL,
2196 RTE_FLOW_ERROR_TYPE_HANDLE, NULL,
2197 "No memory for rss rule");
2201 rss_cfg->proto_hdrs = *rss_meta->proto_hdrs;
2202 rss_cfg->rss_algorithm = rss_meta->rss_algorithm;
2204 ret = iavf_add_del_rss_cfg(ad, rss_cfg, true);
2206 flow->rule = rss_cfg;
2208 PMD_DRV_LOG(ERR, "fail to add RSS configure");
2209 rte_flow_error_set(error, -ret,
2210 RTE_FLOW_ERROR_TYPE_HANDLE, NULL,
2211 "Failed to add rss rule.");
2222 iavf_hash_destroy(__rte_unused struct iavf_adapter *ad,
2223 struct rte_flow *flow,
2224 __rte_unused struct rte_flow_error *error)
2226 struct virtchnl_rss_cfg *rss_cfg;
2229 rss_cfg = (struct virtchnl_rss_cfg *)flow->rule;
2231 ret = iavf_add_del_rss_cfg(ad, rss_cfg, false);
2233 PMD_DRV_LOG(ERR, "fail to del RSS configure");
2234 rte_flow_error_set(error, -ret,
2235 RTE_FLOW_ERROR_TYPE_HANDLE, NULL,
2236 "Failed to delete rss rule.");
2243 iavf_hash_uninit(struct iavf_adapter *ad)
2245 if (iavf_hash_default_set(ad, false))
2246 PMD_DRV_LOG(ERR, "fail to delete default RSS");
2248 iavf_unregister_parser(&iavf_hash_parser, ad);
2252 iavf_hash_free(struct rte_flow *flow)
2254 rte_free(flow->rule);