aboutgitcodebugslistschat
path: root/checksum.h
diff options
context:
space:
mode:
authorLaurent Vivier <lvivier@redhat.com>2024-10-03 16:51:08 +0200
committerStefano Brivio <sbrivio@redhat.com>2024-10-04 14:51:13 +0200
commit151dbe0d3d3690978a0a5cf3b8fa9808bd708668 (patch)
tree0f0b3daf785a837b8648b55b3ad2fa6ea5aad7f0 /checksum.h
parent3d484aa370902873bd42a434fa856b9ee3eac228 (diff)
downloadpasst-151dbe0d3d3690978a0a5cf3b8fa9808bd708668.tar
passt-151dbe0d3d3690978a0a5cf3b8fa9808bd708668.tar.gz
passt-151dbe0d3d3690978a0a5cf3b8fa9808bd708668.tar.bz2
passt-151dbe0d3d3690978a0a5cf3b8fa9808bd708668.tar.lz
passt-151dbe0d3d3690978a0a5cf3b8fa9808bd708668.tar.xz
passt-151dbe0d3d3690978a0a5cf3b8fa9808bd708668.tar.zst
passt-151dbe0d3d3690978a0a5cf3b8fa9808bd708668.zip
udp: Update UDP checksum using an iovec array
As for tcp_update_check_tcp4()/tcp_update_check_tcp6(), change csum_udp4() and csum_udp6() to use an iovec array. Signed-off-by: Laurent Vivier <lvivier@redhat.com> Signed-off-by: Stefano Brivio <sbrivio@redhat.com>
Diffstat (limited to 'checksum.h')
-rw-r--r--checksum.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/checksum.h b/checksum.h
index 49f7472..31ba322 100644
--- a/checksum.h
+++ b/checksum.h
@@ -19,14 +19,14 @@ uint32_t proto_ipv4_header_psum(uint16_t l4len, uint8_t protocol,
struct in_addr saddr, struct in_addr daddr);
void csum_udp4(struct udphdr *udp4hr,
struct in_addr saddr, struct in_addr daddr,
- const void *payload, size_t dlen);
+ const struct iovec *iov, int iov_cnt, size_t offset);
void csum_icmp4(struct icmphdr *icmp4hr, const void *payload, size_t dlen);
uint32_t proto_ipv6_header_psum(uint16_t payload_len, uint8_t protocol,
const struct in6_addr *saddr,
const struct in6_addr *daddr);
void csum_udp6(struct udphdr *udp6hr,
const struct in6_addr *saddr, const struct in6_addr *daddr,
- const void *payload, size_t dlen);
+ const struct iovec *iov, int iov_cnt, size_t offset);
void csum_icmp6(struct icmp6hdr *icmp6hr,
const struct in6_addr *saddr, const struct in6_addr *daddr,
const void *payload, size_t dlen);