Lines Matching defs:dr
249 struct nd_defrouter *dr;
318 dr = defrtrlist_update(&dr0);
391 (void)prelist_update(&pr, dr, m);
583 struct nd_defrouter *dr;
588 for (dr = TAILQ_FIRST(&nd_defrouter); dr;
589 dr = TAILQ_NEXT(dr, dr_entry)) {
590 if (dr->ifp == ifp && IN6_ARE_ADDR_EQUAL(addr, &dr->rtaddr))
591 return(dr);
599 struct nd_defrouter *dr,
612 gate.sin6_addr = dr->rtaddr;
625 FREE(dr, M_IP6NDP);
631 struct nd_defrouter *dr, int nd6locked)
634 struct nd_ifinfo *ndi = &nd_ifinfo[dr->ifp->if_index];
641 if (!ip6_forwarding && (ip6_accept_rtadv || (dr->ifp->if_eflags & IFEF_ACCEPT_RTADVD))) {
643 rt6_flush(&dr->rtaddr, dr->ifp);
648 if (dr == TAILQ_FIRST(&nd_defrouter))
649 deldr = dr; /* The router is primary. */
651 TAILQ_REMOVE(&nd_defrouter, dr, dr_entry);
658 if ((pfxrtr = pfxrtr_lookup(pr, dr)) != NULL)
674 if_name(dr->ifp));
680 FREE(dr, M_IP6NDP);
696 struct nd_defrouter *dr, anydr;
705 for (dr = TAILQ_FIRST(&nd_defrouter); dr;
706 dr = TAILQ_NEXT(dr, dr_entry)) {
707 if ((rt = nd6_lookup(&dr->rtaddr, 0, dr->ifp, 0)) &&
711 TAILQ_REMOVE(&nd_defrouter, dr, dr_entry);
712 TAILQ_INSERT_HEAD(&nd_defrouter, dr, dr_entry);
717 if ((dr = TAILQ_FIRST(&nd_defrouter))) {
727 defrouter_addreq(dr);
769 struct nd_defrouter *dr, *n;
773 if ((dr = defrouter_lookup(&new->rtaddr, new->ifp)) != NULL) {
776 defrtrlist_del(dr, 1);
777 dr = NULL;
780 dr->flags = new->flags; /* xxx flag check */
781 dr->rtlifetime = new->rtlifetime;
782 dr->expire = new->expire;
785 return(dr);
826 struct nd_defrouter *dr)
832 if (search->router == dr)
842 struct nd_defrouter *dr)
852 new->router = dr;
961 struct nd_defrouter *dr,
1011 if (dr) {
1012 pfxrtr_add(new, dr);
1083 struct nd_defrouter *dr, /* may be NULL */
1147 if (dr && pfxrtr_lookup(pr, dr) == NULL)
1148 pfxrtr_add(pr, dr);
1162 error = nd6_prelist_add(new, dr, &newpr);