MCPcopy Create free account
hub / github.com/F-Stack/f-stack / nfp_flow_is_tunnel

Function nfp_flow_is_tunnel

dpdk/drivers/net/nfp/nfp_flow.c:1172–1192  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1170}
1171
1172static bool
1173nfp_flow_is_tunnel(struct rte_flow *nfp_flow)
1174{
1175 uint32_t key_layer2;
1176 struct nfp_flower_ext_meta *ext_meta;
1177 struct nfp_flower_meta_tci *meta_tci;
1178
1179 meta_tci = (struct nfp_flower_meta_tci *)nfp_flow->payload.unmasked_data;
1180 if ((meta_tci->nfp_flow_key_layer & NFP_FLOWER_LAYER_VXLAN) != 0)
1181 return true;
1182
1183 if ((meta_tci->nfp_flow_key_layer & NFP_FLOWER_LAYER_EXT_META) == 0)
1184 return false;
1185
1186 ext_meta = (struct nfp_flower_ext_meta *)(meta_tci + 1);
1187 key_layer2 = rte_be_to_cpu_32(ext_meta->nfp_flow_key_layer2);
1188 if ((key_layer2 & (NFP_FLOWER_LAYER2_GENEVE | NFP_FLOWER_LAYER2_GRE)) != 0)
1189 return true;
1190
1191 return false;
1192}
1193
1194static int
1195nfp_flow_merge_eth(__rte_unused struct nfp_app_fw_flower *app_fw_flower,

Callers 3

nfp_flow_merge_ipv4Function · 0.85
nfp_flow_merge_ipv6Function · 0.85
nfp_flow_destroyFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected