Lines Matching refs:rt

127 	struct rtentry *rt;
155 (rt = ip6forward_rt->ro_rt) != NULL && (rt->rt_flags & RTF_PROXY)) {
157 if ((rt = ip6forward_rt->ro_rt) != NULL)
158 ifscope = rt->rt_ifp->if_index;
171 if (ifscope != IFSCOPE_NONE && (rt = ip6forward_rt->ro_rt) != NULL) {
172 RT_LOCK(rt);
173 if (rt->rt_ifp->if_index != ifscope) {
174 RT_UNLOCK(rt);
176 rt = NULL;
178 RT_UNLOCK(rt);
210 /* XXX in6_ifstat_inc(rt->rt_ifp, ifs6_in_discard) */
226 /* XXX in6_ifstat_inc(rt->rt_ifp, ifs6_in_discard) */
395 if ((rt = ip6forward_rt->ro_rt) != NULL) {
396 RT_LOCK(rt);
398 RT_ADDREF_LOCKED(rt);
401 VERIFY(rt == NULL || rt == ip6forward_rt->ro_rt);
407 if (rt != NULL) {
409 RT_REMREF_LOCKED(rt);
410 RT_UNLOCK(rt);
417 if ((rt = ip6forward_rt->ro_rt) != NULL) {
418 RT_LOCK(rt);
420 RT_ADDREF_LOCKED(rt);
424 if (rt == NULL) {
433 RT_LOCK_ASSERT_HELD(rt);
436 if (rt != NULL) {
438 RT_REMREF_LOCKED(rt);
439 RT_UNLOCK(rt);
450 if ((rt = ip6forward_rt->ro_rt) == NULL) {
459 RT_LOCK(rt);
461 RT_ADDREF_LOCKED(rt);
475 if (in6_setscope(&src_in6, rt->rt_ifp, &outzone)) {
492 in6_ifstat_inc(rt->rt_ifp, ifs6_in_discard);
502 if_name(m->m_pkthdr.rcvif), if_name(rt->rt_ifp));
505 RT_REMREF_LOCKED(rt);
506 RT_UNLOCK(rt);
524 in6_setscope(&dst_in6, rt->rt_ifp, &outzone) != 0 ||
532 if (m->m_pkthdr.len > rt->rt_ifp->if_mtu) {
533 in6_ifstat_inc(rt->rt_ifp, ifs6_in_toobig);
542 mtu = rt->rt_ifp->if_mtu;
549 * encapsulated packet as "rt->rt_ifp".
568 RT_REMREF_LOCKED(rt);
569 RT_UNLOCK(rt);
573 RT_REMREF_LOCKED(rt);
574 RT_UNLOCK(rt);
580 if (rt->rt_flags & RTF_GATEWAY)
581 dst = (struct sockaddr_in6 *)(void *)rt->rt_gateway;
593 ip6_sendredirects && rt->rt_ifp == m->m_pkthdr.rcvif && !srcrt &&
594 (rt->rt_flags & (RTF_DYNAMIC|RTF_MODIFIED)) == 0) {
595 if ((rt->rt_ifp->if_flags & IFF_POINTOPOINT) != 0) {
606 RT_REMREF_LOCKED(rt); /* Release extra ref */
607 RT_UNLOCK(rt);
622 ifp = rt->rt_ifp;
624 RT_UNLOCK(rt);
633 /* We still have the extra ref on rt */
634 RT_LOCK(rt);
646 if ((rt->rt_ifp->if_flags & IFF_LOOPBACK) != 0) {
659 if ((rt->rt_flags & (RTF_BLACKHOLE|RTF_REJECT)) == 0)
667 if_name(rt->rt_ifp));
682 origifp = rt->rt_ifp;
691 ifp = rt->rt_ifp;
693 RT_UNLOCK(rt);
701 RT_REMREF(rt);
726 error = nd6_output(ifp, origifp, m, dst, rt, NULL);
754 RT_REMREF(rt);
761 icmp6_redirect_output(mcopy, rt);
763 RT_REMREF(rt);
788 RT_REMREF(rt);
794 RT_REMREF(rt);