aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--sys/dev/sf/if_sf.c7
-rw-r--r--sys/dev/sk/if_sk.c5
-rw-r--r--sys/dev/ti/if_ti.c7
-rw-r--r--sys/dev/vr/if_vr.c7
-rw-r--r--sys/pci/if_pcn.c7
-rw-r--r--sys/pci/if_rl.c6
-rw-r--r--sys/pci/if_sf.c7
-rw-r--r--sys/pci/if_sk.c5
-rw-r--r--sys/pci/if_ste.c7
-rw-r--r--sys/pci/if_ti.c7
-rw-r--r--sys/pci/if_tl.c7
-rw-r--r--sys/pci/if_vr.c7
-rw-r--r--sys/pci/if_wb.c11
-rw-r--r--sys/pci/if_xl.c7
14 files changed, 15 insertions, 82 deletions
diff --git a/sys/dev/sf/if_sf.c b/sys/dev/sf/if_sf.c
index 487b48fb9e0c..8ebc2f5bf0ab 100644
--- a/sys/dev/sf/if_sf.c
+++ b/sys/dev/sf/if_sf.c
@@ -908,16 +908,11 @@ static int sf_newbuf(sc, c, m)
if (m == NULL) {
MGETHDR(m_new, M_DONTWAIT, MT_DATA);
- if (m_new == NULL) {
- printf("sf%d: no memory for rx list -- "
- "packet dropped!\n", sc->sf_unit);
+ if (m_new == NULL)
return(ENOBUFS);
- }
MCLGET(m_new, M_DONTWAIT);
if (!(m_new->m_flags & M_EXT)) {
- printf("sf%d: no memory for rx list -- "
- "packet dropped!\n", sc->sf_unit);
m_freem(m_new);
return(ENOBUFS);
}
diff --git a/sys/dev/sk/if_sk.c b/sys/dev/sk/if_sk.c
index 86042095fbb8..5ba23f520826 100644
--- a/sys/dev/sk/if_sk.c
+++ b/sys/dev/sk/if_sk.c
@@ -672,11 +672,8 @@ static int sk_newbuf(sc_if, c, m)
caddr_t *buf = NULL;
MGETHDR(m_new, M_DONTWAIT, MT_DATA);
- if (m_new == NULL) {
- printf("sk%d: no memory for rx list -- "
- "packet dropped!\n", sc_if->sk_unit);
+ if (m_new == NULL)
return(ENOBUFS);
- }
/* Allocate the jumbo buffer */
buf = sk_jalloc(sc_if);
diff --git a/sys/dev/ti/if_ti.c b/sys/dev/ti/if_ti.c
index 98b9b6462e93..106f065f9c9a 100644
--- a/sys/dev/ti/if_ti.c
+++ b/sys/dev/ti/if_ti.c
@@ -700,16 +700,11 @@ static int ti_newbuf_std(sc, i, m)
if (m == NULL) {
MGETHDR(m_new, M_DONTWAIT, MT_DATA);
- if (m_new == NULL) {
- printf("ti%d: mbuf allocation failed "
- "-- packet dropped!\n", sc->ti_unit);
+ if (m_new == NULL)
return(ENOBUFS);
- }
MCLGET(m_new, M_DONTWAIT);
if (!(m_new->m_flags & M_EXT)) {
- printf("ti%d: cluster allocation failed "
- "-- packet dropped!\n", sc->ti_unit);
m_freem(m_new);
return(ENOBUFS);
}
diff --git a/sys/dev/vr/if_vr.c b/sys/dev/vr/if_vr.c
index f03729422211..0956396835ac 100644
--- a/sys/dev/vr/if_vr.c
+++ b/sys/dev/vr/if_vr.c
@@ -924,16 +924,11 @@ static int vr_newbuf(sc, c, m)
if (m == NULL) {
MGETHDR(m_new, M_DONTWAIT, MT_DATA);
- if (m_new == NULL) {
- printf("vr%d: no memory for rx list "
- "-- packet dropped!\n", sc->vr_unit);
+ if (m_new == NULL)
return(ENOBUFS);
- }
MCLGET(m_new, M_DONTWAIT);
if (!(m_new->m_flags & M_EXT)) {
- printf("vr%d: no memory for rx list "
- "-- packet dropped!\n", sc->vr_unit);
m_freem(m_new);
return(ENOBUFS);
}
diff --git a/sys/pci/if_pcn.c b/sys/pci/if_pcn.c
index 580f5e99b5a6..6a177c647cee 100644
--- a/sys/pci/if_pcn.c
+++ b/sys/pci/if_pcn.c
@@ -757,16 +757,11 @@ static int pcn_newbuf(sc, idx, m)
if (m == NULL) {
MGETHDR(m_new, M_DONTWAIT, MT_DATA);
- if (m_new == NULL) {
- printf("pcn%d: no memory for rx list "
- "-- packet dropped!\n", sc->pcn_unit);
+ if (m_new == NULL)
return(ENOBUFS);
- }
MCLGET(m_new, M_DONTWAIT);
if (!(m_new->m_flags & M_EXT)) {
- printf("pcn%d: no memory for rx list "
- "-- packet dropped!\n", sc->pcn_unit);
m_freem(m_new);
return(ENOBUFS);
}
diff --git a/sys/pci/if_rl.c b/sys/pci/if_rl.c
index bc92a0016957..980404f0ba3c 100644
--- a/sys/pci/if_rl.c
+++ b/sys/pci/if_rl.c
@@ -1413,16 +1413,12 @@ static int rl_encap(sc, m_head)
*/
MGETHDR(m_new, M_DONTWAIT, MT_DATA);
- if (m_new == NULL) {
- printf("rl%d: no memory for tx list", sc->rl_unit);
+ if (m_new == NULL)
return(1);
- }
if (m_head->m_pkthdr.len > MHLEN) {
MCLGET(m_new, M_DONTWAIT);
if (!(m_new->m_flags & M_EXT)) {
m_freem(m_new);
- printf("rl%d: no memory for tx list",
- sc->rl_unit);
return(1);
}
}
diff --git a/sys/pci/if_sf.c b/sys/pci/if_sf.c
index 487b48fb9e0c..8ebc2f5bf0ab 100644
--- a/sys/pci/if_sf.c
+++ b/sys/pci/if_sf.c
@@ -908,16 +908,11 @@ static int sf_newbuf(sc, c, m)
if (m == NULL) {
MGETHDR(m_new, M_DONTWAIT, MT_DATA);
- if (m_new == NULL) {
- printf("sf%d: no memory for rx list -- "
- "packet dropped!\n", sc->sf_unit);
+ if (m_new == NULL)
return(ENOBUFS);
- }
MCLGET(m_new, M_DONTWAIT);
if (!(m_new->m_flags & M_EXT)) {
- printf("sf%d: no memory for rx list -- "
- "packet dropped!\n", sc->sf_unit);
m_freem(m_new);
return(ENOBUFS);
}
diff --git a/sys/pci/if_sk.c b/sys/pci/if_sk.c
index 86042095fbb8..5ba23f520826 100644
--- a/sys/pci/if_sk.c
+++ b/sys/pci/if_sk.c
@@ -672,11 +672,8 @@ static int sk_newbuf(sc_if, c, m)
caddr_t *buf = NULL;
MGETHDR(m_new, M_DONTWAIT, MT_DATA);
- if (m_new == NULL) {
- printf("sk%d: no memory for rx list -- "
- "packet dropped!\n", sc_if->sk_unit);
+ if (m_new == NULL)
return(ENOBUFS);
- }
/* Allocate the jumbo buffer */
buf = sk_jalloc(sc_if);
diff --git a/sys/pci/if_ste.c b/sys/pci/if_ste.c
index 554b070f0055..4088a605c87e 100644
--- a/sys/pci/if_ste.c
+++ b/sys/pci/if_ste.c
@@ -1117,15 +1117,10 @@ static int ste_newbuf(sc, c, m)
if (m == NULL) {
MGETHDR(m_new, M_DONTWAIT, MT_DATA);
- if (m_new == NULL) {
- printf("ste%d: no memory for rx list -- "
- "packet dropped\n", sc->ste_unit);
+ if (m_new == NULL)
return(ENOBUFS);
- }
MCLGET(m_new, M_DONTWAIT);
if (!(m_new->m_flags & M_EXT)) {
- printf("ste%d: no memory for rx list -- "
- "packet dropped\n", sc->ste_unit);
m_freem(m_new);
return(ENOBUFS);
}
diff --git a/sys/pci/if_ti.c b/sys/pci/if_ti.c
index 98b9b6462e93..106f065f9c9a 100644
--- a/sys/pci/if_ti.c
+++ b/sys/pci/if_ti.c
@@ -700,16 +700,11 @@ static int ti_newbuf_std(sc, i, m)
if (m == NULL) {
MGETHDR(m_new, M_DONTWAIT, MT_DATA);
- if (m_new == NULL) {
- printf("ti%d: mbuf allocation failed "
- "-- packet dropped!\n", sc->ti_unit);
+ if (m_new == NULL)
return(ENOBUFS);
- }
MCLGET(m_new, M_DONTWAIT);
if (!(m_new->m_flags & M_EXT)) {
- printf("ti%d: cluster allocation failed "
- "-- packet dropped!\n", sc->ti_unit);
m_freem(m_new);
return(ENOBUFS);
}
diff --git a/sys/pci/if_tl.c b/sys/pci/if_tl.c
index de4f82221754..8bc0827a5571 100644
--- a/sys/pci/if_tl.c
+++ b/sys/pci/if_tl.c
@@ -1439,16 +1439,11 @@ static int tl_newbuf(sc, c)
struct mbuf *m_new = NULL;
MGETHDR(m_new, M_DONTWAIT, MT_DATA);
- if (m_new == NULL) {
- printf("tl%d: no memory for rx list -- packet dropped!\n",
- sc->tl_unit);
+ if (m_new == NULL)
return(ENOBUFS);
- }
MCLGET(m_new, M_DONTWAIT);
if (!(m_new->m_flags & M_EXT)) {
- printf("tl%d: no memory for rx list -- packet dropped!\n",
- sc->tl_unit);
m_freem(m_new);
return(ENOBUFS);
}
diff --git a/sys/pci/if_vr.c b/sys/pci/if_vr.c
index f03729422211..0956396835ac 100644
--- a/sys/pci/if_vr.c
+++ b/sys/pci/if_vr.c
@@ -924,16 +924,11 @@ static int vr_newbuf(sc, c, m)
if (m == NULL) {
MGETHDR(m_new, M_DONTWAIT, MT_DATA);
- if (m_new == NULL) {
- printf("vr%d: no memory for rx list "
- "-- packet dropped!\n", sc->vr_unit);
+ if (m_new == NULL)
return(ENOBUFS);
- }
MCLGET(m_new, M_DONTWAIT);
if (!(m_new->m_flags & M_EXT)) {
- printf("vr%d: no memory for rx list "
- "-- packet dropped!\n", sc->vr_unit);
m_freem(m_new);
return(ENOBUFS);
}
diff --git a/sys/pci/if_wb.c b/sys/pci/if_wb.c
index be60876627c3..cd1d43f6b3d1 100644
--- a/sys/pci/if_wb.c
+++ b/sys/pci/if_wb.c
@@ -1092,11 +1092,8 @@ static int wb_newbuf(sc, c, m)
if (m == NULL) {
MGETHDR(m_new, M_DONTWAIT, MT_DATA);
- if (m_new == NULL) {
- printf("wb%d: no memory for rx "
- "list -- packet dropped!\n", sc->wb_unit);
+ if (m_new == NULL)
return(ENOBUFS);
- }
m_new->m_data = c->wb_buf;
m_new->m_pkthdr.len = m_new->m_len = WB_BUFBYTES;
MEXTADD(m_new, c->wb_buf, WB_BUFBYTES, wb_bfree, NULL, 0,
@@ -1448,16 +1445,12 @@ static int wb_encap(sc, c, m_head)
struct mbuf *m_new = NULL;
MGETHDR(m_new, M_DONTWAIT, MT_DATA);
- if (m_new == NULL) {
- printf("wb%d: no memory for tx list", sc->wb_unit);
+ if (m_new == NULL)
return(1);
- }
if (m_head->m_pkthdr.len > MHLEN) {
MCLGET(m_new, M_DONTWAIT);
if (!(m_new->m_flags & M_EXT)) {
m_freem(m_new);
- printf("wb%d: no memory for tx list",
- sc->wb_unit);
return(1);
}
}
diff --git a/sys/pci/if_xl.c b/sys/pci/if_xl.c
index 7378d83870ca..aa7f4fc1e42d 100644
--- a/sys/pci/if_xl.c
+++ b/sys/pci/if_xl.c
@@ -1780,16 +1780,11 @@ static int xl_newbuf(sc, c)
struct mbuf *m_new = NULL;
MGETHDR(m_new, M_DONTWAIT, MT_DATA);
- if (m_new == NULL) {
- printf("xl%d: no memory for rx list -- "
- "packet dropped!\n", sc->xl_unit);
+ if (m_new == NULL)
return(ENOBUFS);
- }
MCLGET(m_new, M_DONTWAIT);
if (!(m_new->m_flags & M_EXT)) {
- printf("xl%d: no memory for rx list -- "
- "packet dropped!\n", sc->xl_unit);
m_freem(m_new);
return(ENOBUFS);
}