diff options
Diffstat (limited to 'lib/yang.c')
| -rw-r--r-- | lib/yang.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/lib/yang.c b/lib/yang.c index 73f63b18e4..011fff65a2 100644 --- a/lib/yang.c +++ b/lib/yang.c @@ -71,6 +71,11 @@ static const char *yang_module_imp_clb(const char *mod_name, return NULL; } +static const char * const frr_native_modules[] = { + "frr-interface", + "frr-ripd", +}; + /* Generate the yang_modules tree. */ static inline int yang_module_compare(const struct yang_module *a, const struct yang_module *b) @@ -108,6 +113,12 @@ struct yang_module *yang_module_load(const char *module_name) return module; } +void yang_module_load_all(void) +{ + for (size_t i = 0; i < array_size(frr_native_modules); i++) + yang_module_load(frr_native_modules[i]); +} + struct yang_module *yang_module_find(const char *module_name) { struct yang_module s; |
