diff options
author | Martin Pieuchot <mpi@cvs.openbsd.org> | 2016-01-14 09:20:32 +0000 |
---|---|---|
committer | Martin Pieuchot <mpi@cvs.openbsd.org> | 2016-01-14 09:20:32 +0000 |
commit | e3d0c036438f6732dd0fa4343e7817afec346363 (patch) | |
tree | c06e6b9d844df9993e5b82d530b9f90d999a9093 /sys/net | |
parent | eb25214054c78508ccc656af74d40833d6265d11 (diff) |
No need for a splnet() dance around IFQ_DEQUEUE() anymore.
From David Hill, ok dlg@
Diffstat (limited to 'sys/net')
-rw-r--r-- | sys/net/if_gif.c | 8 | ||||
-rw-r--r-- | sys/net/if_mpe.c | 6 | ||||
-rw-r--r-- | sys/net/if_pppx.c | 6 | ||||
-rw-r--r-- | sys/net/if_vxlan.c | 7 |
4 files changed, 7 insertions, 20 deletions
diff --git a/sys/net/if_gif.c b/sys/net/if_gif.c index a695b5d8f5d..afb8ff0ab06 100644 --- a/sys/net/if_gif.c +++ b/sys/net/if_gif.c @@ -1,4 +1,4 @@ -/* $OpenBSD: if_gif.c,v 1.83 2015/12/05 10:07:55 tedu Exp $ */ +/* $OpenBSD: if_gif.c,v 1.84 2016/01/14 09:20:31 mpi Exp $ */ /* $KAME: if_gif.c,v 1.43 2001/02/20 08:51:07 itojun Exp $ */ /* @@ -164,13 +164,9 @@ gif_start(struct ifnet *ifp) { struct gif_softc *sc = (struct gif_softc*)ifp; struct mbuf *m; - int s; - while (1) { - s = splnet(); + for (;;) { IFQ_DEQUEUE(&ifp->if_snd, m); - splx(s); - if (m == NULL) break; diff --git a/sys/net/if_mpe.c b/sys/net/if_mpe.c index ac06d06fd8b..10cbe545f95 100644 --- a/sys/net/if_mpe.c +++ b/sys/net/if_mpe.c @@ -1,4 +1,4 @@ -/* $OpenBSD: if_mpe.c,v 1.52 2015/12/05 10:07:55 tedu Exp $ */ +/* $OpenBSD: if_mpe.c,v 1.53 2016/01/14 09:20:31 mpi Exp $ */ /* * Copyright (c) 2008 Pierre-Yves Ritschard <pyr@spootnik.org> @@ -143,16 +143,12 @@ mpestart(struct ifnet *ifp0) { struct mbuf *m; struct sockaddr *sa = (struct sockaddr *)&mpedst; - int s; sa_family_t af; struct rtentry *rt; struct ifnet *ifp; for (;;) { - s = splnet(); IFQ_DEQUEUE(&ifp0->if_snd, m); - splx(s); - if (m == NULL) return; diff --git a/sys/net/if_pppx.c b/sys/net/if_pppx.c index 7608e870cef..a6a8ac00b89 100644 --- a/sys/net/if_pppx.c +++ b/sys/net/if_pppx.c @@ -1,4 +1,4 @@ -/* $OpenBSD: if_pppx.c,v 1.48 2015/12/05 16:09:09 yasuoka Exp $ */ +/* $OpenBSD: if_pppx.c,v 1.49 2016/01/14 09:20:31 mpi Exp $ */ /* * Copyright (c) 2010 Claudio Jeker <claudio@openbsd.org> @@ -995,15 +995,13 @@ pppx_if_start(struct ifnet *ifp) { struct pppx_if *pxi = (struct pppx_if *)ifp->if_softc; struct mbuf *m; - int proto, s; + int proto; if (!ISSET(ifp->if_flags, IFF_RUNNING)) return; for (;;) { - s = splnet(); IFQ_DEQUEUE(&ifp->if_snd, m); - splx(s); if (m == NULL) break; diff --git a/sys/net/if_vxlan.c b/sys/net/if_vxlan.c index 75b21602a1b..a220bff8352 100644 --- a/sys/net/if_vxlan.c +++ b/sys/net/if_vxlan.c @@ -1,4 +1,4 @@ -/* $OpenBSD: if_vxlan.c,v 1.35 2015/12/05 10:07:55 tedu Exp $ */ +/* $OpenBSD: if_vxlan.c,v 1.36 2016/01/14 09:20:31 mpi Exp $ */ /* * Copyright (c) 2013 Reyk Floeter <reyk@openbsd.org> @@ -275,15 +275,12 @@ void vxlanstart(struct ifnet *ifp) { struct mbuf *m; - int s; for (;;) { - s = splnet(); IFQ_DEQUEUE(&ifp->if_snd, m); - splx(s); - if (m == NULL) return; + ifp->if_opackets++; #if NBPFILTER > 0 |