summaryrefslogtreecommitdiffstats
path: root/sys/pci/if_tl.c
diff options
context:
space:
mode:
authorsam <sam@FreeBSD.org>2003-11-14 19:00:32 +0000
committersam <sam@FreeBSD.org>2003-11-14 19:00:32 +0000
commit29f07789b1fc26f60bc1c931437f78725f1bc994 (patch)
tree0e5901939d8633065a9035209aa5138fe4ea6820 /sys/pci/if_tl.c
parent6873e20b753b589bfb09a3e55bb3781e9889e442 (diff)
downloadFreeBSD-src-29f07789b1fc26f60bc1c931437f78725f1bc994.zip
FreeBSD-src-29f07789b1fc26f60bc1c931437f78725f1bc994.tar.gz
Drop the driver lock around calls to if_input to avoid a LOR when
the packets are immediately returned for sending (e.g. when bridging or packet forwarding). There are more efficient ways to do this but for now use the least intrusive approach. Reviewed by: imp, rwatson
Diffstat (limited to 'sys/pci/if_tl.c')
-rw-r--r--sys/pci/if_tl.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/sys/pci/if_tl.c b/sys/pci/if_tl.c
index df7784f..dd20b2a 100644
--- a/sys/pci/if_tl.c
+++ b/sys/pci/if_tl.c
@@ -1504,6 +1504,8 @@ tl_intvec_rxeof(xsc, type)
sc = xsc;
ifp = &sc->arpcom.ac_if;
+ TL_LOCK_ASSERT(sc);
+
while(sc->tl_cdata.tl_rx_head != NULL) {
cur_rx = sc->tl_cdata.tl_rx_head;
if (!(cur_rx->tl_ptr->tlist_cstat & TL_CSTAT_FRAMECMP))
@@ -1543,7 +1545,9 @@ tl_intvec_rxeof(xsc, type)
m->m_pkthdr.rcvif = ifp;
m->m_pkthdr.len = m->m_len = total_len;
+ TL_UNLOCK(sc);
(*ifp->if_input)(ifp, m);
+ TL_LOCK(sc);
}
return(r);
OpenPOWER on IntegriCloud