Re: [dpdk-dev] [PATCH] net/virtio: fix broken Tx checksum offloads

2019-10-25 Thread Ferruh Yigit
On 10/25/2019 9:30 AM, Maxime Coquelin wrote: > > > On 10/24/19 7:46 PM, Andrew Rybchenko wrote: >> Missing parenthesis around expression before type cast to struct >> virtio_net_hdr pointer makes the arithmetic to be in >> sizeof(struct virtio_net_hdr) units. >> >> Use rte_pktmbuf_mtod_offset()

Re: [dpdk-dev] [PATCH] net/virtio: fix broken Tx checksum offloads

2019-10-25 Thread Ferruh Yigit
On 10/25/2019 9:30 AM, Maxime Coquelin wrote: > > > On 10/24/19 7:46 PM, Andrew Rybchenko wrote: >> Missing parenthesis around expression before type cast to struct >> virtio_net_hdr pointer makes the arithmetic to be in >> sizeof(struct virtio_net_hdr) units. >> >> Use rte_pktmbuf_mtod_offset()

Re: [dpdk-dev] [PATCH] net/virtio: fix broken Tx checksum offloads

2019-10-25 Thread Maxime Coquelin
Missed to add Ferruh. On 10/25/19 10:30 AM, Maxime Coquelin wrote: > > > On 10/24/19 7:46 PM, Andrew Rybchenko wrote: >> Missing parenthesis around expression before type cast to struct >> virtio_net_hdr pointer makes the arithmetic to be in >> sizeof(struct virtio_net_hdr) units. >> >> Use rte_

Re: [dpdk-dev] [PATCH] net/virtio: fix broken Tx checksum offloads

2019-10-25 Thread Maxime Coquelin
On 10/24/19 7:46 PM, Andrew Rybchenko wrote: > Missing parenthesis around expression before type cast to struct > virtio_net_hdr pointer makes the arithmetic to be in > sizeof(struct virtio_net_hdr) units. > > Use rte_pktmbuf_mtod_offset() to fix the problem. > > Type of head_size is changed t

Re: [dpdk-dev] [PATCH] net/virtio: fix broken Tx checksum offloads

2019-10-24 Thread Tiwei Bie
On Thu, Oct 24, 2019 at 06:46:09PM +0100, Andrew Rybchenko wrote: > Missing parenthesis around expression before type cast to struct > virtio_net_hdr pointer makes the arithmetic to be in > sizeof(struct virtio_net_hdr) units. > > Use rte_pktmbuf_mtod_offset() to fix the problem. > > Type of head

[dpdk-dev] [PATCH] net/virtio: fix broken Tx checksum offloads

2019-10-24 Thread Andrew Rybchenko
Missing parenthesis around expression before type cast to struct virtio_net_hdr pointer makes the arithmetic to be in sizeof(struct virtio_net_hdr) units. Use rte_pktmbuf_mtod_offset() to fix the problem. Type of head_size is changed to signed since some compilers bark on unary minus applied to u