• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /macosx-10.5.8/xnu-1228.15.4/bsd/net/

Lines Matching defs:gateway

649 		 * This also frees the gateway, as they are always malloc'd
797 * destination to go through the given gateway.
802 rtredirect(struct ifnet *ifp, struct sockaddr *dst, struct sockaddr *gateway,
818 * Verify the gateway is directly reachable; if scoped routing
822 if ((ifa = ifa_ifwithnet_scoped(gateway, ifscope)) == NULL) {
846 if ((ifa = ifa_ifwithaddr(gateway))) {
883 gateway, netmask, flags, NULL, ifscope);
887 * Smash the current notion of the gateway to
894 * add the key and gateway (in one malloc'd chunk).
896 error = rt_setgate(rt, rt_key(rt), gateway);
919 info.rti_info[RTAX_GATEWAY] = gateway;
944 const struct sockaddr *gateway)
949 ifa = ifa_ifwithroute_locked(flags, dst, gateway);
957 const struct sockaddr *gateway)
960 gateway, IFSCOPE_NONE));
965 const struct sockaddr *gateway, unsigned int ifscope)
972 return (ifa_ifwithroute_common_locked(flags, dst, gateway, ifscope));
977 const struct sockaddr *gateway, unsigned int ifscope)
993 if (gateway != NULL && gateway->sa_family == AF_INET)
994 gateway = sin_copy(SIN(gateway), &gw_in, IFSCOPE_NONE);
1009 ifa = ifa_ifwithaddr_scoped(gateway, ifscope);
1013 * or host, the gateway may still be on the
1016 ifa = ifa_ifwithdstaddr(gateway);
1019 ifa = ifa_ifwithnet_scoped(gateway, ifscope);
1042 * If we are adding a gateway, it is quite possible that the
1043 * routing table has a static entry in place for the gateway,
1047 * on new entries from rtinit, hence (ifa->ifa_addr != gateway).
1050 !equal(ifa->ifa_addr, (struct sockaddr *)(size_t)gateway)) &&
1051 (rt = rtalloc1_scoped_locked((struct sockaddr *)(size_t)gateway,
1085 rtrequest_locked(int req, struct sockaddr *dst, struct sockaddr *gateway,
1088 return (rtrequest_common_locked(req, dst, gateway, netmask,
1094 struct sockaddr *gateway, struct sockaddr *netmask, int flags,
1102 return (rtrequest_common_locked(req, dst, gateway, netmask,
1123 struct sockaddr *gateway, struct sockaddr *netmask, int flags,
1269 gateway = rt->rt_gateway;
1303 if ((flags & RTF_GATEWAY) && !gateway)
1304 panic("rtrequest: RTF_GATEWAY but no gateway");
1308 gateway, ifscope);
1310 ifa = ifa_ifwithroute_locked(flags, dst0, gateway);
1321 * Add the gateway. Possibly re-malloc-ing the storage for it
1324 if ((error = rt_setgate(rt, dst, gateway)) != 0) {
1464 struct sockaddr *gateway,
1472 error = rtrequest_locked(req, dst, gateway, netmask, flags, ret_nrt);
1576 * A host route with the destination equal to the gateway
1595 * to the next-hop gateway and store it in rt_gwroute.
1615 * through itself as a gateway. This is obviously mandatory
1617 * the gateway must already be present in the system in order
1618 * for the gateway to be referred to by another route.
1625 /* If scoped, the gateway route must use the same interface */
1648 * Tell the kernel debugger about the new default gateway
1649 * if the gateway route uses the primary interface, or
1651 * default gateway is installed (similar to how the system
1663 * Prepare to store the gateway in rt_gateway. Both dst and gateway
1693 * Copy the new gateway value into the memory chunk.
1801 * the same destination (but not necessarily the same gateway) to exist in