* Following section defines generic TLV (type, length, value) macros,
* used for various LSA opaque usage e.g. Traffic Engineering.
*/
-struct tlv_header
-{
+struct tlv_header {
u_int16_t type; /* Type of Value */
u_int16_t length; /* Length of Value portion only, in bytes */
};
#define TLV_HDR(tlvh) tlvh.header
/* Following declaration concerns the Opaque LSA management */
-typedef enum _opcode_t {
+enum lsa_opcode {
REORIGINATE_THIS_LSA,
REFRESH_THIS_LSA,
FLUSH_THIS_LSA
-} opcode_t;
+};
/* Prototypes. */
static void ospf_router_info_show_info(struct vty *vty, struct ospf_lsa *lsa);
static int ospf_router_info_lsa_originate(void *arg);
static struct ospf_lsa *ospf_router_info_lsa_refresh(struct ospf_lsa *lsa);
-static void ospf_router_info_lsa_schedule(opcode_t opcode);
+static void ospf_router_info_lsa_schedule(enum lsa_opcode opcode);
static void ospf_router_info_register_vty(void);
static void del_pce_info(void *val);
return new;
}
-static void ospf_router_info_lsa_schedule(opcode_t opcode)
+static void ospf_router_info_lsa_schedule(enum lsa_opcode opcode)
{
struct ospf_lsa lsa;
struct lsa_header lsah;
}
static void ospf_mpls_te_foreach_area(void (*func)(struct mpls_te_link *lp,
- opcode_t sched_opcode),
- opcode_t sched_opcode)
+ enum lsa_opcode sched_opcode),
+ enum lsa_opcode sched_opcode)
{
struct listnode *node, *nnode;
struct listnode *node2;
return new;
}
-void ospf_mpls_te_lsa_schedule(struct mpls_te_link *lp, opcode_t opcode)
+void ospf_mpls_te_lsa_schedule(struct mpls_te_link *lp, enum lsa_opcode opcode)
{
struct ospf_lsa lsa;
struct lsa_header lsah;
extern void ospf_mpls_te_term(void);
extern struct ospf_mpls_te *get_ospf_mpls_te(void);
extern void ospf_mpls_te_update_if(struct interface *);
-extern void ospf_mpls_te_lsa_schedule(struct mpls_te_link *, opcode_t);
+extern void ospf_mpls_te_lsa_schedule(struct mpls_te_link *, enum lsa_opcode);
extern void set_linkparams_llri(struct mpls_te_link *, u_int32_t, u_int32_t);
extern void set_linkparams_lrrid(struct mpls_te_link *, struct in_addr,
struct in_addr);