summaryrefslogtreecommitdiff
path: root/lib/netns_linux.c
AgeCommit message (Collapse)Author
2018-03-31lib: Namespaces should only complain about failure if we have itDonald Sharp
Do not complain about failure to create a namespace if we do not have any such thing going on. Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
2018-03-07Merge pull request #1428 from LabNConsulting/working/master/indentDonald Sharp
frr: conform with COMMUNITY.md formatting rules
2018-03-06*: conform with COMMUNITY.md formatting rules, via 'make indent'Lou Berger
Signed-off-by: Lou Berger <lberger@labn.net>
2018-03-06lib: NS_DEFAULT wrong valuePhilippe Guibert
The NS_DEFAULT value returns UNKNOWN in the case the vrf lite backend is used, whereas this is wrong. This commit fixes the default value. Also, it fixes the default value in the case NETNS support from system is not ok, or some error can occur when reading default NS at startup. Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
2018-02-27lib: do not use ENOSYS errno when returning from nsPhilippe Guibert
ENOSYS should not be used for other goals. Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
2018-02-27lib: netns checkstyle fixPhilippe Guibert
A space is appended between RB_FOREACH and ' ', to comply with style practiced in frr. Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
2018-02-27lib: add debug guard for ns informational tracesPhilippe Guibert
Informational traces are being added. Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
2018-02-27lib: split logicalrouter and vrf netns featurePhilippe Guibert
This split is introducing logicalrouter.[ch] as the file that contains the vty commands to configure logical router feature. The split has as consequence that the backend of logical router is linux_netns.c formerly called ns.c. The same relationship exists between VRF and its backend which may be linux_netns.c file. The split is adapting ns and vrf fiels so as to : - clarify header - ensure that the daemon persepctive, the feature VRF or logical router is called instead of calling directly ns. - this implies that VRF will call NS apis, as logical router does. Also, like it is done for default NS and default VRF, the associated VRF is enabled first, before NETNS is enabled, so that zvrf->zns pointer is valid when NETNS discovery applies. Also, other_netns.c file is a stub handler that will be used for non linux systems. As NETNS feature is only used by Linux, some BSD systems may want to use the same backend API to benefit from NETNS. This is what that file has been done. Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>