diff options
author | Philippe Guibert <philippe.guibert@6wind.com> | 2017-12-20 12:29:21 +0100 |
---|---|---|
committer | Philippe Guibert <philippe.guibert@6wind.com> | 2018-02-27 11:11:24 +0100 |
commit | ce1be3692f809cfa4d533d484a75653f91c24c4e (patch) | |
tree | d6a151cb9d906b8e1f517b641fabd39b741ef3a0 /lib/vrf.h | |
parent | lib: add namespace name structure in zebra message (diff) | |
download | frr-ce1be3692f809cfa4d533d484a75653f91c24c4e.tar.xz frr-ce1be3692f809cfa4d533d484a75653f91c24c4e.zip |
lib: provide an API to switch from one netns to an other
Two apis are provided so that the switch from one netns to an other one
is taken care.
Also an other API to know if the VRF has a NETNS backend or a VRF Lite
backend.
Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
Diffstat (limited to 'lib/vrf.h')
-rw-r--r-- | lib/vrf.h | 7 |
1 files changed, 7 insertions, 0 deletions
@@ -218,6 +218,13 @@ extern int vrf_handler_create(struct vty *vty, const char *name, struct vrf **vrf); +/* VRF is mapped on netns or not ? */ +int vrf_is_mapped_on_netns(vrf_id_t vrf_id); + +/* VRF switch from NETNS */ +extern int vrf_switch_to_netns(vrf_id_t vrf_id); +extern int vrf_switchback_to_initial(void); + /* used by NS when vrf backend is NS. * Notify a change in the VRF ID of the VRF */ |