Linux Kernel  3.7.1
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
Functions
checksum.c File Reference
#include <linux/module.h>
#include <linux/errno.h>
#include <asm/byteorder.h>
#include <asm/uaccess.h>
#include <asm/checksum.h>
#include "internal.h"

Go to the source code of this file.

Functions

__sum16 ip_fast_csum (const void *iph, unsigned int ihl)
 
 EXPORT_SYMBOL (ip_fast_csum)
 
__wsum csum_partial (const void *buff, int len, __wsum sum)
 
 EXPORT_SYMBOL (csum_partial)
 
__sum16 ip_compute_csum (const void *buff, int len)
 
 EXPORT_SYMBOL (ip_compute_csum)
 
__wsum csum_partial_copy (const void *src, void *dst, int len, __wsum sum)
 
 EXPORT_SYMBOL (csum_partial_copy)
 
__wsum csum_partial_copy_nocheck (const void *src, void *dst, int len, __wsum sum)
 
 EXPORT_SYMBOL (csum_partial_copy_nocheck)
 
__wsum csum_partial_copy_from_user (const void *src, void *dst, int len, __wsum sum, int *err_ptr)
 
 EXPORT_SYMBOL (csum_partial_copy_from_user)
 
__wsum csum_and_copy_to_user (const void *src, void *dst, int len, __wsum sum, int *err_ptr)
 
 EXPORT_SYMBOL (csum_and_copy_to_user)
 

Function Documentation

__wsum csum_and_copy_to_user ( const void src,
void dst,
int  len,
__wsum  sum,
int err_ptr 
)

Definition at line 86 of file checksum.c.

__wsum csum_partial ( const void buff,
int  len,
__wsum  sum 
)

csum_partial - Compute an internet checksum. : buffer to be checksummed : length of buffer. : initial sum to be added in (32bit unfolded)

Returns the 32bit unfolded internet checksum of the buffer. Before filling it in it needs to be csum_fold()'ed. buff should be aligned to a 64bit boundary if possible.

Definition at line 36 of file checksum.c.

__wsum csum_partial_copy ( const void src,
void dst,
int  len,
__wsum  sum 
)

Definition at line 54 of file checksum.c.

__wsum csum_partial_copy_from_user ( const void src,
void dst,
int  len,
__wsum  sum,
int err_ptr 
)

Definition at line 70 of file checksum.c.

__wsum csum_partial_copy_nocheck ( const void src,
void dst,
int  len,
__wsum  sum 
)

Definition at line 61 of file checksum.c.

EXPORT_SYMBOL ( ip_fast_csum  )
EXPORT_SYMBOL ( csum_partial  )
EXPORT_SYMBOL ( ip_compute_csum  )
EXPORT_SYMBOL ( csum_partial_copy  )
EXPORT_SYMBOL ( csum_partial_copy_nocheck  )
EXPORT_SYMBOL ( csum_partial_copy_from_user  )
EXPORT_SYMBOL ( csum_and_copy_to_user  )
__sum16 ip_compute_csum ( const void buff,
int  len 
)

ip_compute_csum - Compute an 16bit IP checksum. : buffer address. : length of buffer.

Returns the 16bit folded/inverted checksum of the passed buffer. Ready to fill in.

Definition at line 48 of file checksum.c.

__sum16 ip_fast_csum ( const void iph,
unsigned int  ihl 
)

Definition at line 30 of file checksum.c.