summaryrefslogtreecommitdiff
path: root/ripngd/ripng_cli.c
diff options
context:
space:
mode:
authorRenato Westphal <renato@opensourcerouting.org>2018-11-28 23:51:34 -0200
committerRenato Westphal <renato@opensourcerouting.org>2018-12-03 13:47:58 -0200
commite9ce224b8543c0e432c4eb29240ffc1300bbdf6e (patch)
tree055a17df4ebfc24409c1a291e2543abbd8305629 /ripngd/ripng_cli.c
parentd801bfae853353a18b55801bfbd90c9ca90f95f2 (diff)
yang, ripngd: add 'frr-ripngd.yang' and associated stub callbacks
Introduce frr-ripngd.yang, which defines a model for managing the FRR ripngd daemon. Update the 'frr_yang_module_info' array of ripngd with the new 'frr-ripngd' module. Add two new files (ripng_cli.[ch]) which should contain all ripngd commands converted to the new northbound model. Centralizing all commands in a single place will facilitate the process of moving the CLI to a separate program in the future. Add automatically generated stub callbacks in ripng_northbound.c. These callbacks will be implemented gradually in the following commits. Add the confd.frr-ripngd.yang YANG module with annotations specific to the ConfD daemon. Signed-off-by: Renato Westphal <renato@opensourcerouting.org>
Diffstat (limited to 'ripngd/ripng_cli.c')
-rw-r--r--ripngd/ripng_cli.c39
1 files changed, 39 insertions, 0 deletions
diff --git a/ripngd/ripng_cli.c b/ripngd/ripng_cli.c
new file mode 100644
index 0000000000..b033a39ac6
--- /dev/null
+++ b/ripngd/ripng_cli.c
@@ -0,0 +1,39 @@
+/*
+ * Copyright (C) 1998 Kunihiro Ishiguro
+ * Copyright (C) 2018 NetDEF, Inc.
+ * Renato Westphal
+ *
+ * This program is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License as published by the Free
+ * Software Foundation; either version 2 of the License, or (at your option)
+ * any later version.
+ *
+ * This program is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
+ * more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; see the file COPYING; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+ */
+
+#include <zebra.h>
+
+#include "if.h"
+#include "vrf.h"
+#include "log.h"
+#include "prefix.h"
+#include "command.h"
+#include "northbound_cli.h"
+#include "libfrr.h"
+
+#include "ripngd/ripngd.h"
+#include "ripngd/ripng_cli.h"
+#ifndef VTYSH_EXTRACT_PL
+#include "ripngd/ripng_cli_clippy.c"
+#endif
+
+void ripng_cli_init(void)
+{
+}