]> git.puffer.fish Git - mirror/frr.git/commitdiff
ospf6d: apply CI style suggestions 16533/head
authorAndrew Cooks <acooks.at.bda@gmail.com>
Wed, 11 Sep 2024 10:27:08 +0000 (20:27 +1000)
committerAndrew Cooks <acooks.at.bda@gmail.com>
Mon, 16 Sep 2024 08:38:17 +0000 (18:38 +1000)
Apply formatting changes suggested by CI frrbot.

Signed-off-by: Andrew Cooks <acooks.at.bda@gmail.com>
ospf6d/ospf6_gr.c
ospf6d/ospf6_gr.h
ospf6d/ospf6_gr_helper.c
ospf6d/ospf6_intra.c
ospf6d/ospf6_lsa.h

index 74a7cccd1269105918f5a7ea6d9bec97228946c9..64eb90d5f29a82782fc691c68e24fd6e0dcad362 100644 (file)
@@ -65,7 +65,8 @@ static int ospf6_gr_lsa_originate(struct ospf6_interface *oi,
 
        /* Put restart reason. */
        grace_lsa->tlv_reason.header.type = htons(TLV_GRACE_RESTART_REASON_TYPE);
-       grace_lsa->tlv_reason.header.length = htons(TLV_GRACE_RESTART_REASON_LENGTH);
+       grace_lsa->tlv_reason.header.length =
+               htons(TLV_GRACE_RESTART_REASON_LENGTH);
        grace_lsa->tlv_reason.reason = reason;
 
        /* Fill LSA Header */
index eddd63e431100e92e2c0cff0caf41f402b976c57..e10d20680bd8f20e4de074aefdb7fc320ce46c71 100644 (file)
@@ -62,7 +62,7 @@ enum ospf6_gr_helper_rejected_reason {
 };
 
 
-#define GRACE_PERIOD_TLV_SIZE sizeof(struct tlv_grace_period)
+#define GRACE_PERIOD_TLV_SIZE        sizeof(struct tlv_grace_period)
 #define GRACE_RESTART_REASON_TLV_SIZE sizeof(struct tlv_grace_restart_reason)
 
 #define OSPF6_GRACE_LSA_MIN_SIZE                                               \
index 639d56e2732cef6c792a38e25ace46c47607dbcc..da8b829cf1ddf3ce9590a841144d07d13c81645e 100644 (file)
@@ -147,7 +147,6 @@ static int ospf6_extract_grace_lsa_fields(struct ospf6_lsa *lsa,
 
        for (tlvh = lsdesc_start(lsah); sum < length && tlvh;
             tlvh = TLV_HDR_NEXT(tlvh)) {
-
                /* Check TLV len against overall LSA */
                if (sum + TLV_SIZE(tlvh) > length) {
                        if (IS_DEBUG_OSPF6_GR)
@@ -1243,7 +1242,6 @@ static int ospf6_grace_lsa_show_info(struct vty *vty, struct ospf6_lsa *lsa,
 
        for (tlvh = lsdesc_start(lsah); sum < length && tlvh;
             tlvh = TLV_HDR_NEXT(tlvh)) {
-
                /* Check TLV len */
                if (sum + TLV_SIZE(tlvh) > length) {
                        if (vty)
index e3c76b971c5c6e45d407a564510f02cb5a0c2a9c..324cd7abe88e39ff62f8e54492acac60ceab5809 100644 (file)
@@ -592,8 +592,6 @@ static char *ospf6_link_lsa_get_prefix_str(struct ospf6_lsa *lsa, char *buf,
        inet_ntop(AF_INET6, &in6, buf, buflen);
 
        return buf;
-
-
 }
 
 static int ospf6_link_lsa_show(struct vty *vty, struct ospf6_lsa *lsa,
index e2c8edd2481e5de977a26d465ce3bd0aa7b062ec..b2c83a1d372d1ffcb51036f64c53d8b3cda85254 100644 (file)
@@ -88,7 +88,6 @@ struct ospf6_lsa_header {
 };
 
 
-
 static inline char *ospf6_lsa_header_end(struct ospf6_lsa_header *header)
 {
        return (char *)header + sizeof(struct ospf6_lsa_header);
@@ -124,7 +123,7 @@ static inline uint16_t ospf6_lsa_size(struct ospf6_lsa_header *header)
 #define OSPF6_LSA_IS_SEQWRAP(L) ((L)->header->seqnum == htonl(OSPF_MAX_SEQUENCE_NUMBER + 1))
 
 /* Router-LSA */
-#define OSPF6_ROUTER_LSA_MIN_SIZE              4U
+#define OSPF6_ROUTER_LSA_MIN_SIZE 4U
 struct ospf6_router_lsa {
        uint8_t bits;
        uint8_t options[3];
@@ -132,7 +131,7 @@ struct ospf6_router_lsa {
 };
 
 /* Link State Description in Router-LSA */
-#define OSPF6_ROUTER_LSDESC_FIX_SIZE          16U
+#define OSPF6_ROUTER_LSDESC_FIX_SIZE 16U
 struct ospf6_router_lsdesc {
        uint8_t type;
        uint8_t reserved;
@@ -142,13 +141,13 @@ struct ospf6_router_lsdesc {
        in_addr_t neighbor_router_id;
 };
 
-#define OSPF6_ROUTER_LSDESC_POINTTOPOINT       1
-#define OSPF6_ROUTER_LSDESC_TRANSIT_NETWORK    2
-#define OSPF6_ROUTER_LSDESC_STUB_NETWORK       3
-#define OSPF6_ROUTER_LSDESC_VIRTUAL_LINK       4
+#define OSPF6_ROUTER_LSDESC_POINTTOPOINT    1
+#define OSPF6_ROUTER_LSDESC_TRANSIT_NETWORK 2
+#define OSPF6_ROUTER_LSDESC_STUB_NETWORK    3
+#define OSPF6_ROUTER_LSDESC_VIRTUAL_LINK    4
 
 /* Network-LSA */
-#define OSPF6_NETWORK_LSA_MIN_SIZE             4U
+#define OSPF6_NETWORK_LSA_MIN_SIZE 4U
 struct ospf6_network_lsa {
        uint8_t reserved;
        uint8_t options[3];
@@ -156,7 +155,7 @@ struct ospf6_network_lsa {
 };
 
 /* Link State Description in Network-LSA */
-#define OSPF6_NETWORK_LSDESC_FIX_SIZE          4U
+#define OSPF6_NETWORK_LSDESC_FIX_SIZE 4U
 struct ospf6_network_lsdesc {
        in_addr_t router_id;
 };
@@ -164,14 +163,14 @@ struct ospf6_network_lsdesc {
        (((struct ospf6_network_lsdesc *)(x))->router_id)
 
 /* Inter-Area-Prefix-LSA */
-#define OSPF6_INTER_PREFIX_LSA_MIN_SIZE        4U /* w/o IPv6 prefix */
+#define OSPF6_INTER_PREFIX_LSA_MIN_SIZE 4U /* w/o IPv6 prefix */
 struct ospf6_inter_prefix_lsa {
        uint32_t metric;
        struct ospf6_prefix prefix;
 };
 
 /* Inter-Area-Router-LSA */
-#define OSPF6_INTER_ROUTER_LSA_FIX_SIZE       12U
+#define OSPF6_INTER_ROUTER_LSA_FIX_SIZE 12U
 struct ospf6_inter_router_lsa {
        uint8_t mbz;
        uint8_t options[3];
@@ -180,7 +179,7 @@ struct ospf6_inter_router_lsa {
 };
 
 /* AS-External-LSA */
-#define OSPF6_AS_EXTERNAL_LSA_MIN_SIZE         4U /* w/o IPv6 prefix */
+#define OSPF6_AS_EXTERNAL_LSA_MIN_SIZE 4U /* w/o IPv6 prefix */
 struct ospf6_as_external_lsa {
        uint32_t bits_metric;
 
@@ -193,7 +192,7 @@ struct ospf6_as_external_lsa {
 /* FIXME: move nssa lsa here. */
 
 /* Link-LSA */
-#define OSPF6_LINK_LSA_MIN_SIZE               24U /* w/o 1st IPv6 prefix */
+#define OSPF6_LINK_LSA_MIN_SIZE 24U /* w/o 1st IPv6 prefix */
 struct ospf6_link_lsa {
        uint8_t priority;
        uint8_t options[3];
@@ -203,7 +202,7 @@ struct ospf6_link_lsa {
 };
 
 /* Intra-Area-Prefix-LSA */
-#define OSPF6_INTRA_PREFIX_LSA_MIN_SIZE       12U /* w/o 1st IPv6 prefix */
+#define OSPF6_INTRA_PREFIX_LSA_MIN_SIZE 12U /* w/o 1st IPv6 prefix */
 struct ospf6_intra_prefix_lsa {
        uint16_t prefix_num;
        uint16_t ref_type;