]> git.proxmox.com Git - mirror_frr.git/blobdiff - ospf6d/ospf6_interface.h
ospf6d: rework BFD integration
[mirror_frr.git] / ospf6d / ospf6_interface.h
index 05ba698a1b0858d9edabc342513d13c9b4003fc2..49a9c2bba6a8766a50af3162aef2b5efc1035fa1 100644 (file)
@@ -90,10 +90,10 @@ struct ospf6_interface {
        uint8_t mtu_ignore;
 
        /* Decision of DR Election */
-       uint32_t drouter;
-       uint32_t bdrouter;
-       uint32_t prev_drouter;
-       uint32_t prev_bdrouter;
+       in_addr_t drouter;
+       in_addr_t bdrouter;
+       in_addr_t prev_drouter;
+       in_addr_t prev_bdrouter;
 
        /* Linklocal LSA Database: includes Link-LSA */
        struct ospf6_lsdb *lsdb;
@@ -111,6 +111,7 @@ struct ospf6_interface {
        struct thread *thread_link_lsa;
        struct thread *thread_intra_prefix_lsa;
        struct thread *thread_as_extern_lsa;
+       struct thread *thread_wait_timer;
 
        struct ospf6_route_table *route_connected;
 
@@ -118,7 +119,12 @@ struct ospf6_interface {
        char *plist_name;
 
        /* BFD information */
-       void *bfd_info;
+       struct {
+               bool enabled;
+               uint8_t detection_multiplier;
+               uint32_t min_rx;
+               uint32_t min_tx;
+       } bfd_config;
 
        /* Statistics Fields */
        uint32_t hello_in;
@@ -133,9 +139,9 @@ struct ospf6_interface {
        uint32_t ls_ack_out;
        uint32_t discarded;
 
-       QOBJ_FIELDS
+       QOBJ_FIELDS;
 };
-DECLARE_QOBJ_TYPE(ospf6_interface)
+DECLARE_QOBJ_TYPE(ospf6_interface);
 
 /* interface state */
 #define OSPF6_INTERFACE_NONE             0
@@ -170,7 +176,8 @@ extern const char *const ospf6_interface_state_str[];
 
 /* Function Prototypes */
 
-extern struct ospf6_interface *ospf6_interface_lookup_by_ifindex(ifindex_t);
+extern struct ospf6_interface *
+ospf6_interface_lookup_by_ifindex(ifindex_t, vrf_id_t vrf_id);
 extern struct ospf6_interface *ospf6_interface_create(struct interface *);
 extern void ospf6_interface_delete(struct ospf6_interface *);
 
@@ -197,6 +204,6 @@ extern void install_element_ospf6_debug_interface(void);
 
 DECLARE_HOOK(ospf6_interface_change,
             (struct ospf6_interface * oi, int state, int old_state),
-            (oi, state, old_state))
+            (oi, state, old_state));
 
 #endif /* OSPF6_INTERFACE_H */