diff options
Diffstat (limited to 'lib/zclient.h')
| -rw-r--r-- | lib/zclient.h | 27 |
1 files changed, 22 insertions, 5 deletions
diff --git a/lib/zclient.h b/lib/zclient.h index ae94237b76..2af448a20c 100644 --- a/lib/zclient.h +++ b/lib/zclient.h @@ -220,6 +220,7 @@ typedef enum { ZEBRA_OPAQUE_UNREGISTER, ZEBRA_NEIGH_DISCOVER, ZEBRA_ROUTE_NOTIFY_REQUEST, + ZEBRA_CLIENT_CLOSE_NOTIFY, } zebra_message_types_t; enum zebra_error_types { @@ -377,6 +378,7 @@ struct zclient { int (*opaque_register_handler)(ZAPI_CALLBACK_ARGS); int (*opaque_unregister_handler)(ZAPI_CALLBACK_ARGS); int (*sr_policy_notify_status)(ZAPI_CALLBACK_ARGS); + int (*zebra_client_close_notify)(ZAPI_CALLBACK_ARGS); }; /* Zebra API message flag. */ @@ -389,14 +391,14 @@ struct zclient { /* Backup nexthops are present */ #define ZAPI_MESSAGE_BACKUP_NEXTHOPS 0x40 #define ZAPI_MESSAGE_NHG 0x80 - /* * This should only be used by a DAEMON that needs to communicate * the table being used is not in the VRF. You must pass the * default vrf, else this will be ignored. */ -#define ZAPI_MESSAGE_TABLEID 0x0080 -#define ZAPI_MESSAGE_SRTE 0x0100 +#define ZAPI_MESSAGE_TABLEID 0x0100 +#define ZAPI_MESSAGE_SRTE 0x0200 +#define ZAPI_MESSAGE_OPAQUE 0x0400 #define ZSERV_VERSION 6 /* Zserv protocol message header */ @@ -570,6 +572,12 @@ struct zapi_route { /* SR-TE color (used for nexthop updates only). */ uint32_t srte_color; + +#define ZAPI_MESSAGE_OPAQUE_LENGTH 1024 + struct { + uint16_t length; + uint8_t data[ZAPI_MESSAGE_OPAQUE_LENGTH]; + } opaque; }; struct zapi_labels { @@ -1083,8 +1091,6 @@ enum zapi_opaque_registry { LDP_IGP_SYNC_IF_STATE_UPDATE = 4, /* Announce that LDP is up */ LDP_IGP_SYNC_ANNOUNCE_UPDATE = 5, - /* Heartbeat indicating that LDP is running */ - LDP_IGP_SYNC_HELLO_UPDATE = 6, }; /* Send the hello message. @@ -1097,6 +1103,17 @@ zclient_send_neigh_discovery_req(struct zclient *zclient, const struct interface *ifp, const struct prefix *p); +struct zapi_client_close_info { + /* Client session tuple */ + uint8_t proto; + uint16_t instance; + uint32_t session_id; +}; + +/* Decode incoming client close notify */ +extern int zapi_client_close_notify_decode(struct stream *s, + struct zapi_client_close_info *info); + #ifdef __cplusplus } #endif |
