/**
* Allow PMD private flow item
*/
- size_t sz = type >= 0 ? desc[type].size : sizeof(void *);
+ bool rte_type = type >= 0;
+
+ size_t sz = rte_type ? desc[type].size : sizeof(void *);
if (buf == NULL || data == NULL)
return 0;
rte_memcpy(buf, data, (size > sz ? sz : size));
- if (desc[type].desc_fn)
+ if (rte_type && desc[type].desc_fn)
sz += desc[type].desc_fn(size > 0 ? buf : NULL, data);
return sz;
}
MK_FLOW_ITEM(META, sizeof(struct rte_flow_item_meta)),
MK_FLOW_ITEM(TAG, sizeof(struct rte_flow_item_tag)),
MK_FLOW_ITEM(GRE_KEY, sizeof(rte_be32_t)),
+ MK_FLOW_ITEM(GRE_OPTION, sizeof(struct rte_flow_item_gre_opt)),
MK_FLOW_ITEM(GTP_PSC, sizeof(struct rte_flow_item_gtp_psc)),
MK_FLOW_ITEM(PPPOES, sizeof(struct rte_flow_item_pppoe)),
MK_FLOW_ITEM(PPPOED, sizeof(struct rte_flow_item_pppoe)),
MK_FLOW_ITEM(REPRESENTED_PORT, sizeof(struct rte_flow_item_ethdev)),
MK_FLOW_ITEM_FN(FLEX, sizeof(struct rte_flow_item_flex),
rte_flow_item_flex_conv),
+ MK_FLOW_ITEM(L2TPV2, sizeof(struct rte_flow_item_l2tpv2)),
+ MK_FLOW_ITEM(PPP, sizeof(struct rte_flow_item_ppp)),
};
/** Generate flow_action[] entry. */