Lines Matching refs:interface
51 static struct interface *ahash_tbl[AHASH_LEN];
55 static struct interface *bhash_tbl[BHASH_LEN];
58 /* hash for physical interface names.
63 static struct interface *nhash_tbl[NHASH_LEN];
77 int have_ripv1_out; /* have a RIPv1 interface */
81 static void if_bad(struct interface *);
82 static int addrouteforif(struct interface *);
84 static struct interface**
97 /* Link a new interface into the lists and hash tables.
100 if_link(struct interface *ifp)
102 struct interface **hifp;
136 /* Find the interface with an address
138 struct interface *
143 struct interface *ifp, *possible = NULL;
174 /* find the interface with a name
176 static struct interface *
180 struct interface *ifp;
186 * for the interface with the target name and address.
194 /* If there is no known interface, maybe there is a
195 * new interface. So just once look for new interfaces.
204 struct interface *
208 struct interface *ifp;
216 /* If there is no known interface, maybe there is a
217 * new interface. So just once look for new interfaces.
227 /* Find an interface from which the specified address
229 * interface a packet came in on.
231 struct interface *
234 struct interface *ifp, *maybe;
263 /* If there is no known interface, maybe there is a
264 * new interface. So just once look for new interfaces.
289 * on the given interface for a given network.
290 * If no interface is specified, look for the best fitting interface.
294 struct interface *ifp) /* as seen on this interface */
303 /* If the target network is that of the associated interface
304 * on which it arrived, then use the netmask of the interface.
311 * to have the same network number of an interface, use the
312 * netmask of that interface. If there is more than one
313 * such interface, prefer the interface with the longest
345 struct interface *ifp) /* as seen on this interface */
378 /* See a new interface duplicates an existing interface.
380 struct interface *
386 struct interface *ifp;
414 check_remote(struct interface *ifp)
441 /* Delete an interface.
444 ifdel(struct interface *ifp)
446 struct interface *ifp1;
469 /* delete aliases when the main interface dies
507 /* Zap all routes associated with this interface.
508 * Assume routes just using gateways beyond this interface
521 /* Mark an interface ill.
524 if_sick(struct interface *ifp)
536 /* Mark an interface dead.
539 if_bad(struct interface *ifp)
541 struct interface *ifp1;
568 /* Mark an interface alive
571 if_ok(struct interface *ifp,
574 struct interface *ifp1;
654 struct interface ifs, ifs0, *ifp, *ifp1;
678 /* Fetch the interface list, without too many system calls
745 /* Prepare for the next address of this interface, which
865 /* Use a minimum metric of one. Treat the interface metric
869 * interface addresses is wrong. It is not set by the
893 /* See if this is a familiar interface.
917 * a changed interface.
919 trace_act("interface %s has changed",
937 msglog("interface %s to %s turned off",
944 trace_act("interface %s has been off"
961 * see if the interface is broken.
970 /* If the interface just awoke, restart the counters.
979 * counters wrap or the interface is reset.
998 trace_act("interface %s to %s"
1008 msglog("interface %s to %s broken:"
1025 /* This is a new interface.
1031 /* If it duplicates an existing interface,
1076 ifp = (struct interface *)rtmalloc(sizeof(*ifp), "ifinit ifp");
1168 trace_act("interface %s has disappeared",
1178 /* If we ever have a RIPv1 interface, assume we always will.
1255 check_net_syn(struct interface *ifp)
1262 * for this interface only if we are running RIPv1 on some other
1263 * interface that is on a different class-A,B,or C network.
1297 /* Add route for interface if not currently installed.
1301 static int /* 0=bad interface */
1302 addrouteforif(struct interface *ifp)
1314 /* If the interface on a subnet, then install a RIPv1 route to
1338 /* We are finished if the correct main interface route exists.
1339 * The right route must be for the right interface, not synthesized
1360 trace_act("re-install interface %s",