1 #ifndef __NET_CHECKSUM_WRAPPER_H
2 #define __NET_CHECKSUM_WRAPPER_H 1
4 #include_next <net/checksum.h>
6 #ifndef HAVE_CSUM_UNFOLD
7 static inline __wsum csum_unfold(__sum16 n)
9 return (__force __wsum)n;
11 #endif /* !HAVE_CSUM_UNFOLD */
13 /* Workaround for debugging included in certain versions of XenServer. It only
14 * applies to 32-bit x86.
16 #if defined(HAVE_CSUM_COPY_DBG) && defined(CONFIG_X86_32)
17 #define csum_and_copy_to_user(src, dst, len, sum, err_ptr) \
18 csum_and_copy_to_user(src, dst, len, sum, NULL, err_ptr)
21 #endif /* checksum.h */