From 966fcb6c0fc714ba84c2fd63c536dd6d3aba2be6 Mon Sep 17 00:00:00 2001 From: Igor Ryzhov Date: Tue, 23 Jan 2024 17:18:41 +0200 Subject: zebra: convert interface ipv6 nd mtu command to NB Signed-off-by: Igor Ryzhov --- zebra/zebra_nb_config.c | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) (limited to 'zebra/zebra_nb_config.c') diff --git a/zebra/zebra_nb_config.c b/zebra/zebra_nb_config.c index ef6ea012d..91ed6f5e1 100644 --- a/zebra/zebra_nb_config.c +++ b/zebra/zebra_nb_config.c @@ -2551,6 +2551,29 @@ int lib_interface_zebra_ipv6_router_advertisements_other_config_flag_modify( return NB_OK; } +/* + * XPath: /frr-interface:lib/interface/frr-zebra:zebra/ipv6-router-advertisements/link-mtu + */ +int lib_interface_zebra_ipv6_router_advertisements_link_mtu_modify( + struct nb_cb_modify_args *args) +{ + struct interface *ifp; + struct zebra_if *zif; + uint32_t mtu; + + if (args->event != NB_EV_APPLY) + return NB_OK; + + ifp = nb_running_get_entry(args->dnode, NULL, true); + zif = ifp->info; + + mtu = yang_dnode_get_uint32(args->dnode, NULL); + + zif->rtadv.AdvLinkMTU = mtu; + + return NB_OK; +} + /* * XPath: /frr-interface:lib/interface/frr-zebra:zebra/ipv6-router-advertisements/reachable-time */ -- cgit v1.2.3