diff options
author | David Gwynne <dlg@cvs.openbsd.org> | 2015-11-02 09:21:49 +0000 |
---|---|---|
committer | David Gwynne <dlg@cvs.openbsd.org> | 2015-11-02 09:21:49 +0000 |
commit | 0a52a71ed2b0cc46e043d928eec873aebc947244 (patch) | |
tree | 364b1cd1094492187b43506049abbc190f6b35c5 /share/man/man9/mq_init.9 | |
parent | d38f5eb49596b360f93ccf67fe305780aaf44c3e (diff) |
provide ml_purge and mq_purge.
these are modelled on IF_PURGE or IFQ_PURGE. they m_freem all the
mbufs on an mbuf list or queue.
ok jmatthew@ mpi@
Diffstat (limited to 'share/man/man9/mq_init.9')
-rw-r--r-- | share/man/man9/mq_init.9 | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/share/man/man9/mq_init.9 b/share/man/man9/mq_init.9 index e529e7e67c7..ed960f889e6 100644 --- a/share/man/man9/mq_init.9 +++ b/share/man/man9/mq_init.9 @@ -1,4 +1,4 @@ -.\" $OpenBSD: mq_init.9,v 1.4 2015/09/23 12:44:35 dlg Exp $ +.\" $OpenBSD: mq_init.9,v 1.5 2015/11/02 09:21:48 dlg Exp $ .\" .\" Copyright (c) 2015 David Gwynne <dlg@openbsd.org> .\" @@ -14,7 +14,7 @@ .\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF .\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. .\" -.Dd $Mdocdate: September 23 2015 $ +.Dd $Mdocdate: November 2 2015 $ .Dt MQ_INIT 9 .Os .Sh NAME @@ -27,6 +27,7 @@ .Nm mq_dechain , .Nm mq_len , .Nm mq_empty , +.Nm mq_purge , .Nm mq_drops , .Nm mq_set_maxlen , .Nm MBUF_QUEUE_INITIALIZER @@ -58,6 +59,8 @@ .Ft int .Fn mq_empty "struct mbuf_queue *mq" .Ft unsigned int +.Fn mq_purge "struct mbuf_queue *mq" +.Ft unsigned int .Fn mq_drops "struct mbuf_queue *mq" .Ft void .Fn mq_set_maxlen "struct mbuf_queue *mq" "unsigned int" @@ -168,6 +171,10 @@ mbuf queue. Return if the .Fa mq mbuf queue is empty. +.It Fn mq_purge "struct mbuf_queue *mq" +Free all the mbufs on the +.Fa mq +mbuf queue. .It Fn mq_drops "struct mbuf_queue *mq" Return how many mbufs were dropped and freed by .Xr m_freem 9 @@ -193,6 +200,7 @@ already exist on the queue. .Fn mq_dechain , .Fn mq_len , .Fn mq_empty , +.Fn mq_purge , .Fn mq_drops , .Fn mq_set_maxlen , and @@ -238,6 +246,9 @@ length. returns the number of mbufs that were dropped from the list if the length of the queue exceeded its maximum length. .Pp +.Fn mq_purge +returns the number of mbufs that were freed. +.Pp .Fn mq_drops returns the number of mbufs that were freed during .Fn mq_enqueue |