00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011 #ifndef ROUTE_H_
00012 #define ROUTE_H_
00013
00014 struct s_route_entry
00015 {
00016 LIST_ENTRY(s_route_entry) rt_next;
00017 int rt_ready;
00018 struct s_route rt;
00019 struct s_iface *rt_iface;
00020 };
00021
00022 LIST_HEAD(s_route_table, s_route_entry);
00023
00024
00025 #ifdef __INET__
00026
00027 struct s_route_entry *find_route(struct in_addr *dst);
00028 int route_create_entry(struct s_entry *father, char *filename, struct s_entry **new);
00029 int route_read(pid_t pid, t_of *of, char *ubuf, size_t usize);
00030 int route_set(struct s_route_entry *route, struct s_subnet *rt_subnet, struct in_addr *rt_gw);
00031 int route_write(pid_t pid, t_of *of, char *ubuf, size_t usize);
00032 #endif
00033 #endif