Author: sbruno Date: Wed Jul 19 21:18:04 2017 New Revision: 321253 URL: https://svnweb.freebsd.org/changeset/base/321253
Log: Don't cache mbuf pointers if the number of descriptors is greater than the number of buffers. Submitted by: Matt Macy <mm...@mattmacy.io> Sponsored by: Limelight Networks Modified: head/sys/net/iflib.c Modified: head/sys/net/iflib.c ============================================================================== --- head/sys/net/iflib.c Wed Jul 19 21:06:31 2017 (r321252) +++ head/sys/net/iflib.c Wed Jul 19 21:18:04 2017 (r321253) @@ -2927,6 +2927,14 @@ iflib_busdma_load_mbuf_sg(iflib_txq_t txq, bus_dma_tag m_free(tmp); continue; } + m = m->m_next; + count++; + } while (m != NULL); + if (count > *nsegs) + return (0); + m = *m0; + count = 0; + do { next = (pidx + count) & (ntxd-1); MPASS(ifsd_m[next] == NULL); ifsd_m[next] = m; _______________________________________________ svn-src-head@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"