summaryrefslogtreecommitdiffstats
path: root/bgpd/bgp_table.h
diff options
context:
space:
mode:
authorDonald Sharp <sharpd@cumulusnetworks.com>2018-09-19 14:20:37 +0200
committerDonald Sharp <sharpd@cumulusnetworks.com>2018-09-22 21:03:01 +0200
commit14315f2d69a1b1d41b4eaf557b352d26be9e7fc7 (patch)
tree12539f365938bac7a8fa1a5040c3e93b6034ff22 /bgpd/bgp_table.h
parentbgpd: Abstract bgp_connected_ref retrieving/setting from info pointer (diff)
downloadfrr-14315f2d69a1b1d41b4eaf557b352d26be9e7fc7.tar.xz
frr-14315f2d69a1b1d41b4eaf557b352d26be9e7fc7.zip
bgpd: Abstract bgp_nexthop_cache retrieving/setting from info pointer
The bgp_nexthop_cache data is stored as a void pointer in `struct bgp_node`. Abstract retrieval of this data and setting of this data into functions so that in the future we can move around what is stored in bgp_node. Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
Diffstat (limited to 'bgpd/bgp_table.h')
-rw-r--r--bgpd/bgp_table.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/bgpd/bgp_table.h b/bgpd/bgp_table.h
index f60265b51..bec95c71a 100644
--- a/bgpd/bgp_table.h
+++ b/bgpd/bgp_table.h
@@ -360,4 +360,16 @@ static inline void bgp_connected_set_node_info(struct bgp_node *node,
node->info = bc;
}
+static inline struct bgp_nexthop_cache *
+bgp_nexthop_get_node_info(struct bgp_node *node)
+{
+ return node->info;
+}
+
+static inline void bgp_nexthop_set_node_info(struct bgp_node *node,
+ struct bgp_nexthop_cache *bnc)
+{
+ node->info = bnc;
+}
+
#endif /* _QUAGGA_BGP_TABLE_H */