Re: [dpdk-dev] [dpdk-users] IPV4/IPV6 TCP/UDP Pseudo Header Checksum APIs

2018-11-28 Thread Hyong Youb Kim
On Tue, Oct 23, 2018 at 11:01:58AM +0200, Olivier Matz wrote: > Hi, > > You are right, the current code does not take IP or IPv6 options > in account. I think this should be considered as a bug. > > The fix for IPv4 is not complicated, I did a quick draft here: > http://git.droids-corp.org/?p=dpd

Re: [dpdk-dev] [dpdk-users] IPV4/IPV6 TCP/UDP Pseudo Header Checksum APIs

2018-10-23 Thread Shyam Shrivastav
These fixes/modifications should include the upper level APIs, rte_ipv4_udptcp_cksum and rte_ipv6_udptcp_cksum. Even for ipv4 following API is more/really useful if changed to take mbufs rte_ipv4_udptcp_cksum(const struct ipv4_hdr *ipv4_hdr, const void *l4_hdr) I can not use it in present form a

Re: [dpdk-dev] [dpdk-users] IPV4/IPV6 TCP/UDP Pseudo Header Checksum APIs

2018-10-23 Thread Olivier Matz
Hi, You are right, the current code does not take IP or IPv6 options in account. I think this should be considered as a bug. The fix for IPv4 is not complicated, I did a quick draft here: http://git.droids-corp.org/?p=dpdk.git;a=commitdiff;h=96a6978ef6814e1450e1bd65fbce91c3d85b3121 For IPv6, it

Re: [dpdk-dev] [dpdk-users] IPV4/IPV6 TCP/UDP Pseudo Header Checksum APIs

2018-10-22 Thread Ferruh Yigit
On 10/20/2018 7:30 AM, Shyam Shrivastav wrote: > Yes you are right, I misread, following code (ipv4 case) assumes no ip > options while calculating pseudo hdr length field > > psd_hdr.len = rte_cpu_to_be_16( > (uint16_t)(rte_be_to_cpu_16(ipv4_hdr->total_length) >