summaryrefslogtreecommitdiffstats
path: root/sys/netgraph
diff options
context:
space:
mode:
authorglebius <glebius@FreeBSD.org>2012-12-05 08:04:20 +0000
committerglebius <glebius@FreeBSD.org>2012-12-05 08:04:20 +0000
commit8e20fa5ae93243e19700ca06c01524b90fe3b784 (patch)
treebf083a0829f8044362fc83354c8e8b60d1f7932a /sys/netgraph
parentd0604243f84872a5dd39fc735ebcdb4fbe1b6bb5 (diff)
downloadFreeBSD-src-8e20fa5ae93243e19700ca06c01524b90fe3b784.zip
FreeBSD-src-8e20fa5ae93243e19700ca06c01524b90fe3b784.tar.gz
Mechanically substitute flags from historic mbuf allocator with
malloc(9) flags within sys. Exceptions: - sys/contrib not touched - sys/mbuf.h edited manually
Diffstat (limited to 'sys/netgraph')
-rw-r--r--sys/netgraph/atm/ccatm/ng_ccatm.c4
-rw-r--r--sys/netgraph/atm/ng_atm.c6
-rw-r--r--sys/netgraph/bluetooth/drivers/bt3c/ng_bt3c_pccard.c4
-rw-r--r--sys/netgraph/bluetooth/drivers/h4/ng_h4.c2
-rw-r--r--sys/netgraph/bluetooth/drivers/ubt/ng_ubt.c12
-rw-r--r--sys/netgraph/bluetooth/hci/ng_hci_cmds.c2
-rw-r--r--sys/netgraph/bluetooth/hci/ng_hci_evnt.c2
-rw-r--r--sys/netgraph/bluetooth/hci/ng_hci_misc.c2
-rw-r--r--sys/netgraph/bluetooth/hci/ng_hci_ulpi.c10
-rw-r--r--sys/netgraph/bluetooth/l2cap/ng_l2cap_cmds.h22
-rw-r--r--sys/netgraph/bluetooth/l2cap/ng_l2cap_evnt.c2
-rw-r--r--sys/netgraph/bluetooth/l2cap/ng_l2cap_llpi.c2
-rw-r--r--sys/netgraph/bluetooth/l2cap/ng_l2cap_misc.c2
-rw-r--r--sys/netgraph/bluetooth/socket/ng_btsocket_hci_raw.c6
-rw-r--r--sys/netgraph/bluetooth/socket/ng_btsocket_l2cap.c6
-rw-r--r--sys/netgraph/bluetooth/socket/ng_btsocket_rfcomm.c14
-rw-r--r--sys/netgraph/bluetooth/socket/ng_btsocket_sco.c4
-rw-r--r--sys/netgraph/netflow/netflow.c2
-rw-r--r--sys/netgraph/netflow/netflow_v9.c2
-rw-r--r--sys/netgraph/ng_UI.c2
-rw-r--r--sys/netgraph/ng_atmllc.c4
-rw-r--r--sys/netgraph/ng_bridge.c2
-rw-r--r--sys/netgraph/ng_cisco.c4
-rw-r--r--sys/netgraph/ng_deflate.c4
-rw-r--r--sys/netgraph/ng_device.c2
-rw-r--r--sys/netgraph/ng_frame_relay.c2
-rw-r--r--sys/netgraph/ng_gif.c2
-rw-r--r--sys/netgraph/ng_gif_demux.c2
-rw-r--r--sys/netgraph/ng_hub.c2
-rw-r--r--sys/netgraph/ng_iface.c2
-rw-r--r--sys/netgraph/ng_ipfw.c2
-rw-r--r--sys/netgraph/ng_l2tp.c14
-rw-r--r--sys/netgraph/ng_lmi.c2
-rw-r--r--sys/netgraph/ng_mppc.c6
-rw-r--r--sys/netgraph/ng_one2many.c2
-rw-r--r--sys/netgraph/ng_ppp.c6
-rw-r--r--sys/netgraph/ng_pppoe.c20
-rw-r--r--sys/netgraph/ng_pptpgre.c4
-rw-r--r--sys/netgraph/ng_pred1.c4
-rw-r--r--sys/netgraph/ng_rfc1490.c10
-rw-r--r--sys/netgraph/ng_source.c8
-rw-r--r--sys/netgraph/ng_tee.c2
-rw-r--r--sys/netgraph/ng_tty.c4
-rw-r--r--sys/netgraph/ng_vjc.c4
-rw-r--r--sys/netgraph/ng_vlan.c2
45 files changed, 112 insertions, 112 deletions
diff --git a/sys/netgraph/atm/ccatm/ng_ccatm.c b/sys/netgraph/atm/ccatm/ng_ccatm.c
index a6ff474..cdbc86f 100644
--- a/sys/netgraph/atm/ccatm/ng_ccatm.c
+++ b/sys/netgraph/atm/ccatm/ng_ccatm.c
@@ -434,13 +434,13 @@ send_dump(struct ccdata *data, void *uarg, const char *buf)
struct ccnode *priv = uarg;
if (priv->dump == NULL) {
- m = m_getcl(M_DONTWAIT, MT_DATA, M_PKTHDR);
+ m = m_getcl(M_NOWAIT, MT_DATA, M_PKTHDR);
if (m == NULL)
return (ENOBUFS);
priv->dump_first = priv->dump_last = m;
m->m_pkthdr.len = 0;
} else {
- m = m_getcl(M_DONTWAIT, MT_DATA, 0);
+ m = m_getcl(M_NOWAIT, MT_DATA, 0);
if (m == 0) {
m_freem(priv->dump_first);
return (ENOBUFS);
diff --git a/sys/netgraph/atm/ng_atm.c b/sys/netgraph/atm/ng_atm.c
index 32bde57..ef168ac 100644
--- a/sys/netgraph/atm/ng_atm.c
+++ b/sys/netgraph/atm/ng_atm.c
@@ -384,7 +384,7 @@ ng_atm_input(struct ifnet *ifp, struct mbuf **mp,
/*
* Prepend the atm_pseudoheader.
*/
- M_PREPEND(*mp, sizeof(*ah), M_DONTWAIT);
+ M_PREPEND(*mp, sizeof(*ah), M_NOWAIT);
if (*mp == NULL)
return;
memcpy(mtod(*mp, struct atm_pseudohdr *), ah, sizeof(*ah));
@@ -462,7 +462,7 @@ ng_atm_input_orphans(struct ifnet *ifp, struct mbuf *m,
/*
* Prepend the atm_pseudoheader.
*/
- M_PREPEND(m, sizeof(*ah), M_DONTWAIT);
+ M_PREPEND(m, sizeof(*ah), M_NOWAIT);
if (m == NULL)
return;
memcpy(mtod(m, struct atm_pseudohdr *), ah, sizeof(*ah));
@@ -502,7 +502,7 @@ ng_atm_rcvdata(hook_p hook, item_p item)
/*
* Prepend pseudo-hdr. Drivers don't care about the flags.
*/
- M_PREPEND(m, sizeof(*aph), M_DONTWAIT);
+ M_PREPEND(m, sizeof(*aph), M_NOWAIT);
if (m == NULL) {
NG_FREE_M(m);
return (ENOMEM);
diff --git a/sys/netgraph/bluetooth/drivers/bt3c/ng_bt3c_pccard.c b/sys/netgraph/bluetooth/drivers/bt3c/ng_bt3c_pccard.c
index b244b30..f2930ab 100644
--- a/sys/netgraph/bluetooth/drivers/bt3c/ng_bt3c_pccard.c
+++ b/sys/netgraph/bluetooth/drivers/bt3c/ng_bt3c_pccard.c
@@ -807,7 +807,7 @@ bt3c_receive(bt3c_softc_p sc)
sc->state = NG_BT3C_W4_PKT_IND;
sc->want = 1;
- MGETHDR(sc->m, M_DONTWAIT, MT_DATA);
+ MGETHDR(sc->m, M_NOWAIT, MT_DATA);
if (sc->m == NULL) {
NG_BT3C_ERR(sc->dev, "Could not get mbuf\n");
NG_BT3C_STAT_IERROR(sc->stat);
@@ -815,7 +815,7 @@ bt3c_receive(bt3c_softc_p sc)
break; /* XXX lost of sync */
}
- MCLGET(sc->m, M_DONTWAIT);
+ MCLGET(sc->m, M_NOWAIT);
if (!(sc->m->m_flags & M_EXT)) {
NG_FREE_M(sc->m);
diff --git a/sys/netgraph/bluetooth/drivers/h4/ng_h4.c b/sys/netgraph/bluetooth/drivers/h4/ng_h4.c
index 2bf1717..97cee2e 100644
--- a/sys/netgraph/bluetooth/drivers/h4/ng_h4.c
+++ b/sys/netgraph/bluetooth/drivers/h4/ng_h4.c
@@ -525,7 +525,7 @@ ng_h4_input(int c, struct tty *tp)
if (sc->hook != NULL && NG_HOOK_IS_VALID(sc->hook)) {
struct mbuf *m = NULL;
- MGETHDR(m, M_DONTWAIT, MT_DATA);
+ MGETHDR(m, M_NOWAIT, MT_DATA);
if (m != NULL) {
m->m_pkthdr.len = 0;
diff --git a/sys/netgraph/bluetooth/drivers/ubt/ng_ubt.c b/sys/netgraph/bluetooth/drivers/ubt/ng_ubt.c
index 44654d2..6de270f 100644
--- a/sys/netgraph/bluetooth/drivers/ubt/ng_ubt.c
+++ b/sys/netgraph/bluetooth/drivers/ubt/ng_ubt.c
@@ -710,13 +710,13 @@ ubt_intr_read_callback(struct usb_xfer *xfer, usb_error_t error)
switch (USB_GET_STATE(xfer)) {
case USB_ST_TRANSFERRED:
/* Allocate a new mbuf */
- MGETHDR(m, M_DONTWAIT, MT_DATA);
+ MGETHDR(m, M_NOWAIT, MT_DATA);
if (m == NULL) {
UBT_STAT_IERROR(sc);
goto submit_next;
}
- MCLGET(m, M_DONTWAIT);
+ MCLGET(m, M_NOWAIT);
if (!(m->m_flags & M_EXT)) {
UBT_STAT_IERROR(sc);
goto submit_next;
@@ -810,13 +810,13 @@ ubt_bulk_read_callback(struct usb_xfer *xfer, usb_error_t error)
switch (USB_GET_STATE(xfer)) {
case USB_ST_TRANSFERRED:
/* Allocate new mbuf */
- MGETHDR(m, M_DONTWAIT, MT_DATA);
+ MGETHDR(m, M_NOWAIT, MT_DATA);
if (m == NULL) {
UBT_STAT_IERROR(sc);
goto submit_next;
}
- MCLGET(m, M_DONTWAIT);
+ MCLGET(m, M_NOWAIT);
if (!(m->m_flags & M_EXT)) {
UBT_STAT_IERROR(sc);
goto submit_next;
@@ -1020,13 +1020,13 @@ ubt_isoc_read_one_frame(struct usb_xfer *xfer, int frame_no)
while (total > 0) {
if (m == NULL) {
/* Start new reassembly buffer */
- MGETHDR(m, M_DONTWAIT, MT_DATA);
+ MGETHDR(m, M_NOWAIT, MT_DATA);
if (m == NULL) {
UBT_STAT_IERROR(sc);
return (-1); /* XXX out of sync! */
}
- MCLGET(m, M_DONTWAIT);
+ MCLGET(m, M_NOWAIT);
if (!(m->m_flags & M_EXT)) {
UBT_STAT_IERROR(sc);
NG_FREE_M(m);
diff --git a/sys/netgraph/bluetooth/hci/ng_hci_cmds.c b/sys/netgraph/bluetooth/hci/ng_hci_cmds.c
index 8d630a2..1dc9854 100644
--- a/sys/netgraph/bluetooth/hci/ng_hci_cmds.c
+++ b/sys/netgraph/bluetooth/hci/ng_hci_cmds.c
@@ -118,7 +118,7 @@ ng_hci_send_command(ng_hci_unit_p unit)
ng_hci_mtap(unit, m0);
- m = m_dup(m0, M_DONTWAIT);
+ m = m_dup(m0, M_NOWAIT);
if (m != NULL)
NG_SEND_DATA_ONLY(error, unit->drv, m);
else
diff --git a/sys/netgraph/bluetooth/hci/ng_hci_evnt.c b/sys/netgraph/bluetooth/hci/ng_hci_evnt.c
index a4cc9ba..b8dd21f 100644
--- a/sys/netgraph/bluetooth/hci/ng_hci_evnt.c
+++ b/sys/netgraph/bluetooth/hci/ng_hci_evnt.c
@@ -511,7 +511,7 @@ con_compl(ng_hci_unit_p unit, struct mbuf *event)
} __attribute__ ((packed)) *lp;
struct mbuf *m;
- MGETHDR(m, M_DONTWAIT, MT_DATA);
+ MGETHDR(m, M_NOWAIT, MT_DATA);
if (m != NULL) {
m->m_pkthdr.len = m->m_len = sizeof(*lp);
lp = mtod(m, struct __link_policy *);
diff --git a/sys/netgraph/bluetooth/hci/ng_hci_misc.c b/sys/netgraph/bluetooth/hci/ng_hci_misc.c
index 252a580..2209fbd 100644
--- a/sys/netgraph/bluetooth/hci/ng_hci_misc.c
+++ b/sys/netgraph/bluetooth/hci/ng_hci_misc.c
@@ -65,7 +65,7 @@ ng_hci_mtap(ng_hci_unit_p unit, struct mbuf *m0)
int error = 0;
if (unit->raw != NULL && NG_HOOK_IS_VALID(unit->raw)) {
- m = m_dup(m0, M_DONTWAIT);
+ m = m_dup(m0, M_NOWAIT);
if (m != NULL)
NG_SEND_DATA_ONLY(error, unit->raw, m);
diff --git a/sys/netgraph/bluetooth/hci/ng_hci_ulpi.c b/sys/netgraph/bluetooth/hci/ng_hci_ulpi.c
index 311bd4f..4c06c07 100644
--- a/sys/netgraph/bluetooth/hci/ng_hci_ulpi.c
+++ b/sys/netgraph/bluetooth/hci/ng_hci_ulpi.c
@@ -224,7 +224,7 @@ ng_hci_lp_acl_con_req(ng_hci_unit_p unit, item_p item, hook_p hook)
* Create HCI command
*/
- MGETHDR(m, M_DONTWAIT, MT_DATA);
+ MGETHDR(m, M_NOWAIT, MT_DATA);
if (m == NULL) {
ng_hci_free_con(con);
error = ENOBUFS;
@@ -417,7 +417,7 @@ ng_hci_lp_sco_con_req(ng_hci_unit_p unit, item_p item, hook_p hook)
* Create HCI command
*/
- MGETHDR(m, M_DONTWAIT, MT_DATA);
+ MGETHDR(m, M_NOWAIT, MT_DATA);
if (m == NULL) {
ng_hci_free_con(sco_con);
error = ENOBUFS;
@@ -531,7 +531,7 @@ ng_hci_lp_discon_req(ng_hci_unit_p unit, item_p item, hook_p hook)
* Create HCI command
*/
- MGETHDR(m, M_DONTWAIT, MT_DATA);
+ MGETHDR(m, M_NOWAIT, MT_DATA);
if (m == NULL) {
error = ENOBUFS;
goto out;
@@ -776,7 +776,7 @@ ng_hci_lp_con_rsp(ng_hci_unit_p unit, item_p item, hook_p hook)
* Create HCI command
*/
- MGETHDR(m, M_DONTWAIT, MT_DATA);
+ MGETHDR(m, M_NOWAIT, MT_DATA);
if (m == NULL) {
error = ENOBUFS;
goto out;
@@ -996,7 +996,7 @@ ng_hci_lp_qos_req(ng_hci_unit_p unit, item_p item, hook_p hook)
* Create HCI command
*/
- MGETHDR(m, M_DONTWAIT, MT_DATA);
+ MGETHDR(m, M_NOWAIT, MT_DATA);
if (m == NULL) {
error = ENOBUFS;
goto out;
diff --git a/sys/netgraph/bluetooth/l2cap/ng_l2cap_cmds.h b/sys/netgraph/bluetooth/l2cap/ng_l2cap_cmds.h
index ed225c8..52789a1 100644
--- a/sys/netgraph/bluetooth/l2cap/ng_l2cap_cmds.h
+++ b/sys/netgraph/bluetooth/l2cap/ng_l2cap_cmds.h
@@ -56,7 +56,7 @@ do { \
ng_l2cap_cmd_rej_data_t data; \
} __attribute__ ((packed)) *c = NULL; \
\
- MGETHDR((_m), M_DONTWAIT, MT_DATA); \
+ MGETHDR((_m), M_NOWAIT, MT_DATA); \
if ((_m) == NULL) \
break; \
\
@@ -90,7 +90,7 @@ do { \
ng_l2cap_con_req_cp param; \
} __attribute__ ((packed)) *c = NULL; \
\
- MGETHDR((_m), M_DONTWAIT, MT_DATA); \
+ MGETHDR((_m), M_NOWAIT, MT_DATA); \
if ((_m) == NULL) \
break; \
\
@@ -113,7 +113,7 @@ do { \
ng_l2cap_con_rsp_cp param; \
} __attribute__ ((packed)) *c = NULL; \
\
- MGETHDR((_m), M_DONTWAIT, MT_DATA); \
+ MGETHDR((_m), M_NOWAIT, MT_DATA); \
if ((_m) == NULL) \
break; \
\
@@ -138,7 +138,7 @@ do { \
ng_l2cap_cfg_req_cp param; \
} __attribute__ ((packed)) *c = NULL; \
\
- MGETHDR((_m), M_DONTWAIT, MT_DATA); \
+ MGETHDR((_m), M_NOWAIT, MT_DATA); \
if ((_m) == NULL) { \
NG_FREE_M((_data)); \
break; \
@@ -172,7 +172,7 @@ do { \
ng_l2cap_cfg_rsp_cp param; \
} __attribute__ ((packed)) *c = NULL; \
\
- MGETHDR((_m), M_DONTWAIT, MT_DATA); \
+ MGETHDR((_m), M_NOWAIT, MT_DATA); \
if ((_m) == NULL) { \
NG_FREE_M((_data)); \
break; \
@@ -204,7 +204,7 @@ do { \
do { \
u_int8_t *p = NULL; \
\
- MGETHDR((_m), M_DONTWAIT, MT_DATA); \
+ MGETHDR((_m), M_NOWAIT, MT_DATA); \
if ((_m) == NULL) \
break; \
\
@@ -281,7 +281,7 @@ do { \
ng_l2cap_discon_req_cp param; \
} __attribute__ ((packed)) *c = NULL; \
\
- MGETHDR((_m), M_DONTWAIT, MT_DATA); \
+ MGETHDR((_m), M_NOWAIT, MT_DATA); \
if ((_m) == NULL) \
break; \
\
@@ -304,7 +304,7 @@ do { \
ng_l2cap_discon_rsp_cp param; \
} __attribute__ ((packed)) *c = NULL; \
\
- MGETHDR((_m), M_DONTWAIT, MT_DATA); \
+ MGETHDR((_m), M_NOWAIT, MT_DATA); \
if ((_m) == NULL) \
break; \
\
@@ -324,7 +324,7 @@ do { \
do { \
ng_l2cap_cmd_hdr_t *c = NULL; \
\
- MGETHDR((_m), M_DONTWAIT, MT_DATA); \
+ MGETHDR((_m), M_NOWAIT, MT_DATA); \
if ((_m) == NULL) \
break; \
\
@@ -351,7 +351,7 @@ do { \
ng_l2cap_info_req_cp param; \
} __attribute__ ((packed)) *c = NULL; \
\
- MGETHDR((_m), M_DONTWAIT, MT_DATA); \
+ MGETHDR((_m), M_NOWAIT, MT_DATA); \
if ((_m) == NULL) \
break; \
\
@@ -374,7 +374,7 @@ do { \
ng_l2cap_info_rsp_data_t data; \
} __attribute__ ((packed)) *c = NULL; \
\
- MGETHDR((_m), M_DONTWAIT, MT_DATA); \
+ MGETHDR((_m), M_NOWAIT, MT_DATA); \
if ((_m) == NULL) \
break; \
\
diff --git a/sys/netgraph/bluetooth/l2cap/ng_l2cap_evnt.c b/sys/netgraph/bluetooth/l2cap/ng_l2cap_evnt.c
index 9d5268e..747b74c 100644
--- a/sys/netgraph/bluetooth/l2cap/ng_l2cap_evnt.c
+++ b/sys/netgraph/bluetooth/l2cap/ng_l2cap_evnt.c
@@ -192,7 +192,7 @@ ng_l2cap_process_signal_cmd(ng_l2cap_con_p con)
/* Get the command, save the rest (if any) */
if (con->rx_pkt->m_pkthdr.len > hdr->length)
- m = m_split(con->rx_pkt, hdr->length, M_DONTWAIT);
+ m = m_split(con->rx_pkt, hdr->length, M_NOWAIT);
else
m = NULL;
diff --git a/sys/netgraph/bluetooth/l2cap/ng_l2cap_llpi.c b/sys/netgraph/bluetooth/l2cap/ng_l2cap_llpi.c
index 923ecfc..704e74a 100644
--- a/sys/netgraph/bluetooth/l2cap/ng_l2cap_llpi.c
+++ b/sys/netgraph/bluetooth/l2cap/ng_l2cap_llpi.c
@@ -528,7 +528,7 @@ ng_l2cap_lp_send(ng_l2cap_con_p con, u_int16_t dcid, struct mbuf *m0)
/* Check length of the packet against HCI MTU */
len = m0->m_pkthdr.len;
if (len > l2cap->pkt_size) {
- m = m_split(m0, l2cap->pkt_size, M_DONTWAIT);
+ m = m_split(m0, l2cap->pkt_size, M_NOWAIT);
if (m == NULL) {
NG_L2CAP_ALERT(
"%s: %s - m_split(%d) failed\n", __func__, NG_NODE_NAME(l2cap->node),
diff --git a/sys/netgraph/bluetooth/l2cap/ng_l2cap_misc.c b/sys/netgraph/bluetooth/l2cap/ng_l2cap_misc.c
index 3791dcd..0c3f1d0 100644
--- a/sys/netgraph/bluetooth/l2cap/ng_l2cap_misc.c
+++ b/sys/netgraph/bluetooth/l2cap/ng_l2cap_misc.c
@@ -558,7 +558,7 @@ ng_l2cap_command_untimeout(ng_l2cap_cmd_p cmd)
struct mbuf *
ng_l2cap_prepend(struct mbuf *m, int size)
{
- M_PREPEND(m, size, M_DONTWAIT);
+ M_PREPEND(m, size, M_NOWAIT);
if (m == NULL || (m->m_len < size && (m = m_pullup(m, size)) == NULL))
return (NULL);
diff --git a/sys/netgraph/bluetooth/socket/ng_btsocket_hci_raw.c b/sys/netgraph/bluetooth/socket/ng_btsocket_hci_raw.c
index df18913..35cd766 100644
--- a/sys/netgraph/bluetooth/socket/ng_btsocket_hci_raw.c
+++ b/sys/netgraph/bluetooth/socket/ng_btsocket_hci_raw.c
@@ -310,7 +310,7 @@ ng_btsocket_hci_raw_node_rcvdata(hook_p hook, item_p item)
* for now
*/
- MGET(nam, M_DONTWAIT, MT_SONAME);
+ MGET(nam, M_NOWAIT, MT_SONAME);
if (nam != NULL) {
struct sockaddr_hci *sa = mtod(nam, struct sockaddr_hci *);
@@ -519,7 +519,7 @@ ng_btsocket_hci_raw_data_input(struct mbuf *nam)
* will check if socket has enough buffer space.
*/
- m = m_dup(m0, M_DONTWAIT);
+ m = m_dup(m0, M_NOWAIT);
if (m != NULL) {
struct mbuf *ctl = NULL;
@@ -1585,7 +1585,7 @@ ng_btsocket_hci_raw_send(struct socket *so, int flags, struct mbuf *m,
sa = (struct sockaddr *) &pcb->addr;
}
- MGET(nam, M_DONTWAIT, MT_SONAME);
+ MGET(nam, M_NOWAIT, MT_SONAME);
if (nam == NULL) {
mtx_unlock(&pcb->pcb_mtx);
error = ENOBUFS;
diff --git a/sys/netgraph/bluetooth/socket/ng_btsocket_l2cap.c b/sys/netgraph/bluetooth/socket/ng_btsocket_l2cap.c
index 0066a85..9934945 100644
--- a/sys/netgraph/bluetooth/socket/ng_btsocket_l2cap.c
+++ b/sys/netgraph/bluetooth/socket/ng_btsocket_l2cap.c
@@ -1533,7 +1533,7 @@ ng_btsocket_l2cap_data_input(struct mbuf *m, hook_p hook)
* it is a broadcast traffic after all
*/
- copy = m_dup(m, M_DONTWAIT);
+ copy = m_dup(m, M_NOWAIT);
if (copy != NULL) {
sbappendrecord(&pcb->so->so_rcv, copy);
sorwakeup(pcb->so);
@@ -2513,12 +2513,12 @@ ng_btsocket_l2cap_send2(ng_btsocket_l2cap_pcb_p pcb)
if (pcb->so->so_snd.sb_cc == 0)
return (EINVAL); /* XXX */
- m = m_dup(pcb->so->so_snd.sb_mb, M_DONTWAIT);
+ m = m_dup(pcb->so->so_snd.sb_mb, M_NOWAIT);
if (m == NULL)
return (ENOBUFS);
/* Create L2CA packet header */
- M_PREPEND(m, sizeof(*hdr), M_DONTWAIT);
+ M_PREPEND(m, sizeof(*hdr), M_NOWAIT);
if (m != NULL)
if (m->m_len < sizeof(*hdr))
m = m_pullup(m, sizeof(*hdr));
diff --git a/sys/netgraph/bluetooth/socket/ng_btsocket_rfcomm.c b/sys/netgraph/bluetooth/socket/ng_btsocket_rfcomm.c
index a0e266e..0ffc12e 100644
--- a/sys/netgraph/bluetooth/socket/ng_btsocket_rfcomm.c
+++ b/sys/netgraph/bluetooth/socket/ng_btsocket_rfcomm.c
@@ -3005,7 +3005,7 @@ ng_btsocket_rfcomm_send_command(ng_btsocket_rfcomm_session_p s,
/* NOT REACHED */
}
- MGETHDR(m, M_DONTWAIT, MT_DATA);
+ MGETHDR(m, M_NOWAIT, MT_DATA);
if (m == NULL)
return (ENOBUFS);
@@ -3036,14 +3036,14 @@ ng_btsocket_rfcomm_send_uih(ng_btsocket_rfcomm_session_p s, u_int8_t address,
mtx_assert(&s->session_mtx, MA_OWNED);
- MGETHDR(m, M_DONTWAIT, MT_DATA);
+ MGETHDR(m, M_NOWAIT, MT_DATA);
if (m == NULL) {
NG_FREE_M(data);
return (ENOBUFS);
}
m->m_pkthdr.len = m->m_len = sizeof(*hdr);
- MGET(mcrc, M_DONTWAIT, MT_DATA);
+ MGET(mcrc, M_NOWAIT, MT_DATA);
if (mcrc == NULL) {
NG_FREE_M(data);
return (ENOBUFS);
@@ -3110,7 +3110,7 @@ ng_btsocket_rfcomm_send_msc(ng_btsocket_rfcomm_pcb_p pcb)
mtx_assert(&pcb->session->session_mtx, MA_OWNED);
mtx_assert(&pcb->pcb_mtx, MA_OWNED);
- MGETHDR(m, M_DONTWAIT, MT_DATA);
+ MGETHDR(m, M_NOWAIT, MT_DATA);
if (m == NULL)
return (ENOBUFS);
@@ -3148,7 +3148,7 @@ ng_btsocket_rfcomm_send_pn(ng_btsocket_rfcomm_pcb_p pcb)
mtx_assert(&pcb->session->session_mtx, MA_OWNED);
mtx_assert(&pcb->pcb_mtx, MA_OWNED);
- MGETHDR(m, M_DONTWAIT, MT_DATA);
+ MGETHDR(m, M_NOWAIT, MT_DATA);
if (m == NULL)
return (ENOBUFS);
@@ -3519,7 +3519,7 @@ ng_btsocket_rfcomm_prepare_packet(struct sockbuf *sb, int length)
struct mbuf *top = NULL, *m = NULL, *n = NULL, *nextpkt = NULL;
int mlen, noff, len;
- MGETHDR(top, M_DONTWAIT, MT_DATA);
+ MGETHDR(top, M_NOWAIT, MT_DATA);
if (top == NULL)
return (NULL);
@@ -3543,7 +3543,7 @@ ng_btsocket_rfcomm_prepare_packet(struct sockbuf *sb, int length)
length -= len;
if (length > 0 && m->m_len == mlen) {
- MGET(m->m_next, M_DONTWAIT, MT_DATA);
+ MGET(m->m_next, M_NOWAIT, MT_DATA);
if (m->m_next == NULL) {
NG_FREE_M(top);
return (NULL);
diff --git a/sys/netgraph/bluetooth/socket/ng_btsocket_sco.c b/sys/netgraph/bluetooth/socket/ng_btsocket_sco.c
index 12786fa..7727d7c 100644
--- a/sys/netgraph/bluetooth/socket/ng_btsocket_sco.c
+++ b/sys/netgraph/bluetooth/socket/ng_btsocket_sco.c
@@ -1746,14 +1746,14 @@ ng_btsocket_sco_send2(ng_btsocket_sco_pcb_p pcb)
while (pcb->rt->pending < pcb->rt->num_pkts &&
pcb->so->so_snd.sb_cc > 0) {
/* Get a copy of the first packet on send queue */
- m = m_dup(pcb->so->so_snd.sb_mb, M_DONTWAIT);
+ m = m_dup(pcb->so->so_snd.sb_mb, M_NOWAIT);
if (m == NULL) {
error = ENOBUFS;
break;
}
/* Create SCO packet header */
- M_PREPEND(m, sizeof(*hdr), M_DONTWAIT);
+ M_PREPEND(m, sizeof(*hdr), M_NOWAIT);
if (m != NULL)
if (m->m_len < sizeof(*hdr))
m = m_pullup(m, sizeof(*hdr));
diff --git a/sys/netgraph/netflow/netflow.c b/sys/netgraph/netflow/netflow.c
index 2775756..c889a0d 100644
--- a/sys/netgraph/netflow/netflow.c
+++ b/sys/netgraph/netflow/netflow.c
@@ -214,7 +214,7 @@ get_export_dgram(priv_p priv, fib_export_p fe)
struct netflow_v5_export_dgram *dgram;
struct mbuf *m;
- m = m_getcl(M_DONTWAIT, MT_DATA, M_PKTHDR);
+ m = m_getcl(M_NOWAIT, MT_DATA, M_PKTHDR);
if (m == NULL)
return (NULL);
item = ng_package_data(m, NG_NOFLAGS);
diff --git a/sys/netgraph/netflow/netflow_v9.c b/sys/netgraph/netflow/netflow_v9.c
index e040665..a3c5791 100644
--- a/sys/netgraph/netflow/netflow_v9.c
+++ b/sys/netgraph/netflow/netflow_v9.c
@@ -386,7 +386,7 @@ get_export9_dgram(priv_p priv, fib_export_p fe, struct netflow_v9_packet_opt **t
uint16_t mtu = priv->mtu;
/* Allocate entire packet at once, allowing easy m_append() calls */
- m = m_getm(NULL, mtu, M_DONTWAIT, MT_DATA);
+ m = m_getm(NULL, mtu, M_NOWAIT, MT_DATA);
if (m == NULL)
return (NULL);
diff --git a/sys/netgraph/ng_UI.c b/sys/netgraph/ng_UI.c
index b06c17a..8e8ab55 100644
--- a/sys/netgraph/ng_UI.c
+++ b/sys/netgraph/ng_UI.c
@@ -188,7 +188,7 @@ ng_UI_rcvdata(hook_p hook, item_p item)
m_adj(m, ptr - start);
NG_FWD_NEW_DATA(error, item, priv->uplink, m); /* m -> NULL */
} else if (hook == priv->uplink) {
- M_PREPEND(m, 1, M_DONTWAIT); /* Prepend IP NLPID */
+ M_PREPEND(m, 1, M_NOWAIT); /* Prepend IP NLPID */
if (!m)
ERROUT(ENOBUFS);
mtod(m, u_char *)[0] = HDLC_UI;
diff --git a/sys/netgraph/ng_atmllc.c b/sys/netgraph/ng_atmllc.c
index 3ba9dff..f35707b 100644
--- a/sys/netgraph/ng_atmllc.c
+++ b/sys/netgraph/ng_atmllc.c
@@ -202,7 +202,7 @@ ng_atmllc_rcvdata(hook_p hook, item_p item)
m_adj(m, sizeof(struct atmllc) + padding);
} else if (hook == priv->ether) {
/* Add the LLC header */
- M_PREPEND(m, NG_ATMLLC_HEADER_LEN + 2, M_DONTWAIT);
+ M_PREPEND(m, NG_ATMLLC_HEADER_LEN + 2, M_NOWAIT);
if (m == NULL) {
printf("ng_atmllc: M_PREPEND failed\n");
NG_FREE_ITEM(item);
@@ -219,7 +219,7 @@ ng_atmllc_rcvdata(hook_p hook, item_p item)
outhook = priv->atm;
} else if (hook == priv->fddi) {
/* Add the LLC header */
- M_PREPEND(m, NG_ATMLLC_HEADER_LEN + 3, M_DONTWAIT);
+ M_PREPEND(m, NG_ATMLLC_HEADER_LEN + 3, M_NOWAIT);
if (m == NULL) {
printf("ng_atmllc: M_PREPEND failed\n");
NG_FREE_ITEM(item);
diff --git a/sys/netgraph/ng_bridge.c b/sys/netgraph/ng_bridge.c
index 738441d..becfea1 100644
--- a/sys/netgraph/ng_bridge.c
+++ b/sys/netgraph/ng_bridge.c
@@ -719,7 +719,7 @@ ng_bridge_rcvdata(hook_p hook, item_p item)
* It's usable link but not the reserved (first) one.
* Copy mbuf info for sending.
*/
- m2 = m_dup(m, M_DONTWAIT); /* XXX m_copypacket() */
+ m2 = m_dup(m, M_NOWAIT); /* XXX m_copypacket() */
if (m2 == NULL) {
link->stats.memoryFailures++;
NG_FREE_ITEM(item);
diff --git a/sys/netgraph/ng_cisco.c b/sys/netgraph/ng_cisco.c
index 7183369..f937557 100644
--- a/sys/netgraph/ng_cisco.c
+++ b/sys/netgraph/ng_cisco.c
@@ -360,7 +360,7 @@ cisco_rcvdata(hook_p hook, item_p item)
/* OK so it came from a protocol, heading out. Prepend general data
packet header. For now, IP,IPX only */
NGI_GET_M(item, m);
- M_PREPEND(m, CISCO_HEADER_LEN, M_DONTWAIT);
+ M_PREPEND(m, CISCO_HEADER_LEN, M_NOWAIT);
if (!m) {
error = ENOBUFS;
goto out;
@@ -608,7 +608,7 @@ cisco_send(sc_p sc, int type, long par1, long par2)
getmicrouptime(&time);
- MGETHDR(m, M_DONTWAIT, MT_DATA);
+ MGETHDR(m, M_NOWAIT, MT_DATA);
if (!m)
return (ENOBUFS);
diff --git a/sys/netgraph/ng_deflate.c b/sys/netgraph/ng_deflate.c
index 5fa6363..da68e49 100644
--- a/sys/netgraph/ng_deflate.c
+++ b/sys/netgraph/ng_deflate.c
@@ -462,7 +462,7 @@ ng_deflate_compress(node_p node, struct mbuf *m, struct mbuf **resultp)
}
/* We must own the mbuf chain exclusively to modify it. */
- m = m_unshare(m, M_DONTWAIT);
+ m = m_unshare(m, M_NOWAIT);
if (m == NULL) {
priv->stats.Errors++;
return (ENOMEM);
@@ -556,7 +556,7 @@ ng_deflate_decompress(node_p node, struct mbuf *m, struct mbuf **resultp)
}
/* We must own the mbuf chain exclusively to modify it. */
- m = m_unshare(m, M_DONTWAIT);
+ m = m_unshare(m, M_NOWAIT);
if (m == NULL) {
priv->stats.Errors++;
return (ENOMEM);
diff --git a/sys/netgraph/ng_device.c b/sys/netgraph/ng_device.c
index f6e6087..723fbca 100644
--- a/sys/netgraph/ng_device.c
+++ b/sys/netgraph/ng_device.c
@@ -465,7 +465,7 @@ ngdwrite(struct cdev *dev, struct uio *uio, int flag)
if (uio->uio_resid < 0 || uio->uio_resid > IP_MAXPACKET)
return (EIO);
- if ((m = m_uiotombuf(uio, M_DONTWAIT, 0, 0, M_PKTHDR)) == NULL)
+ if ((m = m_uiotombuf(uio, M_NOWAIT, 0, 0, M_PKTHDR)) == NULL)
return (ENOBUFS);
NG_SEND_DATA_ONLY(error, priv->hook, m);
diff --git a/sys/netgraph/ng_frame_relay.c b/sys/netgraph/ng_frame_relay.c
index 05c311d..4d39d11 100644
--- a/sys/netgraph/ng_frame_relay.c
+++ b/sys/netgraph/ng_frame_relay.c
@@ -360,7 +360,7 @@ ngfrm_rcvdata(hook_p hook, item_p item)
alen = sc->addrlen;
if (alen == 0)
alen = 2; /* default value for transmit */
- M_PREPEND(m, alen, M_DONTWAIT);
+ M_PREPEND(m, alen, M_NOWAIT);
if (m == NULL) {
error = ENOBUFS;
goto bad;
diff --git a/sys/netgraph/ng_gif.c b/sys/netgraph/ng_gif.c
index d362152..580b8b1 100644
--- a/sys/netgraph/ng_gif.c
+++ b/sys/netgraph/ng_gif.c
@@ -303,7 +303,7 @@ ng_gif_glue_af(struct mbuf **mp, int af)
* hopefully everything after that will not
* need one. So let's just use M_PREPEND.
*/
- M_PREPEND(m, sizeof (tmp_af), M_DONTWAIT);
+ M_PREPEND(m, sizeof (tmp_af), M_NOWAIT);
if (m == NULL) {
error = ENOBUFS;
goto done;
diff --git a/sys/netgraph/ng_gif_demux.c b/sys/netgraph/ng_gif_demux.c
index 646e37d..ce0fba0 100644
--- a/sys/netgraph/ng_gif_demux.c
+++ b/sys/netgraph/ng_gif_demux.c
@@ -341,7 +341,7 @@ ng_gif_demux_rcvdata(hook_p hook, item_p item)
* Add address family header and set the output hook.
*/
iffam = get_iffam_from_hook(priv, hook);
- M_PREPEND(m, sizeof (iffam->family), M_DONTWAIT);
+ M_PREPEND(m, sizeof (iffam->family), M_NOWAIT);
if (m == NULL) {
NG_FREE_M(m);
NG_FREE_ITEM(item);
diff --git a/sys/netgraph/ng_hub.c b/sys/netgraph/ng_hub.c
index 2a8c2d2..9348b27 100644
--- a/sys/netgraph/ng_hub.c
+++ b/sys/netgraph/ng_hub.c
@@ -133,7 +133,7 @@ ng_hub_rcvdata(hook_p hook, item_p item)
if (--nhooks == 1)
NG_FWD_ITEM_HOOK(error, item, hook2);
else {
- if ((m2 = m_dup(m, M_DONTWAIT)) == NULL) {
+ if ((m2 = m_dup(m, M_NOWAIT)) == NULL) {
NG_FREE_ITEM(item);
return (ENOBUFS);
}
diff --git a/sys/netgraph/ng_iface.c b/sys/netgraph/ng_iface.c
index 3ce0261..5e6f12f 100644
--- a/sys/netgraph/ng_iface.c
+++ b/sys/netgraph/ng_iface.c
@@ -394,7 +394,7 @@ ng_iface_output(struct ifnet *ifp, struct mbuf *m,
ng_iface_bpftap(ifp, m, dst->sa_family);
if (ALTQ_IS_ENABLED(&ifp->if_snd)) {
- M_PREPEND(m, sizeof(sa_family_t), M_DONTWAIT);
+ M_PREPEND(m, sizeof(sa_family_t), M_NOWAIT);
if (m == NULL) {
IFQ_LOCK(&ifp->if_snd);
IFQ_INC_DROPS(&ifp->if_snd);
diff --git a/sys/netgraph/ng_ipfw.c b/sys/netgraph/ng_ipfw.c
index 82a7238..8c77798 100644
--- a/sys/netgraph/ng_ipfw.c
+++ b/sys/netgraph/ng_ipfw.c
@@ -320,7 +320,7 @@ ng_ipfw_input(struct mbuf **m0, int dir, struct ip_fw_args *fwa, int tee)
m_tag_prepend(m, tag);
} else
- if ((m = m_dup(*m0, M_DONTWAIT)) == NULL)
+ if ((m = m_dup(*m0, M_NOWAIT)) == NULL)
return (ENOMEM); /* which is ignored */
if (m->m_len < sizeof(struct ip) &&
diff --git a/sys/netgraph/ng_l2tp.c b/sys/netgraph/ng_l2tp.c
index 3b91b84..bd98e6c 100644
--- a/sys/netgraph/ng_l2tp.c
+++ b/sys/netgraph/ng_l2tp.c
@@ -934,7 +934,7 @@ ng_l2tp_rcvdata_lower(hook_p h, item_p item)
mtx_unlock(&seq->mtx);
/* Prepend session ID to packet. */
- M_PREPEND(m, 2, M_DONTWAIT);
+ M_PREPEND(m, 2, M_NOWAIT);
if (m == NULL) {
seq->inproc = 0;
priv->stats.memoryFailures++;
@@ -1071,7 +1071,7 @@ ng_l2tp_rcvdata_ctrl(hook_p hook, item_p item)
mtx_unlock(&seq->mtx);
/* Copy packet */
- if ((m = L2TP_COPY_MBUF(m, M_DONTWAIT)) == NULL) {
+ if ((m = L2TP_COPY_MBUF(m, M_NOWAIT)) == NULL) {
priv->stats.memoryFailures++;
ERROUT(ENOBUFS);
}
@@ -1122,7 +1122,7 @@ ng_l2tp_rcvdata(hook_p hook, item_p item)
M_PREPEND(m, 6
+ (2 * (hpriv->conf.include_length != 0))
+ (4 * (hpriv->conf.enable_dseq != 0)),
- M_DONTWAIT);
+ M_NOWAIT);
if (m == NULL) {
priv->stats.memoryFailures++;
NG_FREE_ITEM(item);
@@ -1406,7 +1406,7 @@ ng_l2tp_seq_recv_nr(priv_p priv, u_int16_t nr)
*/
for (i = 0; i < j; i++) {
struct mbuf *m;
- if ((m = L2TP_COPY_MBUF(xwin[i], M_DONTWAIT)) == NULL)
+ if ((m = L2TP_COPY_MBUF(xwin[i], M_NOWAIT)) == NULL)
priv->stats.memoryFailures++;
else
ng_l2tp_xmit_ctrl(priv, m, ns);
@@ -1482,7 +1482,7 @@ ng_l2tp_seq_rack_timeout(node_p node, hook_p hook, void *arg1, int arg2)
seq->acks = 0;
/* Retransmit oldest unack'd packet */
- if ((m = L2TP_COPY_MBUF(seq->xwin[0], M_DONTWAIT)) == NULL)
+ if ((m = L2TP_COPY_MBUF(seq->xwin[0], M_NOWAIT)) == NULL)
priv->stats.memoryFailures++;
else
ng_l2tp_xmit_ctrl(priv, m, seq->ns++);
@@ -1521,7 +1521,7 @@ ng_l2tp_xmit_ctrl(priv_p priv, struct mbuf *m, u_int16_t ns)
if (m == NULL) {
/* Create a new mbuf for ZLB packet */
- MGETHDR(m, M_DONTWAIT, MT_DATA);
+ MGETHDR(m, M_NOWAIT, MT_DATA);
if (m == NULL) {
priv->stats.memoryFailures++;
return (ENOBUFS);
@@ -1539,7 +1539,7 @@ ng_l2tp_xmit_ctrl(priv_p priv, struct mbuf *m, u_int16_t ns)
session_id = (mtod(m, u_int8_t *)[0] << 8) + mtod(m, u_int8_t *)[1];
/* Make room for L2TP header */
- M_PREPEND(m, 10, M_DONTWAIT); /* - 2 + 12 = 10 */
+ M_PREPEND(m, 10, M_NOWAIT); /* - 2 + 12 = 10 */
if (m == NULL) {
priv->stats.memoryFailures++;
return (ENOBUFS);
diff --git a/sys/netgraph/ng_lmi.c b/sys/netgraph/ng_lmi.c
index 2624e06..6d3fb20 100644
--- a/sys/netgraph/ng_lmi.c
+++ b/sys/netgraph/ng_lmi.c
@@ -317,7 +317,7 @@ nglmi_inquire(sc_p sc, int full)
if (sc->lmi_channel == NULL)
return;
- MGETHDR(m, M_DONTWAIT, MT_DATA);
+ MGETHDR(m, M_NOWAIT, MT_DATA);
if (m == NULL) {
log(LOG_ERR, "nglmi: unable to start up LMI processing\n");
return;
diff --git a/sys/netgraph/ng_mppc.c b/sys/netgraph/ng_mppc.c
index 6754be7..ddf97d1 100644
--- a/sys/netgraph/ng_mppc.c
+++ b/sys/netgraph/ng_mppc.c
@@ -467,7 +467,7 @@ ng_mppc_compress(node_p node, struct mbuf **datap)
struct mbuf *m = *datap;
/* We must own the mbuf chain exclusively to modify it. */
- m = m_unshare(m, M_DONTWAIT);
+ m = m_unshare(m, M_NOWAIT);
if (m == NULL)
return (ENOMEM);
@@ -595,7 +595,7 @@ err1:
MPPC_CCOUNT_INC(d->cc);
/* Install header */
- M_PREPEND(m, MPPC_HDRLEN, M_DONTWAIT);
+ M_PREPEND(m, MPPC_HDRLEN, M_NOWAIT);
if (m != NULL)
be16enc(mtod(m, void *), header);
@@ -617,7 +617,7 @@ ng_mppc_decompress(node_p node, struct mbuf **datap)
struct mbuf *m = *datap;
/* We must own the mbuf chain exclusively to modify it. */
- m = m_unshare(m, M_DONTWAIT);
+ m = m_unshare(m, M_NOWAIT);
if (m == NULL)
return (ENOMEM);
diff --git a/sys/netgraph/ng_one2many.c b/sys/netgraph/ng_one2many.c
index 5984279..8171005 100644
--- a/sys/netgraph/ng_one2many.c
+++ b/sys/netgraph/ng_one2many.c
@@ -459,7 +459,7 @@ ng_one2many_rcvdata(hook_p hook, item_p item)
struct ng_one2many_link *mdst;
mdst = &priv->many[priv->activeMany[i]];
- m2 = m_dup(m, M_DONTWAIT); /* XXX m_copypacket() */
+ m2 = m_dup(m, M_NOWAIT); /* XXX m_copypacket() */
if (m2 == NULL) {
mdst->stats.memoryFailures++;
NG_FREE_ITEM(item);
diff --git a/sys/netgraph/ng_ppp.c b/sys/netgraph/ng_ppp.c
index b26163a..9db1a2f 100644
--- a/sys/netgraph/ng_ppp.c
+++ b/sys/netgraph/ng_ppp.c
@@ -2095,7 +2095,7 @@ deliver:
/* Split off next fragment as "m2" */
m2 = m;
if (!lastFragment) {
- struct mbuf *n = m_split(m, len, M_DONTWAIT);
+ struct mbuf *n = m_split(m, len, M_NOWAIT);
if (n == NULL) {
NG_FREE_M(m);
@@ -2103,7 +2103,7 @@ deliver:
NG_FREE_ITEM(item);
return (ENOMEM);
}
- m_tag_copy_chain(n, m, M_DONTWAIT);
+ m_tag_copy_chain(n, m, M_NOWAIT);
m = n;
}
@@ -2445,7 +2445,7 @@ ng_ppp_cutproto(struct mbuf *m, uint16_t *proto)
static struct mbuf *
ng_ppp_prepend(struct mbuf *m, const void *buf, int len)
{
- M_PREPEND(m, len, M_DONTWAIT);
+ M_PREPEND(m, len, M_NOWAIT);
if (m == NULL || (m->m_len < len && (m = m_pullup(m, len)) == NULL))
return (NULL);
bcopy(buf, mtod(m, uint8_t *), len);
diff --git a/sys/netgraph/ng_pppoe.c b/sys/netgraph/ng_pppoe.c
index 3b953b3..818bd7a 100644
--- a/sys/netgraph/ng_pppoe.c
+++ b/sys/netgraph/ng_pppoe.c
@@ -460,7 +460,7 @@ pppoe_broadcast_padi(node_p node, struct mbuf *m0)
LIST_FOREACH(sp, &privp->listeners, sessions) {
struct mbuf *m;
- m = m_dup(m0, M_DONTWAIT);
+ m = m_dup(m0, M_NOWAIT);
if (m == NULL)
return (ENOMEM);
NG_SEND_DATA_ONLY(error, sp->hook, m);
@@ -801,7 +801,7 @@ ng_pppoe_rcvmsg(node_p node, item_p item, hook_p lasthook)
if (neg == NULL)
LEAVE(ENOMEM);
- neg->m = m_getcl(M_DONTWAIT, MT_DATA, M_PKTHDR);
+ neg->m = m_getcl(M_NOWAIT, MT_DATA, M_PKTHDR);
if (neg->m == NULL) {
free(neg, M_NETGRAPH_PPPOE);
LEAVE(ENOBUFS);
@@ -1078,7 +1078,7 @@ pppoe_start(sessp sp)
ng_callout(&neg->handle, node, hook, PPPOE_INITIAL_TIMEOUT * hz,
pppoe_ticker, NULL, 0);
neg->timeout = PPPOE_INITIAL_TIMEOUT * 2;
- m0 = m_copypacket(neg->m, M_DONTWAIT);
+ m0 = m_copypacket(neg->m, M_NOWAIT);
NG_SEND_DATA_ONLY(error, privp->ethernet_hook, m0);
}
@@ -1161,7 +1161,7 @@ ng_pppoe_rcvdata(hook_p hook, item_p item)
* Bang in a pre-made header, and set the length up
* to be correct. Then send it to the ethernet driver.
*/
- M_PREPEND(m, sizeof(*wh), M_DONTWAIT);
+ M_PREPEND(m, sizeof(*wh), M_NOWAIT);
if (m == NULL)
LEAVE(ENOBUFS);
@@ -1251,7 +1251,7 @@ ng_pppoe_rcvdata(hook_p hook, item_p item)
*/
ng_callout(&neg->handle, node, hook, PPPOE_OFFER_TIMEOUT * hz,
pppoe_ticker, NULL, 0);
- m0 = m_copypacket(sp->neg->m, M_DONTWAIT);
+ m0 = m_copypacket(sp->neg->m, M_NOWAIT);
NG_FWD_NEW_DATA(error, item, privp->ethernet_hook, m0);
privp->packets_out++;
break;
@@ -1338,7 +1338,7 @@ ng_pppoe_rcvdata_ether(hook_p hook, item_p item)
* Put it into a cluster.
*/
struct mbuf *n;
- n = m_dup(m, M_DONTWAIT);
+ n = m_dup(m, M_NOWAIT);
m_freem(m);
m = n;
if (m) {
@@ -1472,7 +1472,7 @@ ng_pppoe_rcvdata_ether(hook_p hook, item_p item)
PPPOE_INITIAL_TIMEOUT * hz,
pppoe_ticker, NULL, 0);
neg->timeout = PPPOE_INITIAL_TIMEOUT * 2;
- m0 = m_copypacket(neg->m, M_DONTWAIT);
+ m0 = m_copypacket(neg->m, M_NOWAIT);
NG_FWD_NEW_DATA(error, item, privp->ethernet_hook, m0);
break;
case PADR_CODE:
@@ -1530,7 +1530,7 @@ ng_pppoe_rcvdata_ether(hook_p hook, item_p item)
sp->state = PPPOE_NEWCONNECTED;
/* Send the PADS without a timeout - we're now connected. */
- m0 = m_copypacket(sp->neg->m, M_DONTWAIT);
+ m0 = m_copypacket(sp->neg->m, M_NOWAIT);
NG_FWD_NEW_DATA(error, item, privp->ethernet_hook, m0);
/*
@@ -1736,7 +1736,7 @@ ng_pppoe_disconnect(hook_p hook)
struct mbuf *m;
/* Generate a packet of that type. */
- MGETHDR(m, M_DONTWAIT, MT_DATA);
+ MGETHDR(m, M_NOWAIT, MT_DATA);
if (m == NULL)
log(LOG_NOTICE, "ng_pppoe[%x]: session out of "
"mbufs\n", node->nd_ID);
@@ -1823,7 +1823,7 @@ pppoe_ticker(node_p node, hook_p hook, void *arg1, int arg2)
case PPPOE_SINIT:
case PPPOE_SREQ:
/* Timeouts on these produce resends. */
- m0 = m_copypacket(sp->neg->m, M_DONTWAIT);
+ m0 = m_copypacket(sp->neg->m, M_NOWAIT);
NG_SEND_DATA_ONLY( error, privp->ethernet_hook, m0);
ng_callout(&neg->handle, node, hook, neg->timeout * hz,
pppoe_ticker, NULL, 0);
diff --git a/sys/netgraph/ng_pptpgre.c b/sys/netgraph/ng_pptpgre.c
index f48b80c..83d3e0a 100644
--- a/sys/netgraph/ng_pptpgre.c
+++ b/sys/netgraph/ng_pptpgre.c
@@ -598,7 +598,7 @@ ng_pptpgre_xmit(hpriv_p hpriv, item_p item)
/* Prepend GRE header to outgoing frame */
grelen = sizeof(*gre) + sizeof(u_int32_t) * (gre->hasSeq + gre->hasAck);
if (m == NULL) {
- MGETHDR(m, M_DONTWAIT, MT_DATA);
+ MGETHDR(m, M_NOWAIT, MT_DATA);
if (m == NULL) {
priv->stats.memoryFailures++;
ERROUT(ENOBUFS);
@@ -606,7 +606,7 @@ ng_pptpgre_xmit(hpriv_p hpriv, item_p item)
m->m_len = m->m_pkthdr.len = grelen;
m->m_pkthdr.rcvif = NULL;
} else {
- M_PREPEND(m, grelen, M_DONTWAIT);
+ M_PREPEND(m, grelen, M_NOWAIT);
if (m == NULL || (m->m_len < grelen
&& (m = m_pullup(m, grelen)) == NULL)) {
priv->stats.memoryFailures++;
diff --git a/sys/netgraph/ng_pred1.c b/sys/netgraph/ng_pred1.c
index 52efe63..4792b7a 100644
--- a/sys/netgraph/ng_pred1.c
+++ b/sys/netgraph/ng_pred1.c
@@ -401,7 +401,7 @@ ng_pred1_compress(node_p node, struct mbuf *m, struct mbuf **resultp)
}
/* We must own the mbuf chain exclusively to modify it. */
- m = m_unshare(m, M_DONTWAIT);
+ m = m_unshare(m, M_NOWAIT);
if (m == NULL) {
priv->stats.Errors++;
return (ENOMEM);
@@ -479,7 +479,7 @@ ng_pred1_decompress(node_p node, struct mbuf *m, struct mbuf **resultp)
}
/* We must own the mbuf chain exclusively to modify it. */
- m = m_unshare(m, M_DONTWAIT);
+ m = m_unshare(m, M_NOWAIT);
if (m == NULL) {
priv->stats.Errors++;
return (ENOMEM);
diff --git a/sys/netgraph/ng_rfc1490.c b/sys/netgraph/ng_rfc1490.c
index 2dc5123..061faa2 100644
--- a/sys/netgraph/ng_rfc1490.c
+++ b/sys/netgraph/ng_rfc1490.c
@@ -385,7 +385,7 @@ switch_on_etype: etype = ntohs(*((const u_int16_t *)ptr));
break;
}
} else if (hook == priv->ppp) {
- M_PREPEND(m, 2, M_DONTWAIT); /* Prepend PPP NLPID */
+ M_PREPEND(m, 2, M_NOWAIT); /* Prepend PPP NLPID */
if (!m)
ERROUT(ENOBUFS);
mtod(m, u_char *)[0] = HDLC_UI;
@@ -394,7 +394,7 @@ switch_on_etype: etype = ntohs(*((const u_int16_t *)ptr));
} else if (hook == priv->inet) {
switch (priv->enc->method) {
case NG_RFC1490_ENCAP_IETF_IP:
- M_PREPEND(m, 2, M_DONTWAIT); /* Prepend IP NLPID */
+ M_PREPEND(m, 2, M_NOWAIT); /* Prepend IP NLPID */
if (!m)
ERROUT(ENOBUFS);
mtod(m, u_char *)[0] = HDLC_UI;
@@ -406,7 +406,7 @@ switch_on_etype: etype = ntohs(*((const u_int16_t *)ptr));
* HDLC_UI PAD NLIPID OUI PID
* 03 00 80 00 00 00 08 00
*/
- M_PREPEND(m, 8, M_DONTWAIT);
+ M_PREPEND(m, 8, M_NOWAIT);
if (!m)
ERROUT(ENOBUFS);
mtod(m, u_char *)[0] = HDLC_UI;
@@ -417,7 +417,7 @@ switch_on_etype: etype = ntohs(*((const u_int16_t *)ptr));
= htons(ETHERTYPE_IP); /* PID */
break;
case NG_RFC1490_ENCAP_CISCO:
- M_PREPEND(m, 2, M_DONTWAIT); /* Prepend IP ethertype */
+ M_PREPEND(m, 2, M_NOWAIT); /* Prepend IP ethertype */
if (!m)
ERROUT(ENOBUFS);
*((u_int16_t *)mtod(m, u_int16_t *)) = htons(ETHERTYPE_IP);
@@ -425,7 +425,7 @@ switch_on_etype: etype = ntohs(*((const u_int16_t *)ptr));
}
NG_FWD_NEW_DATA(error, item, priv->downlink, m);
} else if (hook == priv->ethernet) {
- M_PREPEND(m, 8, M_DONTWAIT); /* Prepend NLPID, OUI, PID */
+ M_PREPEND(m, 8, M_NOWAIT); /* Prepend NLPID, OUI, PID */
if (!m)
ERROUT(ENOBUFS);
mtod(m, u_char *)[0] = HDLC_UI;
diff --git a/sys/netgraph/ng_source.c b/sys/netgraph/ng_source.c
index 83473f9..1883ec0 100644
--- a/sys/netgraph/ng_source.c
+++ b/sys/netgraph/ng_source.c
@@ -445,7 +445,7 @@ ng_source_rcvmsg(node_p node, item_p item, hook_p lasthook)
{
struct ng_source_embed_info *embed;
- NG_MKRESPONSE(resp, msg, sizeof(*embed), M_DONTWAIT);
+ NG_MKRESPONSE(resp, msg, sizeof(*embed), M_NOWAIT);
if (resp == NULL) {
error = ENOMEM;
goto done;
@@ -484,7 +484,7 @@ ng_source_rcvmsg(node_p node, item_p item, hook_p lasthook)
error = EINVAL;
goto done;
}
- NG_MKRESPONSE(resp, msg, sizeof(*embed), M_DONTWAIT);
+ NG_MKRESPONSE(resp, msg, sizeof(*embed), M_NOWAIT);
if (resp == NULL) {
error = ENOMEM;
goto done;
@@ -873,9 +873,9 @@ ng_source_dup_mod(sc_p sc, struct mbuf *m0, struct mbuf **m_ptr)
/* Duplicate the packet. */
if (modify)
- m = m_dup(m0, M_DONTWAIT);
+ m = m_dup(m0, M_NOWAIT);
else
- m = m_copypacket(m0, M_DONTWAIT);
+ m = m_copypacket(m0, M_NOWAIT);
if (m == NULL) {
error = ENOBUFS;
goto done;
diff --git a/sys/netgraph/ng_tee.c b/sys/netgraph/ng_tee.c
index 4d85666..c6a517e 100644
--- a/sys/netgraph/ng_tee.c
+++ b/sys/netgraph/ng_tee.c
@@ -305,7 +305,7 @@ ng_tee_rcvdata(hook_p hook, item_p item)
struct mbuf *m2;
/* Copy packet (failure will not stop the original)*/
- m2 = m_dup(m, M_DONTWAIT);
+ m2 = m_dup(m, M_NOWAIT);
if (m2) {
/* Deliver duplicate */
h = hinfo->dup;
diff --git a/sys/netgraph/ng_tty.c b/sys/netgraph/ng_tty.c
index 34105b2..35e1734 100644
--- a/sys/netgraph/ng_tty.c
+++ b/sys/netgraph/ng_tty.c
@@ -418,7 +418,7 @@ ngt_rint_bypass(struct tty *tp, const void *buf, size_t len)
if (sc->hook == NULL)
return (0);
- m = m_getm2(NULL, len, M_DONTWAIT, MT_DATA, M_PKTHDR);
+ m = m_getm2(NULL, len, M_NOWAIT, MT_DATA, M_PKTHDR);
if (m == NULL) {
if (sc->flags & FLG_DEBUG)
log(LOG_ERR,
@@ -476,7 +476,7 @@ ngt_rint(struct tty *tp, char c, int flags)
/* Get a new header mbuf if we need one */
if (!(m = sc->m)) {
- MGETHDR(m, M_DONTWAIT, MT_DATA);
+ MGETHDR(m, M_NOWAIT, MT_DATA);
if (!m) {
if (sc->flags & FLG_DEBUG)
log(LOG_ERR,
diff --git a/sys/netgraph/ng_vjc.c b/sys/netgraph/ng_vjc.c
index 97801f2..e1b76b5 100644
--- a/sys/netgraph/ng_vjc.c
+++ b/sys/netgraph/ng_vjc.c
@@ -474,7 +474,7 @@ ng_vjc_rcvdata(hook_p hook, item_p item)
m_adj(m, vjlen);
/* Copy the reconstructed TCP/IP headers into a new mbuf */
- MGETHDR(hm, M_DONTWAIT, MT_DATA);
+ MGETHDR(hm, M_NOWAIT, MT_DATA);
if (hm == NULL) {
priv->slc.sls_errorin++;
NG_FREE_M(m);
@@ -484,7 +484,7 @@ ng_vjc_rcvdata(hook_p hook, item_p item)
hm->m_len = 0;
hm->m_pkthdr.rcvif = NULL;
if (hlen > MHLEN) { /* unlikely, but can happen */
- MCLGET(hm, M_DONTWAIT);
+ MCLGET(hm, M_NOWAIT);
if ((hm->m_flags & M_EXT) == 0) {
m_freem(hm);
priv->slc.sls_errorin++;
diff --git a/sys/netgraph/ng_vlan.c b/sys/netgraph/ng_vlan.c
index b07a603..1c10a0e 100644
--- a/sys/netgraph/ng_vlan.c
+++ b/sys/netgraph/ng_vlan.c
@@ -648,7 +648,7 @@ ng_vlan_rcvdata(hook_p hook, item_p item)
* [dmac] [smac] [TPID] [PCP/CFI/VID] [ether_type] [payload]
* |-----------| |-- inserted tag --| |--------------------|
*/
- M_PREPEND(m, ETHER_VLAN_ENCAP_LEN, M_DONTWAIT);
+ M_PREPEND(m, ETHER_VLAN_ENCAP_LEN, M_NOWAIT);
if (m == NULL)
error = ENOMEM;
else
OpenPOWER on IntegriCloud