diff --git a/sys/sys/mbuf.h b/sys/sys/mbuf.h index 59f1dfe1a0e9..39952a92d07d 100644 --- a/sys/sys/mbuf.h +++ b/sys/sys/mbuf.h @@ -1619,6 +1619,12 @@ mbufq_last(const struct mbufq *mq) return (STAILQ_LAST(&mq->mq_head, mbuf, m_stailqpkt)); } +static inline bool +mbufq_empty(const struct mbufq *mq) +{ + return (mq->mq_len == 0); +} + static inline int mbufq_full(const struct mbufq *mq) {