diff options
author | Laurent Vivier <lvivier@redhat.com> | 2024-10-03 16:51:06 +0200 |
---|---|---|
committer | Stefano Brivio <sbrivio@redhat.com> | 2024-10-04 14:51:08 +0200 |
commit | e6548c643796f036de83163e395f0efd56da4790 (patch) | |
tree | 373cacbab76e3027c785815dba789652d8f11157 /checksum.h | |
parent | fd8334b25dfa0cf4a93bb7fad6728f3bd0e31c6d (diff) | |
download | passt-e6548c643796f036de83163e395f0efd56da4790.tar passt-e6548c643796f036de83163e395f0efd56da4790.tar.gz passt-e6548c643796f036de83163e395f0efd56da4790.tar.bz2 passt-e6548c643796f036de83163e395f0efd56da4790.tar.lz passt-e6548c643796f036de83163e395f0efd56da4790.tar.xz passt-e6548c643796f036de83163e395f0efd56da4790.tar.zst passt-e6548c643796f036de83163e395f0efd56da4790.zip |
checksum: Add an offset argument in csum_iov()
The offset allows any headers that are not part of the data
to checksum to be skipped.
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.h | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -32,6 +32,7 @@ void csum_icmp6(struct icmp6hdr *icmp6hr, const void *payload, size_t dlen); uint32_t csum_unfolded(const void *buf, size_t len, uint32_t init); uint16_t csum(const void *buf, size_t len, uint32_t init); -uint16_t csum_iov(const struct iovec *iov, size_t n, uint32_t init); +uint16_t csum_iov(const struct iovec *iov, size_t n, size_t offset, + uint32_t init); #endif /* CHECKSUM_H */ |