summaryrefslogtreecommitdiffstats
path: root/sys/dev/ti
diff options
context:
space:
mode:
authorglebius <glebius@FreeBSD.org>2012-12-04 09:32:43 +0000
committerglebius <glebius@FreeBSD.org>2012-12-04 09:32:43 +0000
commita69aaa772119d359e38760dd0e931bed9afb88bf (patch)
tree30c414dead3eba042cad7b6cbb32d1c9cba96149 /sys/dev/ti
parent75a08a975ae27f7cf7af6db9f5ee6e87136be40d (diff)
downloadFreeBSD-src-a69aaa772119d359e38760dd0e931bed9afb88bf.zip
FreeBSD-src-a69aaa772119d359e38760dd0e931bed9afb88bf.tar.gz
Mechanically substitute flags from historic mbuf allocator with
malloc(9) flags in sys/dev.
Diffstat (limited to 'sys/dev/ti')
-rw-r--r--sys/dev/ti/if_ti.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/sys/dev/ti/if_ti.c b/sys/dev/ti/if_ti.c
index d31af29..f8142b4 100644
--- a/sys/dev/ti/if_ti.c
+++ b/sys/dev/ti/if_ti.c
@@ -1381,7 +1381,7 @@ ti_newbuf_std(struct ti_softc *sc, int i)
struct ti_rx_desc *r;
int error, nsegs;
- m = m_getcl(M_DONTWAIT, MT_DATA, M_PKTHDR);
+ m = m_getcl(M_NOWAIT, MT_DATA, M_PKTHDR);
if (m == NULL)
return (ENOBUFS);
m->m_len = m->m_pkthdr.len = MCLBYTES;
@@ -1436,7 +1436,7 @@ ti_newbuf_mini(struct ti_softc *sc, int i)
struct ti_rx_desc *r;
int error, nsegs;
- MGETHDR(m, M_DONTWAIT, MT_DATA);
+ MGETHDR(m, M_NOWAIT, MT_DATA);
if (m == NULL)
return (ENOBUFS);
m->m_len = m->m_pkthdr.len = MHLEN;
@@ -1495,7 +1495,7 @@ ti_newbuf_jumbo(struct ti_softc *sc, int i, struct mbuf *dummy)
(void)dummy;
- m = m_getjcl(M_DONTWAIT, MT_DATA, M_PKTHDR, MJUM9BYTES);
+ m = m_getjcl(M_NOWAIT, MT_DATA, M_PKTHDR, MJUM9BYTES);
if (m == NULL)
return (ENOBUFS);
m->m_len = m->m_pkthdr.len = MJUM9BYTES;
@@ -1577,19 +1577,19 @@ ti_newbuf_jumbo(struct ti_softc *sc, int idx, struct mbuf *m_old)
}
} else {
/* Allocate the mbufs. */
- MGETHDR(m_new, M_DONTWAIT, MT_DATA);
+ MGETHDR(m_new, M_NOWAIT, MT_DATA);
if (m_new == NULL) {
device_printf(sc->ti_dev, "mbuf allocation failed "
"-- packet dropped!\n");
goto nobufs;
}
- MGET(m[NPAYLOAD], M_DONTWAIT, MT_DATA);
+ MGET(m[NPAYLOAD], M_NOWAIT, MT_DATA);
if (m[NPAYLOAD] == NULL) {
device_printf(sc->ti_dev, "cluster mbuf allocation "
"failed -- packet dropped!\n");
goto nobufs;
}
- MCLGET(m[NPAYLOAD], M_DONTWAIT);
+ MCLGET(m[NPAYLOAD], M_NOWAIT);
if ((m[NPAYLOAD]->m_flags & M_EXT) == 0) {
device_printf(sc->ti_dev, "mbuf allocation failed "
"-- packet dropped!\n");
@@ -1598,7 +1598,7 @@ ti_newbuf_jumbo(struct ti_softc *sc, int idx, struct mbuf *m_old)
m[NPAYLOAD]->m_len = MCLBYTES;
for (i = 0; i < NPAYLOAD; i++){
- MGET(m[i], M_DONTWAIT, MT_DATA);
+ MGET(m[i], M_NOWAIT, MT_DATA);
if (m[i] == NULL) {
device_printf(sc->ti_dev, "mbuf allocation "
"failed -- packet dropped!\n");
@@ -3051,7 +3051,7 @@ ti_encap(struct ti_softc *sc, struct mbuf **m_head)
error = bus_dmamap_load_mbuf_sg(sc->ti_cdata.ti_tx_tag, txd->tx_dmamap,
*m_head, txsegs, &nseg, 0);
if (error == EFBIG) {
- m = m_defrag(*m_head, M_DONTWAIT);
+ m = m_defrag(*m_head, M_NOWAIT);
if (m == NULL) {
m_freem(*m_head);
*m_head = NULL;
OpenPOWER on IntegriCloud