summaryrefslogtreecommitdiffstats
path: root/sys/kern/subr_mbuf.c
diff options
context:
space:
mode:
Diffstat (limited to 'sys/kern/subr_mbuf.c')
-rw-r--r--sys/kern/subr_mbuf.c15
1 files changed, 14 insertions, 1 deletions
diff --git a/sys/kern/subr_mbuf.c b/sys/kern/subr_mbuf.c
index 596319d..7c4ab83 100644
--- a/sys/kern/subr_mbuf.c
+++ b/sys/kern/subr_mbuf.c
@@ -621,9 +621,22 @@ mb_alloc(struct mb_lstmngr *mb_list, int how, short type)
* steal from other lists.
*/
m = mb_alloc_wait(mb_list, type);
- } else
+ } else {
+ /*
+ * no way to indent this code decently
+ * with 8-space tabs.
+ */
+ static int last_report;
/* XXX: No consistency. */
mbstat.m_drops++;
+ if (ticks < last_report ||
+ (ticks - last_report) >= hz) {
+ last_report = ticks;
+ printf(
+"mb_alloc for type %d failed, consider increase mbuf value.\n", type);
+ }
+
+ }
}
}
}
OpenPOWER on IntegriCloud