summaryrefslogtreecommitdiff
path: root/sys/net
diff options
context:
space:
mode:
authorHenning Brauer <henning@cvs.openbsd.org>2011-07-05 19:59:19 +0000
committerHenning Brauer <henning@cvs.openbsd.org>2011-07-05 19:59:19 +0000
commit3e464520f38d4df0f1fa0ea7f355ac7d02ed6afc (patch)
treeee6505cbe551f0df2929aa3aa60b6bf5893fd196 /sys/net
parent13f2a1a3586795763adef30659b4253b998b3f11 (diff)
use IFQ_IS_EMPTY instead of fiddling with ifqueue internals - 3 cases
why bother with APIs when you can muck with internals directly, it's obvious there'll NEVER be changes, right. ok claudio ryan
Diffstat (limited to 'sys/net')
-rw-r--r--sys/net/if_ppp.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/sys/net/if_ppp.c b/sys/net/if_ppp.c
index d45ea897148..3f94efe822d 100644
--- a/sys/net/if_ppp.c
+++ b/sys/net/if_ppp.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_ppp.c,v 1.59 2011/07/04 20:40:58 dhill Exp $ */
+/* $OpenBSD: if_ppp.c,v 1.60 2011/07/05 19:59:18 henning Exp $ */
/* $NetBSD: if_ppp.c,v 1.39 1997/05/17 21:11:59 christos Exp $ */
/*
@@ -1120,13 +1120,14 @@ pppintr()
s = splsoftnet(); /* XXX - what's the point of this? see comment above */
LIST_FOREACH(sc, &ppp_softc_list, sc_list) {
if (!(sc->sc_flags & SC_TBUSY)
- && (IFQ_IS_EMPTY(&sc->sc_if.if_snd) == 0 || sc->sc_fastq.ifq_head)) {
+ && (!IFQ_IS_EMPTY(&sc->sc_if.if_snd) ||
+ !IFQ_IS_EMPTY(&sc->sc_fastq))) {
s2 = splnet();
sc->sc_flags |= SC_TBUSY;
splx(s2);
(*sc->sc_start)(sc);
}
- while (sc->sc_rawq.ifq_head) {
+ while (!IFQ_IS_EMPTY(&sc->sc_rawq)) {
s2 = splnet();
IF_DEQUEUE(&sc->sc_rawq, m);
splx(s2);