From fa9336b832723490e5dd918d3ecb2bd9fa100a43 Mon Sep 17 00:00:00 2001 From: Robert Watson Date: Sun, 11 Apr 2004 16:26:39 +0000 Subject: [PATCH] Compare IFF_POLLING flag with ifp->if_flags rather than ifp->if_ipending, which was almost certainly a bug since polling support was introduced in this driver. Found during discussion with: mlaier --- sys/dev/nge/if_nge.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/dev/nge/if_nge.c b/sys/dev/nge/if_nge.c index 2805b1e09d7..2b85ed1310d 100644 --- a/sys/dev/nge/if_nge.c +++ b/sys/dev/nge/if_nge.c @@ -1310,7 +1310,7 @@ nge_rxeof(sc) u_int32_t extsts; #ifdef DEVICE_POLLING - if (ifp->if_ipending & IFF_POLLING) { + if (ifp->if_flags & IFF_POLLING) { if (sc->rxcycles <= 0) break; sc->rxcycles--; @@ -1576,7 +1576,7 @@ nge_intr(arg) ifp = &sc->arpcom.ac_if; #ifdef DEVICE_POLLING - if (ifp->if_ipending & IFF_POLLING) + if (ifp->if_flags & IFF_POLLING) return; if (ether_poll_register(nge_poll, ifp)) { /* ok, disable interrupts */ CSR_WRITE_4(sc, NGE_IER, 0); @@ -1956,7 +1956,7 @@ nge_init(xsc) * ... only enable interrupts if we are not polling, make sure * they are off otherwise. */ - if (ifp->if_ipending & IFF_POLLING) + if (ifp->if_flags & IFF_POLLING) CSR_WRITE_4(sc, NGE_IER, 0); else #endif /* DEVICE_POLLING */