diff options
author | Daniel Borkmann <dborkman@redhat.com> | 2013-11-04 17:10:25 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2013-11-04 21:27:08 +0100 |
commit | cea80ea8d2a4c646f240a8fd6ece5c8e7bc969d3 (patch) | |
tree | 77a3386d2c211756a37acd65a0a9aee0e460e6cf /include/net/checksum.h | |
parent | Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net (diff) | |
download | linux-cea80ea8d2a4c646f240a8fd6ece5c8e7bc969d3.tar.xz linux-cea80ea8d2a4c646f240a8fd6ece5c8e7bc969d3.zip |
net: checksum: fix warning in skb_checksum
This patch fixes a build warning in skb_checksum() by wrapping the
csum_partial() usage in skb_checksum(). The problem is that on a few
architectures, csum_partial is used with prefix asmlinkage whereas
on most architectures it's not. So fix this up generically as we did
with csum_block_add_ext() to match the signature. Introduced by
2817a336d4d ("net: skb_checksum: allow custom update/combine for
walking skb").
Reported-by: Fengguang Wu <fengguang.wu@intel.com>
Signed-off-by: Daniel Borkmann <dborkman@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/net/checksum.h')
-rw-r--r-- | include/net/checksum.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/include/net/checksum.h b/include/net/checksum.h index 15f33fde826e..37a0e24adbe7 100644 --- a/include/net/checksum.h +++ b/include/net/checksum.h @@ -98,6 +98,11 @@ static inline __wsum csum_unfold(__sum16 n) return (__force __wsum)n; } +static inline __wsum csum_partial_ext(const void *buff, int len, __wsum sum) +{ + return csum_partial(buff, len, sum); +} + #define CSUM_MANGLED_0 ((__force __sum16)0xffff) static inline void csum_replace4(__sum16 *sum, __be32 from, __be32 to) |