summaryrefslogtreecommitdiffstats
path: root/lib/zclient.h
diff options
context:
space:
mode:
authorCarmine Scarpitta <cscarpit@cisco.com>2024-03-23 18:31:12 +0100
committerCarmine Scarpitta <cscarpit@cisco.com>2024-06-13 14:54:16 +0200
commitee1d20879b0cb44abb77954190a55a07e1921435 (patch)
tree1a699fd38b79b1953913f8d072c026723aaddebe /lib/zclient.h
parentlib: Add ZAPI operation get SRv6 locator (diff)
downloadfrr-ee1d20879b0cb44abb77954190a55a07e1921435.tar.xz
frr-ee1d20879b0cb44abb77954190a55a07e1921435.zip
lib: Add ZAPI operations to get/release SRv6 SIDs
Add two new ZAPI operations: `ZEBRA_SRV6_MANAGER_GET_SRV6_SID` and `ZEBRA_SRV6_MANAGER_RELEASE_SRV6_SID`. These APIs allow a daemon to get and release an SRv6 SID, respectively. Signed-off-by: Carmine Scarpitta <cscarpit@cisco.com>
Diffstat (limited to '')
-rw-r--r--lib/zclient.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/lib/zclient.h b/lib/zclient.h
index 87617003d..bb527f0b4 100644
--- a/lib/zclient.h
+++ b/lib/zclient.h
@@ -210,6 +210,8 @@ typedef enum {
ZEBRA_SRV6_MANAGER_GET_LOCATOR_CHUNK,
ZEBRA_SRV6_MANAGER_RELEASE_LOCATOR_CHUNK,
ZEBRA_SRV6_MANAGER_GET_LOCATOR,
+ ZEBRA_SRV6_MANAGER_GET_SRV6_SID,
+ ZEBRA_SRV6_MANAGER_RELEASE_SRV6_SID,
ZEBRA_ERROR,
ZEBRA_CLIENT_CAPABILITIES,
ZEBRA_OPAQUE_MESSAGE,
@@ -1071,12 +1073,23 @@ extern int tm_get_table_chunk(struct zclient *zclient, uint32_t chunk_size,
uint32_t *start, uint32_t *end);
extern int tm_release_table_chunk(struct zclient *zclient, uint32_t start,
uint32_t end);
+
+/* Zebra SRv6 Manager flags */
+#define ZAPI_SRV6_MANAGER_SID_FLAG_HAS_SID_VALUE 0x01
+#define ZAPI_SRV6_MANAGER_SID_FLAG_HAS_LOCATOR 0x02
+
extern int srv6_manager_get_locator_chunk(struct zclient *zclient,
const char *locator_name);
extern int srv6_manager_release_locator_chunk(struct zclient *zclient,
const char *locator_name);
extern int srv6_manager_get_locator(struct zclient *zclient,
const char *locator_name);
+extern int srv6_manager_get_sid(struct zclient *zclient,
+ const struct srv6_sid_ctx *ctx,
+ struct in6_addr *sid_value,
+ const char *locator_name, uint32_t *sid_func);
+extern int srv6_manager_release_sid(struct zclient *zclient,
+ const struct srv6_sid_ctx *ctx);
extern enum zclient_send_status zebra_send_sr_policy(struct zclient *zclient,
int cmd,