]> git.proxmox.com Git - mirror_frr.git/blobdiff - ldpd/ldp.h
zebra, lib: fix the ZEBRA_INTERFACE_VRF_UPDATE zapi message
[mirror_frr.git] / ldpd / ldp.h
index c421cddc386f8fb9bbcedf4bd91a907fa45c4b09..cac3da7c55d0259a5310e6e92cc9b30f294dfd61 100644 (file)
@@ -63,6 +63,7 @@
 #define MSG_TYPE_HELLO         0x0100
 #define MSG_TYPE_INIT          0x0200
 #define MSG_TYPE_KEEPALIVE     0x0201
+#define MSG_TYPE_CAPABILITY    0x0202 /* RFC 5561 */
 #define MSG_TYPE_ADDR          0x0300
 #define MSG_TYPE_ADDRWITHDRAW  0x0301
 #define MSG_TYPE_LABELMAPPING  0x0400
 #define TLV_TYPE_FRSESSION     0x0502
 #define TLV_TYPE_LABELREQUEST  0x0600
 /* RFC 4447 */
-#define TLV_TYPE_PW_STATUS     0x096A
+#define TLV_TYPE_MAC_LIST      0x8404
+#define TLV_TYPE_PW_STATUS     0x896A
 #define TLV_TYPE_PW_IF_PARAM   0x096B
 #define TLV_TYPE_PW_GROUP_ID   0x096C
+/* RFC 5561 */
+#define TLV_TYPE_RETURNED_TLVS 0x8304
+#define TLV_TYPE_DYNAMIC_CAP   0x8506
+/* RFC 5918 */
+#define TLV_TYPE_TWCARD_CAP    0x850B
+/* RFC 5919 */
+#define TLV_TYPE_UNOTIF_CAP    0x8603
 /* RFC 7552 */
 #define TLV_TYPE_DUALSTACK     0x8701
 
@@ -196,6 +205,10 @@ struct hello_prms_opt16_tlv {
 #define S_UNASSIGN_TAI 0x00000029
 #define S_MISCONF_ERR  0x0000002A
 #define S_WITHDRAW_MTHD        0x0000002B
+/* RFC 5561 */
+#define        S_UNSSUPORTDCAP 0x0000002E
+/* RFC 5919 */
+#define        S_ENDOFLIB      0x0000002F
 /* RFC 7552 */
 #define        S_TRANS_MISMTCH 0x80000032
 #define        S_DS_NONCMPLNCE 0x80000033
@@ -227,6 +240,26 @@ struct status_tlv {
 #define STATUS_TLV_LEN         10
 #define        STATUS_FATAL            0x80000000
 
+struct capability_tlv {
+       uint16_t        type;
+       uint16_t        length;
+       uint8_t         reserved;
+};
+#define STATE_BIT              0x80
+
+#define F_CAP_TLV_RCVD_DYNAMIC 0x01
+#define F_CAP_TLV_RCVD_TWCARD  0x02
+#define F_CAP_TLV_RCVD_UNOTIF  0x04
+
+#define CAP_TLV_DYNAMIC_SIZE   5
+#define CAP_TLV_DYNAMIC_LEN    1
+
+#define CAP_TLV_TWCARD_SIZE    5
+#define CAP_TLV_TWCARD_LEN     1
+
+#define CAP_TLV_UNOTIF_SIZE    5
+#define CAP_TLV_UNOTIF_LEN     1
+
 #define        AF_IPV4                 0x1
 #define        AF_IPV6                 0x2
 
@@ -242,17 +275,20 @@ struct address_list_tlv {
 #define FEC_ELM_WCARD_LEN      1
 #define FEC_ELM_PREFIX_MIN_LEN 4
 #define FEC_PWID_ELM_MIN_LEN   8
+#define FEC_PWID_SIZE          4
+#define FEC_ELM_TWCARD_MIN_LEN 3
 
 #define        MAP_TYPE_WILDCARD       0x01
 #define        MAP_TYPE_PREFIX         0x02
+#define        MAP_TYPE_TYPED_WCARD    0x05
 #define        MAP_TYPE_PWID           0x80
 #define        MAP_TYPE_GENPWID        0x81
 
 #define CONTROL_WORD_FLAG      0x8000
-#define PW_TYPE_ETHERNET_TAGGED        0x0004
-#define PW_TYPE_ETHERNET       0x0005
 #define DEFAULT_PW_TYPE                PW_TYPE_ETHERNET
 
+#define PW_TWCARD_RESERVED_BIT 0x8000
+
 /* RFC 4447 Sub-TLV record */
 struct subtlv {
        uint8_t         type;