summaryrefslogtreecommitdiffstats
path: root/nest/route.h
diff options
context:
space:
mode:
authorMartin Mares <mj@ucw.cz>1998-10-20 17:13:18 +0200
committerMartin Mares <mj@ucw.cz>1998-10-20 17:13:18 +0200
commita0762910a62085d875b5bf5e1494c4fdde6f603f (patch)
treefd7d94a5b8abf9c06b98c4b2596a4050ad2fe295 /nest/route.h
parentb6903c948b2325f11cfb07f2df0590708920b987 (diff)
downloadbird-a0762910a62085d875b5bf5e1494c4fdde6f603f.tar
bird-a0762910a62085d875b5bf5e1494c4fdde6f603f.zip
Added pointer to network to RTE. The complications with passing NET separately
aren't worth 4 bytes per RTE. rte_discard and rte_dump don't need net * as parameter.
Diffstat (limited to 'nest/route.h')
-rw-r--r--nest/route.h7
1 files changed, 4 insertions, 3 deletions
diff --git a/nest/route.h b/nest/route.h
index 39c6ef7..d3a1304 100644
--- a/nest/route.h
+++ b/nest/route.h
@@ -85,7 +85,8 @@ typedef struct network {
typedef struct rte {
struct rte *next;
- struct rtattr *attrs;
+ net *net; /* Network this RTE belongs to */
+ struct rtattr *attrs; /* Attributes of this route */
byte flags; /* Flags (REF_...) */
byte pflags; /* Protocol-specific flags */
word pref; /* Route preference */
@@ -125,8 +126,8 @@ net *net_get(rtable *tab, unsigned tos, ip_addr addr, unsigned len);
rte *rte_find(net *net, struct proto *p);
rte *rte_get_temp(struct rtattr *);
void rte_update(net *net, struct proto *p, rte *new);
-void rte_discard(net *net, rte *old);
-void rte_dump(net *, rte *);
+void rte_discard(rte *old);
+void rte_dump(rte *);
void rt_dump(rtable *);
void rt_dump_all(void);
void rt_feed_baby(struct proto *p);