summaryrefslogtreecommitdiff
path: root/usr.sbin/bgpd/rde.h
diff options
context:
space:
mode:
authorClaudio Jeker <claudio@cvs.openbsd.org>2017-01-25 00:15:39 +0000
committerClaudio Jeker <claudio@cvs.openbsd.org>2017-01-25 00:15:39 +0000
commit70006cfdbb48d55071dbea8e4c8b1642d11dde62 (patch)
tree13641c2df28a47bd5919d5d1706066739d7ddedf /usr.sbin/bgpd/rde.h
parent995538d2093d90c336c36e38a6d0f656f4bce2a2 (diff)
Switch rde_generate_update and rde_send_kroute to accept a struct rib instead
of the id. For this we move the rtableid into struct rib. Also move the update code in rib.c up to where the kroute code is. Makes more senses like that.
Diffstat (limited to 'usr.sbin/bgpd/rde.h')
-rw-r--r--usr.sbin/bgpd/rde.h34
1 files changed, 17 insertions, 17 deletions
diff --git a/usr.sbin/bgpd/rde.h b/usr.sbin/bgpd/rde.h
index d2228b6808a..a51637cebd0 100644
--- a/usr.sbin/bgpd/rde.h
+++ b/usr.sbin/bgpd/rde.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: rde.h,v 1.158 2017/01/24 23:38:12 claudio Exp $ */
+/* $OpenBSD: rde.h,v 1.159 2017/01/25 00:15:38 claudio Exp $ */
/*
* Copyright (c) 2003, 2004 Claudio Jeker <claudio@openbsd.org> and
@@ -288,6 +288,7 @@ struct rib_entry {
struct rib {
struct rib_tree tree;
+ u_int rtableid;
u_int16_t flags;
u_int16_t id;
};
@@ -297,7 +298,6 @@ struct rib_desc {
struct rib rib;
struct filter_head *in_rules;
struct filter_head *in_rules_tmp;
- u_int rtableid;
enum reconf_action state;
};
@@ -313,24 +313,24 @@ extern struct rde_memstats rdemem;
/* prototypes */
/* mrt.c */
-int mrt_dump_v2_hdr(struct mrt *, struct bgpd_config *,
+int mrt_dump_v2_hdr(struct mrt *, struct bgpd_config *,
struct rde_peer_head *);
-void mrt_dump_upcall(struct rib_entry *, void *);
-void mrt_done(void *);
+void mrt_dump_upcall(struct rib_entry *, void *);
+void mrt_done(void *);
/* rde.c */
-void rde_send_kroute(struct prefix *, struct prefix *, u_int16_t);
-void rde_send_nexthop(struct bgpd_addr *, int);
-void rde_send_pftable(u_int16_t, struct bgpd_addr *,
- u_int8_t, int);
-void rde_send_pftable_commit(void);
-
-void rde_generate_updates(u_int16_t, struct prefix *,
- struct prefix *);
-u_int32_t rde_local_as(void);
-int rde_noevaluate(void);
-int rde_decisionflags(void);
-int rde_as4byte(struct rde_peer *);
+void rde_send_kroute(struct rib *, struct prefix *, struct prefix *);
+void rde_send_nexthop(struct bgpd_addr *, int);
+void rde_send_pftable(u_int16_t, struct bgpd_addr *,
+ u_int8_t, int);
+void rde_send_pftable_commit(void);
+
+void rde_generate_updates(struct rib *, struct prefix *,
+ struct prefix *);
+u_int32_t rde_local_as(void);
+int rde_noevaluate(void);
+int rde_decisionflags(void);
+int rde_as4byte(struct rde_peer *);
/* rde_attr.c */
int attr_write(void *, u_int16_t, u_int8_t, u_int8_t, void *,