summaryrefslogtreecommitdiffstats
path: root/lib/yang.h
diff options
context:
space:
mode:
authorRenato Westphal <renato@opensourcerouting.org>2018-11-13 22:30:24 +0100
committerRenato Westphal <renato@opensourcerouting.org>2018-11-26 20:36:34 +0100
commita1b5f469e70333042c2a0bd7e98bc4e69f4a0237 (patch)
tree270f93edc8e94ba17b5f9d95e5d56ba04c4e8c1b /lib/yang.h
parentlib: remove entire data tree on yang_dnode_free() (diff)
downloadfrr-a1b5f469e70333042c2a0bd7e98bc4e69f4a0237.tar.xz
frr-a1b5f469e70333042c2a0bd7e98bc4e69f4a0237.zip
lib: introduce function that loads all FRR native YANG modules
In some cases it will be necessary to load all FRR native modules. Examples: * vtysh needs to load all YANG modules so that it can manipulate data from all daemons. * The gen_northbound_callbacks tool will need to load all YANG modules since augmentations from one module can have an effect in the required northbound callbacks of other modules. The new yang_module_load_all() function provides this functionality. As a side note, the "frr_native_modules" will need to be updated every time we add a new YANG module to FRR. Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
Diffstat (limited to 'lib/yang.h')
-rw-r--r--lib/yang.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/lib/yang.h b/lib/yang.h
index b55d7bcb5..aa08654ab 100644
--- a/lib/yang.h
+++ b/lib/yang.h
@@ -115,6 +115,11 @@ extern struct yang_modules yang_modules;
extern struct yang_module *yang_module_load(const char *module_name);
/*
+ * Load all FRR native YANG models.
+ */
+extern void yang_module_load_all(void);
+
+/*
* Find a YANG module by its name.
*
* module_name