summaryrefslogtreecommitdiffstats
path: root/babeld/babel_interface.c
diff options
context:
space:
mode:
authorPhilippe Guibert <philippe.guibert@6wind.com>2018-12-04 15:45:57 +0100
committerPhilippe Guibert <philippe.guibert@6wind.com>2018-12-28 18:18:40 +0100
commit03a38493f8b319a3fac139c8898eac53001ad151 (patch)
treef90987f91bf09457877e01b1c6d694eec3ec3ee0 /babeld/babel_interface.c
parentlib: enforce vrf_name_to_id by returning default_vrf when name is null (diff)
downloadfrr-03a38493f8b319a3fac139c8898eac53001ad151.tar.xz
frr-03a38493f8b319a3fac139c8898eac53001ad151.zip
lib, rip, ripng, babel, eigrp: add ctx pointer to distribute api
a distribute_ctx context pointer is returned after initialisation to the calling daemon. this context pointer will be further used to do discussion with distribute service. Today, there is no specific problem with old api, since the pointer is the same in all the memory process. but the pointer will be different if we have multiple instances. Right now, this is not the case, but if that happens, that work will be used for that. distribute-list initialisation is split in two. the vty initialisation is done at global level, while the context initialisation is done for each routing daemon instance. babel daemon is being equipped with a routing returning the main babel instance. also, a delete routine is available when the daemon routing instance is suppressed. a list of contexts is used inside distribute_list. This will permit distribute_list utility to handle in the same daemon to handle more than one context. This will be very useful in the vrf context. Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
Diffstat (limited to 'babeld/babel_interface.c')
-rw-r--r--babeld/babel_interface.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/babeld/babel_interface.c b/babeld/babel_interface.c
index 7121ca28d..a8698bfce 100644
--- a/babeld/babel_interface.c
+++ b/babeld/babel_interface.c
@@ -1248,11 +1248,16 @@ DEFUN (show_babel_parameters,
"Babel information\n"
"Configuration information\n")
{
+ struct babel *babel_ctx;
+
vty_out (vty, " -- Babel running configuration --\n");
show_babel_main_configuration(vty);
- vty_out (vty, " -- distribution lists --\n");
- config_show_distribute(vty);
+ babel_ctx = babel_lookup();
+ if (babel_ctx) {
+ vty_out (vty, " -- distribution lists --\n");
+ config_show_distribute(vty, babel_ctx->distribute_ctx);
+ }
return CMD_SUCCESS;
}