summaryrefslogtreecommitdiff
path: root/bgpd/bgp_table.h
diff options
context:
space:
mode:
authorDonald Sharp <sharpd@cumulusnetworks.com>2018-09-25 20:37:16 -0400
committerDonald Sharp <sharpd@cumulusnetworks.com>2018-11-16 09:43:35 -0500
commit67009e2200b70563b5b2eb1ca5752d7fafe6902c (patch)
treea07b7f41b1d287a87551fc441aa29a5101064451 /bgpd/bgp_table.h
parent6f94b685d0480f7ea427ddfd1c603399dd047aa3 (diff)
bgpd: Abstract bgp_table retrieving/setting from info pointer
Convert the set/get of bgp_table's from the info pointer. 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 87fbc39f43..ee21e74a15 100644
--- a/bgpd/bgp_table.h
+++ b/bgpd/bgp_table.h
@@ -388,6 +388,18 @@ static inline void bgp_node_set_bgp_path_info(struct bgp_node *node,
node->info = bi;
}
+static inline struct bgp_table *
+bgp_node_get_bgp_table_info(struct bgp_node *node)
+{
+ return node->info;
+}
+
+static inline void bgp_node_set_bgp_table_info(struct bgp_node *node,
+ struct bgp_table *table)
+{
+ node->info = table;
+}
+
static inline bool bgp_node_has_bgp_path_info_data(struct bgp_node *node)
{
return !!node->info;