Allow mbuf queues to be unlimited.

There is number of legacy code that uses ifqueue without setting
a limit on it first. Easier to allow for that rather than improve
legacy drivers.
This commit is contained in:
Gleb Smirnoff 2019-08-30 00:03:41 +00:00
parent 7d5b071384
commit b2005c033e

View File

@ -1434,7 +1434,7 @@ static inline int
mbufq_full(const struct mbufq *mq)
{
return (mq->mq_len >= mq->mq_maxlen);
return (mq->mq_maxlen > 0 && mq->mq_len >= mq->mq_maxlen);
}
static inline int