pim6d: Adding show running for ipv6 mld commands

Signed-off-by: Mobashshera Rasool <mrasool@vmware.com>
This commit is contained in:
Sai Gomathi N 2022-01-19 05:16:55 -08:00 committed by Mobashshera Rasool
parent 078c5867a1
commit d17b6892fc
5 changed files with 19 additions and 20 deletions

View File

@ -50,15 +50,15 @@ void pim_bfd_write_config(struct vty *vty, struct interface *ifp)
if (pim_ifp->bfd_config.detection_multiplier != BFD_DEF_DETECT_MULT
|| pim_ifp->bfd_config.min_rx != BFD_DEF_MIN_RX
|| pim_ifp->bfd_config.min_tx != BFD_DEF_MIN_TX)
vty_out(vty, " ip pim bfd %d %d %d\n",
vty_out(vty, " " PIM_AF_NAME " pim bfd %d %d %d\n",
pim_ifp->bfd_config.detection_multiplier,
pim_ifp->bfd_config.min_rx, pim_ifp->bfd_config.min_tx);
else
#endif /* ! HAVE_BFDD */
vty_out(vty, " ip pim bfd\n");
vty_out(vty, " " PIM_AF_NAME " pim bfd\n");
if (pim_ifp->bfd_config.profile)
vty_out(vty, " ip pim bfd profile %s\n",
vty_out(vty, " " PIM_AF_NAME " pim bfd profile %s\n",
pim_ifp->bfd_config.profile);
}

View File

@ -59,9 +59,9 @@ void pim_bsm_write_config(struct vty *vty, struct interface *ifp)
if (pim_ifp) {
if (!pim_ifp->bsm_enable)
vty_out(vty, " no ip pim bsm\n");
vty_out(vty, " no " PIM_AF_NAME " pim bsm\n");
if (!pim_ifp->ucast_bsm_accept)
vty_out(vty, " no ip pim unicast-bsm\n");
vty_out(vty, " no " PIM_AF_NAME " pim unicast-bsm\n");
}
}

View File

@ -305,11 +305,11 @@ int pim_static_write_mroute(struct pim_instance *pim, struct vty *vty,
i);
if (pim_addr_is_any(sroute->source))
vty_out(vty,
" ip mroute %s %pPA\n",
" " PIM_AF_NAME " mroute %s %pPA\n",
oifp->name, &sroute->group);
else
vty_out(vty,
" ip mroute %s %pPA %pPA\n",
" " PIM_AF_NAME " mroute %s %pPA %pPA\n",
oifp->name, &sroute->group,
&sroute->source);
count++;

View File

@ -353,48 +353,49 @@ static int pim_igmp_config_write(struct vty *vty, int writes,
}
#endif
#if PIM_IPV == 4
int pim_config_write(struct vty *vty, int writes, struct interface *ifp,
struct pim_instance *pim)
{
struct pim_interface *pim_ifp = ifp->info;
if (PIM_IF_TEST_PIM(pim_ifp->options)) {
vty_out(vty, " ip pim\n");
vty_out(vty, " " PIM_AF_NAME " pim\n");
++writes;
}
/* IF ip pim drpriority */
if (pim_ifp->pim_dr_priority != PIM_DEFAULT_DR_PRIORITY) {
vty_out(vty, " ip pim drpriority %u\n",
vty_out(vty, " " PIM_AF_NAME " pim drpriority %u\n",
pim_ifp->pim_dr_priority);
++writes;
}
/* IF ip pim hello */
if (pim_ifp->pim_hello_period != PIM_DEFAULT_HELLO_PERIOD) {
vty_out(vty, " ip pim hello %d", pim_ifp->pim_hello_period);
vty_out(vty, " " PIM_AF_NAME " pim hello %d", pim_ifp->pim_hello_period);
if (pim_ifp->pim_default_holdtime != -1)
vty_out(vty, " %d", pim_ifp->pim_default_holdtime);
vty_out(vty, "\n");
++writes;
}
#if PIM_IPV == 4
writes += pim_igmp_config_write(vty, writes, pim_ifp);
#endif
/* update source */
if (!pim_addr_is_any(pim_ifp->update_source)) {
vty_out(vty, " ip pim use-source %pPA\n",
vty_out(vty, " " PIM_AF_NAME " pim use-source %pPA\n",
&pim_ifp->update_source);
++writes;
}
if (pim_ifp->activeactive)
vty_out(vty, " ip pim active-active\n");
vty_out(vty, " " PIM_AF_NAME " pim active-active\n");
/* boundary */
if (pim_ifp->boundary_oil_plist) {
vty_out(vty, " ip multicast boundary oil %s\n",
vty_out(vty, " " PIM_AF_NAME " multicast boundary oil %s\n",
pim_ifp->boundary_oil_plist);
++writes;
}
@ -407,7 +408,6 @@ int pim_config_write(struct vty *vty, int writes, struct interface *ifp,
return writes;
}
#endif
int pim_interface_config_write(struct vty *vty)
{
@ -438,11 +438,12 @@ int pim_interface_config_write(struct vty *vty)
vty_out(vty, " description %s\n", ifp->desc);
++writes;
}
#if PIM_IPV == 4
if (ifp->info)
if (ifp->info) {
pim_config_write(vty, writes, ifp, pim);
#endif
}
if_vty_config_end(vty);
++writes;
}
}

View File

@ -25,8 +25,6 @@
int pim_debug_config_write(struct vty *vty);
int pim_global_config_write_worker(struct pim_instance *pim, struct vty *vty);
int pim_interface_config_write(struct vty *vty);
#if PIM_IPV == 4
int pim_config_write(struct vty *vty, int writes, struct interface *ifp,
struct pim_instance *pim);
#endif
#endif /* PIM_VTY_H */