Lines Matching defs:lc

81 tcp_lro_init(struct lro_ctrl *lc)
86 lc->lro_bad_csum = 0;
87 lc->lro_queued = 0;
88 lc->lro_flushed = 0;
89 lc->lro_cnt = 0;
90 SLIST_INIT(&lc->lro_free);
91 SLIST_INIT(&lc->lro_active);
102 lc->lro_cnt = i + 1;
103 SLIST_INSERT_HEAD(&lc->lro_free, le, next);
110 tcp_lro_free(struct lro_ctrl *lc)
114 while (!SLIST_EMPTY(&lc->lro_free)) {
115 le = SLIST_FIRST(&lc->lro_free);
116 SLIST_REMOVE_HEAD(&lc->lro_free, next);
207 tcp_lro_flush_inactive(struct lro_ctrl *lc, const struct timeval *timeout)
212 if (SLIST_EMPTY(&lc->lro_active))
217 SLIST_FOREACH_SAFE(le, &lc->lro_active, next, le_tmp) {
219 SLIST_REMOVE(&lc->lro_active, le, lro_entry, next);
220 tcp_lro_flush(lc, le);
226 tcp_lro_flush(struct lro_ctrl *lc, struct lro_entry *le)
311 (*lc->ifp->if_input)(lc->ifp, le->m_head);
312 lc->lro_queued += le->append_cnt + 1;
313 lc->lro_flushed++;
315 SLIST_INSERT_HEAD(&lc->lro_free, le, next);
320 tcp_lro_rx_ipv6(struct lro_ctrl *lc, struct mbuf *m, struct ip6_hdr *ip6,
339 tcp_lro_rx_ipv4(struct lro_ctrl *lc, struct mbuf *m, struct ip *ip4,
360 lc->lro_bad_csum++;
366 lc->lro_bad_csum++;
379 tcp_lro_rx(struct lro_ctrl *lc, struct mbuf *m, uint32_t csum)
405 CURVNET_SET(lc->ifp->if_vnet);
413 error = tcp_lro_rx_ipv6(lc, m, ip6, &th);
424 CURVNET_SET(lc->ifp->if_vnet);
432 error = tcp_lro_rx_ipv4(lc, m, ip4, &th);
501 SLIST_FOREACH(le, &lc->lro_active, next) {
528 SLIST_REMOVE(&lc->lro_active, le, lro_entry, next);
529 tcp_lro_flush(lc, le);
535 SLIST_REMOVE(&lc->lro_active, le, lro_entry, next);
536 tcp_lro_flush(lc, le);
544 SLIST_REMOVE(&lc->lro_active, le, lro_entry, next);
545 tcp_lro_flush(lc, le);
592 if (le->p_len > (65535 - lc->ifp->if_mtu)) {
593 SLIST_REMOVE(&lc->lro_active, le, lro_entry, next);
594 tcp_lro_flush(lc, le);
610 if (SLIST_EMPTY(&lc->lro_free))
614 le = SLIST_FIRST(&lc->lro_free);
615 SLIST_REMOVE_HEAD(&lc->lro_free, next);
616 SLIST_INSERT_HEAD(&lc->lro_active, le, next);