[dpdk-dev] [PATCH v3 6/8] driver/virtio:enqueue vhost TX offload

Liu, Jijiang jijiang.liu at intel.com
Wed Nov 4 13:52:00 CET 2015


Hi Thomas,


> -----Original Message-----
> From: Thomas Monjalon [mailto:thomas.monjalon at 6wind.com]
> Sent: Wednesday, November 4, 2015 7:18 PM
> To: Liu, Jijiang
> Cc: dev at dpdk.org; Michael S. Tsirkin
> Subject: Re: [dpdk-dev] [PATCH v3 6/8] driver/virtio:enqueue vhost 


The following code is not in the patch 6, please review the latest patch set.


> > +	parse_ethernet(m, &l4_proto, &l4_hdr);
> > +	if (hdr->flags == VIRTIO_NET_HDR_F_NEEDS_CSUM) {
> > +		if ((hdr->csum_start == m->l2_len) &&
> > +			(hdr->csum_offset == offsetof(struct ipv4_hdr,
> > +						hdr_checksum)))
> > +			m->ol_flags |= PKT_TX_IP_CKSUM;
> > +		else if (hdr->csum_start == (m->l2_len + m->l3_len)) {
> > +			switch (hdr->csum_offset) {
> > +			case (offsetof(struct tcp_hdr, cksum)):
> > +				if (l4_proto == IPPROTO_TCP)
> > +					m->ol_flags |= PKT_TX_TCP_CKSUM;
> > +				break;
> > +			case (offsetof(struct udp_hdr, dgram_cksum)):
> > +				if (l4_proto == IPPROTO_UDP)
> > +					m->ol_flags |= PKT_TX_UDP_CKSUM;
> > +				break;
> > +			case (offsetof(struct sctp_hdr, cksum)):
> > +				if (l4_proto == IPPROTO_SCTP)
> > +					m->ol_flags |= PKT_TX_SCTP_CKSUM;
> > +				break;
> > +			default:
> > +				break;
> > +			}
> > +		}
> 
> The kernel doesn't work this way.
> Please could you check that your virtio implementation works with a vanilla
> Linux with or without vhost?
> Thanks

This is vhost lib implementation, not virtio-net side.
We have already validated with a vanilla Linux with or without virtio-net, and it passed.
Could you please review latest patch v3?

Xu Qian can send the test report out.  



More information about the dev mailing list