tech-net archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

failure to fetch route from selectroute



Hi,

I am presently working on NetBSD version5. I see that in the function 
nd6_ns_output we call the function in6_selectsrc routine to select the source 
src address.

in6_selectsrc calls in6_selectif which in turn calls selectroute to select the 
route to the destination. In the function select route I see that

if (IN6_IS_ADDR_MULTICAST(dst) &&
            mopts != NULL && (ifp = mopts->im6o_multicast_ifp) != NULL) {
                goto done; /* we do not need a route for multicast. */
        }

*No need for a route if the destination is a multicast. But to choose the route 
at this place mopts should be set.

Now my doubt is if no need to get a route if the destination is a multicast 
then 
why in6_selectsrc route was called with mopts NULL in the first place in the 
routine nd6_ns_output.

nd6_ns_output(struct ifnet *ifp, const struct in6_addr *daddr6, 
                  const struct in6_addr *taddr6, struct llentry *ln, int dad) 
{
    ...........................
      error = in6_selectsrc(&dst_sa, NULL,
                                 NULL, &ro, NULL, NULL, &src_in);
}

I was trying to ping two back to back connect systems and I see failure in 
selectroute routine as it fails to allocate a route.

Thanks,
Raghav



Home | Main Index | Thread Index | Old Index