-# $OpenBSD: Makefile,v 1.247 2015/10/21 08:48:12 mpi Exp $
+# $OpenBSD: Makefile,v 1.248 2015/10/22 05:26:06 dlg Exp $
# $NetBSD: Makefile,v 1.4 1996/01/09 03:23:01 thorpej Exp $
# Makefile for section 9 (kernel function and variable) manual pages.
microtime.9 getnanouptime.9 microtime.9 bintime.9 \
microtime.9 binuptime.9
MLINKS+=ml_init.9 ml_enqueue.9 ml_init.9 ml_dequeue.9 ml_init.9 ml_requeue.9 \
- ml_init.9 ml_dechain.9 \
+ ml_init.9 ml_enlist.9 ml_init.9 ml_dechain.9 \
ml_init.9 ml_filter.9 ml_init.9 ml_len.9 ml_init.9 ml_empty.9 \
ml_init.9 MBUF_LIST_INITIALIZER.9 ml_init.9 MBUF_LIST_FOREACH.9
MLINKS+=mountroothook_establish.9 mountroothook_disestablish.9
-.\" $OpenBSD: ml_init.9,v 1.6 2015/10/02 09:24:13 sobrado Exp $
+.\" $OpenBSD: ml_init.9,v 1.7 2015/10/22 05:26:06 dlg Exp $
.\"
.\" Copyright (c) 2015 David Gwynne <dlg@openbsd.org>
.\"
.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
.\"
-.Dd $Mdocdate: October 2 2015 $
+.Dd $Mdocdate: October 22 2015 $
.Dt ML_INIT 9
.Os
.Sh NAME
.Nm ml_enqueue ,
.Nm ml_dequeue ,
.Nm ml_requeue ,
+.Nm ml_enlist ,
.Nm ml_dechain ,
.Nm ml_len ,
.Nm ml_empty ,
.Fn ml_dequeue "struct mbuf_list *ml"
.Ft void
.Fn ml_requeue "struct mbuf_list *ml" "struct mbuf *m"
+.Ft void
+.Fn ml_enlist "struct mbuf_list *ml" "struct mbuf_list *src"
.Ft struct mbuf *
.Fn ml_dechain "struct mbuf_list *ml"
.Ft struct mbuf *
at the head of the
.Fa ml
mbuf list.
+.It Fn ml_enlist "struct mbuf_list *ml" "struct mbuf_list *src"
+Enqueue all the mbufs on the
+.Fa src
+mbuf list on to the end of the
+.Fa ml
+mbuf list.
.It Fn ml_dechain "struct mbuf_list *ml"
Dequeues all mbufs from the
.Fa ml
.Fn ml_enqueue ,
.Fn ml_dequeue ,
.Fn ml_requeue ,
+.Fn ml_enlist ,
.Fn ml_dechain ,
.Fn ml_len ,
.Fn ml_empty ,
-/* $OpenBSD: uipc_mbuf.c,v 1.207 2015/08/14 05:25:29 dlg Exp $ */
+/* $OpenBSD: uipc_mbuf.c,v 1.208 2015/10/22 05:26:06 dlg Exp $ */
/* $NetBSD: uipc_mbuf.c,v 1.15.4.1 1996/06/13 17:11:44 cgd Exp $ */
/*
* mbuf lists
*/
-void ml_join(struct mbuf_list *, struct mbuf_list *);
-
void
ml_init(struct mbuf_list *ml)
{
}
void
-ml_join(struct mbuf_list *mla, struct mbuf_list *mlb)
+ml_enlist(struct mbuf_list *mla, struct mbuf_list *mlb)
{
if (!ml_empty(mlb)) {
if (ml_empty(mla))
mtx_enter(&mq->mq_mtx);
if (mq_len(mq) < mq->mq_maxlen)
- ml_join(&mq->mq_list, ml);
+ ml_enlist(&mq->mq_list, ml);
else {
dropped = ml_len(ml);
mq->mq_drops += dropped;
-/* $OpenBSD: mbuf.h,v 1.197 2015/10/08 11:36:15 dlg Exp $ */
+/* $OpenBSD: mbuf.h,v 1.198 2015/10/22 05:26:06 dlg Exp $ */
/* $NetBSD: mbuf.h,v 1.19 1996/02/09 18:25:14 christos Exp $ */
/*
void ml_enqueue(struct mbuf_list *, struct mbuf *);
struct mbuf * ml_dequeue(struct mbuf_list *);
void ml_requeue(struct mbuf_list *, struct mbuf *);
+void ml_enlist(struct mbuf_list *, struct mbuf_list *);
struct mbuf * ml_dechain(struct mbuf_list *);
struct mbuf * ml_filter(struct mbuf_list *,
int (*)(void *, const struct mbuf *), void *);