summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
Diffstat (limited to 'sys')
-rw-r--r--sys/net/if_pppoe.c29
1 files changed, 14 insertions, 15 deletions
diff --git a/sys/net/if_pppoe.c b/sys/net/if_pppoe.c
index 4686e8dd6bf..8d18f98e8bb 100644
--- a/sys/net/if_pppoe.c
+++ b/sys/net/if_pppoe.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_pppoe.c,v 1.13 2007/09/15 16:43:51 henning Exp $ */
+/* $OpenBSD: if_pppoe.c,v 1.14 2008/02/20 09:37:52 brad Exp $ */
/* $NetBSD: if_pppoe.c,v 1.51 2003/11/28 08:56:48 keihan Exp $ */
/*
@@ -366,25 +366,22 @@ pppoe_find_softc_by_hunique(u_int8_t *token, size_t len, struct ifnet *rcvif)
void
pppoeintr(void)
{
- struct pppoe_softc *sc;
struct mbuf *m;
splassert(IPL_SOFTNET);
- LIST_FOREACH(sc, &pppoe_softc_list, sc_list) {
- while (ppoediscinq.ifq_head) {
- MBUFLOCK(IF_DEQUEUE(&ppoediscinq, m););
- if (m == NULL)
- break;
- pppoe_disc_input(m);
- }
+ while (ppoediscinq.ifq_head) {
+ MBUFLOCK(IF_DEQUEUE(&ppoediscinq, m););
+ if (m == NULL)
+ break;
+ pppoe_disc_input(m);
+ }
- while (ppoeinq.ifq_head) {
- MBUFLOCK(IF_DEQUEUE(&ppoeinq, m););
- if (m == NULL)
- break;
- pppoe_data_input(m);
- }
+ while (ppoeinq.ifq_head) {
+ MBUFLOCK(IF_DEQUEUE(&ppoeinq, m););
+ if (m == NULL)
+ break;
+ pppoe_data_input(m);
}
}
@@ -733,6 +730,8 @@ pppoe_data_input(struct mbuf *m)
#ifdef PPPOE_TERM_UNKNOWN_SESSIONS
u_int8_t shost[ETHER_ADDR_LEN];
#endif
+ if (LIST_EMPTY(&pppoe_softc_list))
+ goto drop;
KASSERT(m->m_flags & M_PKTHDR);