Deleted Added
full compact
mbufq.h (174640) mbufq.h (176472)
1/**************************************************************************
2
3Copyright (c) 2007, Chelsio Inc.
4All rights reserved.
5
6Redistribution and use in source and binary forms, with or without
7modification, are permitted provided that the following conditions are met:
8

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

20LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
21CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
22SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
23INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
24CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
25ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
26POSSIBILITY OF SUCH DAMAGE.
27
1/**************************************************************************
2
3Copyright (c) 2007, Chelsio Inc.
4All rights reserved.
5
6Redistribution and use in source and binary forms, with or without
7modification, are permitted provided that the following conditions are met:
8

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

20LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
21CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
22SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
23INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
24CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
25ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
26POSSIBILITY OF SUCH DAMAGE.
27
28$FreeBSD: head/sys/dev/cxgb/sys/mbufq.h 174640 2007-12-16 05:19:48Z kmacy $
28$FreeBSD: head/sys/dev/cxgb/sys/mbufq.h 176472 2008-02-23 01:06:17Z kmacy $
29
30***************************************************************************/
31
32#ifndef CXGB_MBUFQ_H_
33#define CXGB_MBUFQ_H_
34
35struct mbuf_head {
36 struct mbuf *head;

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

98 l->qlen--;
99 l->qsize -= m->m_pkthdr.len;
100 }
101
102 return (m);
103}
104
105static __inline struct mbuf *
29
30***************************************************************************/
31
32#ifndef CXGB_MBUFQ_H_
33#define CXGB_MBUFQ_H_
34
35struct mbuf_head {
36 struct mbuf *head;

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

98 l->qlen--;
99 l->qsize -= m->m_pkthdr.len;
100 }
101
102 return (m);
103}
104
105static __inline struct mbuf *
106mbufq_peek(struct mbuf_head *l)
106mbufq_peek(const struct mbuf_head *l)
107{
108 return (l->head);
109}
110
111static __inline void
112mbufq_append(struct mbuf_head *a, struct mbuf_head *b)
113{
114 if (a->tail)
115 a->tail->m_nextpkt = b->head;
116 if (b->tail)
117 a->tail = b->tail;
118 a->qlen += b->qlen;
119 a->qsize += b->qsize;
120
121
122}
123#endif /* CXGB_MBUFQ_H_ */
107{
108 return (l->head);
109}
110
111static __inline void
112mbufq_append(struct mbuf_head *a, struct mbuf_head *b)
113{
114 if (a->tail)
115 a->tail->m_nextpkt = b->head;
116 if (b->tail)
117 a->tail = b->tail;
118 a->qlen += b->qlen;
119 a->qsize += b->qsize;
120
121
122}
123#endif /* CXGB_MBUFQ_H_ */