]> git.puffer.fish Git - mirror/frr.git/commitdiff
Correct indentation and remove _opcode_t typedef
authorOlivier Dugeon <olivier.dugeon@orange.com>
Fri, 21 Jul 2017 14:34:33 +0000 (16:34 +0200)
committerOlivier Dugeon <olivier.dugeon@orange.com>
Fri, 21 Jul 2017 14:34:33 +0000 (16:34 +0200)
 * Correct struct tlh_header indentation in opaque.h
 * Change typedef enum _opcode_t by enum lsa_opcode
 * Propagate change in ospf_te.[c,h) and ospf_ri.c

Signed-off-by: Olivier Dugeon <olivier.dugeon@orange.com>
ospfd/ospf_opaque.h
ospfd/ospf_ri.c
ospfd/ospf_te.c
ospfd/ospf_te.h

index 88a6854b846cc36e814be6cfb98c1de78b942f9e..60435e502eec4b7a4d3bffc62ba5ed2ee21bd51b 100644 (file)
@@ -81,8 +81,7 @@
  * 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 */
 };
@@ -112,11 +111,11 @@ struct tlv_header
 #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. */
 
index 2136f2eb64dd6cca92df530e75febe68d4ad7e3b..e192a39e459ddc6ea112995d73a814dbec957ab7 100644 (file)
@@ -111,7 +111,7 @@ static void ospf_router_info_config_write_router(struct vty *vty);
 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);
 
@@ -778,7 +778,7 @@ static struct ospf_lsa *ospf_router_info_lsa_refresh(struct ospf_lsa *lsa)
        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;
index 66de46c5c9c41ae8b4e7d135cc96b09681ad1a18..a982350e63ab665d5a54e30fa5760af07383c6c7 100644 (file)
@@ -229,8 +229,8 @@ static struct mpls_te_link *lookup_linkparams_by_instance(struct ospf_lsa *lsa)
 }
 
 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;
@@ -1509,7 +1509,7 @@ static struct ospf_lsa *ospf_mpls_te_lsa_refresh(struct ospf_lsa *lsa)
        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;
index 233350f830d6cf0ebb60f8f7ec6dd0aeff43c428..e3a6114b4fdcae9039bfae4dc4f0175fadd31dd4 100644 (file)
@@ -408,7 +408,7 @@ extern int ospf_mpls_te_init(void);
 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);