Deleted Added
full compact
mbuf.h (210225) mbuf.h (210226)
1/*-
2 * Copyright (c) 1982, 1986, 1988, 1993
3 * The Regents of the University of California.
4 * All rights reserved.
5 *
6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions
8 * are met:

--- 14 unchanged lines hidden (view full) ---

23 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
24 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
25 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
26 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
27 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
28 * SUCH DAMAGE.
29 *
30 * @(#)mbuf.h 8.5 (Berkeley) 2/19/95
1/*-
2 * Copyright (c) 1982, 1986, 1988, 1993
3 * The Regents of the University of California.
4 * All rights reserved.
5 *
6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions
8 * are met:

--- 14 unchanged lines hidden (view full) ---

23 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
24 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
25 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
26 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
27 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
28 * SUCH DAMAGE.
29 *
30 * @(#)mbuf.h 8.5 (Berkeley) 2/19/95
31 * $FreeBSD: head/sys/sys/mbuf.h 210225 2010-07-18 20:23:10Z trasz $
31 * $FreeBSD: head/sys/sys/mbuf.h 210226 2010-07-18 20:57:53Z trasz $
32 */
33
34#ifndef _SYS_MBUF_H_
35#define _SYS_MBUF_H_
36
37/* XXX: These includes suck. Sorry! */
38#include <sys/queue.h>
39#ifdef _KERNEL

--- 14 unchanged lines hidden (view full) ---

54 * clusters.
55 */
56#define MLEN (MSIZE - sizeof(struct m_hdr)) /* normal data len */
57#define MHLEN (MLEN - sizeof(struct pkthdr)) /* data len w/pkthdr */
58#define MINCLSIZE (MHLEN + 1) /* smallest amount to put in cluster */
59#define M_MAXCOMPRESS (MHLEN / 2) /* max amount to copy for compression */
60
61#ifdef _KERNEL
32 */
33
34#ifndef _SYS_MBUF_H_
35#define _SYS_MBUF_H_
36
37/* XXX: These includes suck. Sorry! */
38#include <sys/queue.h>
39#ifdef _KERNEL

--- 14 unchanged lines hidden (view full) ---

54 * clusters.
55 */
56#define MLEN (MSIZE - sizeof(struct m_hdr)) /* normal data len */
57#define MHLEN (MLEN - sizeof(struct pkthdr)) /* data len w/pkthdr */
58#define MINCLSIZE (MHLEN + 1) /* smallest amount to put in cluster */
59#define M_MAXCOMPRESS (MHLEN / 2) /* max amount to copy for compression */
60
61#ifdef _KERNEL
62/*
62/*-
63 * Macro for type conversion: convert mbuf pointer to data pointer of correct
64 * type:
65 *
66 * mtod(m, t) -- Convert mbuf pointer to data pointer of correct type.
67 */
68#define mtod(m, t) ((t)((m)->m_data))
69
70/*

--- 751 unchanged lines hidden (view full) ---

822void m_print(const struct mbuf *, int);
823struct mbuf *m_pulldown(struct mbuf *, int, int, int *);
824struct mbuf *m_pullup(struct mbuf *, int);
825int m_sanity(struct mbuf *, int);
826struct mbuf *m_split(struct mbuf *, int, int);
827struct mbuf *m_uiotombuf(struct uio *, int, int, int, int);
828struct mbuf *m_unshare(struct mbuf *, int how);
829
63 * Macro for type conversion: convert mbuf pointer to data pointer of correct
64 * type:
65 *
66 * mtod(m, t) -- Convert mbuf pointer to data pointer of correct type.
67 */
68#define mtod(m, t) ((t)((m)->m_data))
69
70/*

--- 751 unchanged lines hidden (view full) ---

822void m_print(const struct mbuf *, int);
823struct mbuf *m_pulldown(struct mbuf *, int, int, int *);
824struct mbuf *m_pullup(struct mbuf *, int);
825int m_sanity(struct mbuf *, int);
826struct mbuf *m_split(struct mbuf *, int, int);
827struct mbuf *m_uiotombuf(struct uio *, int, int, int, int);
828struct mbuf *m_unshare(struct mbuf *, int how);
829
830/*
830/*-
831 * Network packets may have annotations attached by affixing a list of
832 * "packet tags" to the pkthdr structure. Packet tags are dynamically
833 * allocated semi-opaque data structures that have a fixed header
834 * (struct m_tag) that specifies the size of the memory block and a
835 * <cookie,type> pair that identifies it. The cookie is a 32-bit unique
836 * unsigned value used to identify a module or ABI. By convention this value
837 * is chosen as the date+time that the module is created, expressed as the
838 * number of seconds since the epoch (e.g., using date -u +'%s'). The type

--- 195 unchanged lines hidden ---
831 * Network packets may have annotations attached by affixing a list of
832 * "packet tags" to the pkthdr structure. Packet tags are dynamically
833 * allocated semi-opaque data structures that have a fixed header
834 * (struct m_tag) that specifies the size of the memory block and a
835 * <cookie,type> pair that identifies it. The cookie is a 32-bit unique
836 * unsigned value used to identify a module or ABI. By convention this value
837 * is chosen as the date+time that the module is created, expressed as the
838 * number of seconds since the epoch (e.g., using date -u +'%s'). The type

--- 195 unchanged lines hidden ---