summaryrefslogtreecommitdiffstats
path: root/lib/routing_nb.h
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-28 09:53:30 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-28 09:53:30 +0000
commit2c7cac91ed6e7db0f6937923d2b57f97dbdbc337 (patch)
treec05dc0f8e6aa3accc84e3e5cffc933ed94941383 /lib/routing_nb.h
parentInitial commit. (diff)
downloadfrr-2c7cac91ed6e7db0f6937923d2b57f97dbdbc337.tar.xz
frr-2c7cac91ed6e7db0f6937923d2b57f97dbdbc337.zip
Adding upstream version 8.4.4.upstream/8.4.4upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'lib/routing_nb.h')
-rw-r--r--lib/routing_nb.h39
1 files changed, 39 insertions, 0 deletions
diff --git a/lib/routing_nb.h b/lib/routing_nb.h
new file mode 100644
index 0000000..c185091
--- /dev/null
+++ b/lib/routing_nb.h
@@ -0,0 +1,39 @@
+#ifndef _FRR_ROUTING_NB_H_
+#define _FRR_ROUTING_NB_H_
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+extern const struct frr_yang_module_info frr_routing_info;
+
+/* Mandatory callbacks. */
+int routing_control_plane_protocols_control_plane_protocol_create(
+ struct nb_cb_create_args *args);
+int routing_control_plane_protocols_control_plane_protocol_destroy(
+ struct nb_cb_destroy_args *args);
+
+#define FRR_ROUTING_XPATH \
+ "/frr-routing:routing/control-plane-protocols/control-plane-protocol"
+
+#define FRR_ROUTING_KEY_XPATH \
+ "/frr-routing:routing/control-plane-protocols/" \
+ "control-plane-protocol[type='%s'][name='%s'][vrf='%s']"
+
+#define FRR_ROUTING_KEY_XPATH_VRF \
+ "/frr-routing:routing/control-plane-protocols/" \
+ "control-plane-protocol[vrf='%s']"
+
+/*
+ * callbacks for routing to handle configuration events
+ * based on the control plane protocol
+ */
+DECLARE_HOOK(routing_conf_event, (struct nb_cb_create_args *args), (args));
+
+void routing_control_plane_protocols_register_vrf_dependency(void);
+
+#ifdef __cplusplus
+}
+#endif
+
+#endif /* _FRR_ROUTING_NB_H_ */