[dpdk-dev] [PATCH v2 3/4] vmxnet3: add TSO support

2016-01-05 Thread Yong Wang
On 1/4/16, 9:15 PM, "Stephen Hemminger" wrote: >On Mon, 4 Jan 2016 18:28:18 -0800 >Yong Wang wrote: > >> +/* The number of descriptors that are needed for a packet. */ >> +static unsigned >> +txd_estimate(const struct rte_mbuf *m) >> +{ >> +return m->nb_segs; >> +} >> + > >A wrapper funct

[dpdk-dev] [PATCH v2 3/4] vmxnet3: add TSO support

2016-01-05 Thread Yong Wang
On 1/4/16, 9:14 PM, "Stephen Hemminger" wrote: >On Mon, 4 Jan 2016 18:28:18 -0800 >Yong Wang wrote: > >> +mbuf = txq->cmd_ring.buf_info[eop_idx].m; >> +if (unlikely(mbuf == NULL)) >> +rte_panic("EOP desc does not point to a valid mbuf"); >> +else > >The unlikely is rea

[dpdk-dev] [PATCH v2 3/4] vmxnet3: add TSO support

2016-01-04 Thread Stephen Hemminger
On Mon, 4 Jan 2016 18:28:18 -0800 Yong Wang wrote: > +/* The number of descriptors that are needed for a packet. */ > +static unsigned > +txd_estimate(const struct rte_mbuf *m) > +{ > + return m->nb_segs; > +} > + A wrapper function only really clarifies if it is hiding some information. Wh

[dpdk-dev] [PATCH v2 3/4] vmxnet3: add TSO support

2016-01-04 Thread Stephen Hemminger
On Mon, 4 Jan 2016 18:28:18 -0800 Yong Wang wrote: > + mbuf = txq->cmd_ring.buf_info[eop_idx].m; > + if (unlikely(mbuf == NULL)) > + rte_panic("EOP desc does not point to a valid mbuf"); > + else The unlikely is really not needed with rte_panic since it is declared with

[dpdk-dev] [PATCH v2 3/4] vmxnet3: add TSO support

2016-01-04 Thread Yong Wang
This commit adds vmxnet3 TSO support. Verified with test-pmd (set fwd csum) that both tso and non-tso pkts can be successfully transmitted and all segmentes for a tso pkt are correct on the receiver side. Signed-off-by: Yong Wang --- doc/guides/rel_notes/release_2_3.rst | 3 + drivers/net/vmx