head/sys/fs/nfsserver/nfs_nfsdcache.c
/*
 * Calculate the length of the mbuf list and a checksum on the first up to
 * NFSRVCACHE_CHECKLEN bytes.
 */
Calculate the length of the mbuf list and a checksum on the first up to
NFSRVCACHE_CHECKLEN bytes.
Calculate the length of the mbuf list and a checksum on the first up to NFSRVCACHE_CHECKLEN bytes .
static int
nfsrc_getlenandcksum(mbuf_t m1, u_int16_t *cksum)
{
	int len = 0, cklen;
	mbuf_t m;
	m = m1;
	while (m) {
		len += mbuf_len(m);
		m = mbuf_next(m);
	}
	cklen = (len > NFSRVCACHE_CHECKLEN) ? NFSRVCACHE_CHECKLEN : len;
	*cksum = in_cksum(m1, cklen);
	return (len);
}
static int nfsrc_getlenandcksum ( mbuf_t m1 , u_int16_t * cksum ) { int len = 0 , cklen ; mbuf_t m ; m = m1 ; while ( m ) { len += mbuf_len ( m ) ; m = mbuf_next ( m ) ; } cklen = ( len > NFSRVCACHE_CHECKLEN ) ? NFSRVCACHE_CHECKLEN : len ; * cksum = in_cksum ( m1 , cklen ) ; return ( len ) ; }
Calculate the length of the mbuf list and a checksum on the first up to
 NFSRVCACHE_CHECKLEN bytes.
Calculate the length of the mbuf list and a checksum on the first up to NFSRVCACHE_CHECKLEN bytes .