[dpdk-dev] [PATCH v2 3/5] szedata2: add handling of scattered packets in TX
Thomas Monjalon
thomas.monjalon at 6wind.com
Mon Oct 26 15:55:20 CET 2015
Hi Matej,
2015-09-18 10:32, Matej Vido:
> - rte_memcpy(tmp_dst,
> - rte_pktmbuf_mtod(mbuf, const void *),
> - pkt_len);
> + if (likely(mbuf_segs == 1)) {
> + /*
> + * non-scattered packet,
> + * transmit from one mbuf
> + */
> + rte_memcpy(tmp_dst,
> + rte_pktmbuf_mtod(mbuf, const void *),
> + pkt_len);
You could avoid this change by keeping "if (likely(mbuf_segs == 1))"
in the first patch.
By the way, it seems to be an abusive use of "likely".
More information about the dev
mailing list