}
}
+/* Internal Function to identify broadcast or multicast packets */
+static int32_t
+ulp_rte_parser_is_bcmc_addr(const struct rte_ether_addr *eth_addr)
+{
+ if (rte_is_multicast_ether_addr(eth_addr) ||
+ rte_is_broadcast_ether_addr(eth_addr)) {
+ BNXT_TF_DBG(DEBUG,
+ "No support for bcast or mcast addr offload\n");
+ return 1;
+ }
+ return 0;
+}
+
/* Function to handle the parsing of RTE Flow item Ethernet Header. */
int32_t
ulp_rte_eth_hdr_handler(const struct rte_flow_item *item,
field = ulp_rte_parser_fld_copy(¶ms->hdr_field[idx],
eth_spec->dst.addr_bytes,
size);
+ /* Todo: work around to avoid multicast and broadcast addr */
+ if (ulp_rte_parser_is_bcmc_addr(ð_spec->dst))
+ return BNXT_TF_RC_PARSE_ERR;
+
size = sizeof(eth_spec->src.addr_bytes);
field = ulp_rte_parser_fld_copy(field,
eth_spec->src.addr_bytes,
size);
+ /* Todo: work around to avoid multicast and broadcast addr */
+ if (ulp_rte_parser_is_bcmc_addr(ð_spec->src))
+ return BNXT_TF_RC_PARSE_ERR;
+
field = ulp_rte_parser_fld_copy(field,
ð_spec->type,
sizeof(eth_spec->type));