vppinfra: Improve code portability
[vpp.git] / src / vnet / ip6-nd / ip6_mld.c
index 2a95c84..74428ec 100644 (file)
@@ -33,7 +33,6 @@
  * adjacency tables and neighbor discovery logic.
  */
 
-/* *INDENT-OFF*/
 /* multicast listener report packet format for ethernet. */
 typedef CLIB_PACKED (struct
 {
@@ -51,7 +50,6 @@ typedef CLIB_PACKED (struct
   ip6_header_t ip;
   icmp6_multicast_listener_report_header_t report_hdr;
 }) icmp6_multicast_listener_report_packet_t;
-/* *INDENT-ON*/
 
 typedef struct
 {
@@ -224,12 +222,10 @@ ip6_mld_delegate_disable (index_t imdi)
   imd = pool_elt_at_index (ip6_mld_pool, imdi);
 
   /* clean MLD pools */
-  /* *INDENT-OFF* */
   pool_flush (m, imd->mldp_group_pool,
   ({
     mhash_unset (&imd->address_to_mldp_index, &m->mcast_address, 0);
   }));
-  /* *INDENT-ON* */
 
   pool_free (imd->mldp_group_pool);
 
@@ -326,9 +322,8 @@ ip6_neighbor_send_mldpv2_report (u32 sw_if_index)
 
   rh0->icmp.checksum = 0;
 
-  /* *INDENT-OFF* */
-  pool_foreach (m, imd->mldp_group_pool,
-  ({
+  pool_foreach (m, imd->mldp_group_pool)
+   {
     rr.type = m->type;
     rr.aux_data_len_u32s = 0;
     rr.num_sources = clib_host_to_net_u16 (m->num_sources);
@@ -344,8 +339,7 @@ ip6_neighbor_send_mldpv2_report (u32 sw_if_index)
       }
 
     payload_length += sizeof( icmp6_multicast_address_record_t);
-  }));
-  /* *INDENT-ON* */
+  }
 
   rh0->rsvd = 0;
   rh0->num_addr_records = clib_host_to_net_u16 (num_addr_records);
@@ -388,9 +382,8 @@ ip6_mld_timer_event (vlib_main_t * vm,
   ip6_mld_t *imd;
 
   /* Interface ip6 radv info list */
-  /* *INDENT-OFF* */
-  pool_foreach (imd, ip6_mld_pool,
-  ({
+  pool_foreach (imd, ip6_mld_pool)
+   {
     if (!vnet_sw_interface_is_admin_up (vnm, imd->sw_if_index))
       {
         imd->all_routers_mcast = 0;
@@ -404,8 +397,7 @@ ip6_mld_timer_event (vlib_main_t * vm,
         ip6_neighbor_send_mldpv2_report(imd->sw_if_index);
         imd->all_routers_mcast = 1;
       }
-  }));
-  /* *INDENT-ON* */
+  }
 
   return 0;
 }
@@ -433,13 +425,11 @@ ip6_mld_event_process (vlib_main_t * vm,
   return frame->n_vectors;
 }
 
-/* *INDENT-OFF* */
 VLIB_REGISTER_NODE (ip6_mld_event_process_node) = {
   .function = ip6_mld_event_process,
   .name = "ip6-mld-process",
   .type = VLIB_NODE_TYPE_PROCESS,
 };
-/* *INDENT-ON* */
 
 static u8 *
 format_ip6_mld (u8 * s, va_list * args)
@@ -453,15 +443,13 @@ format_ip6_mld (u8 * s, va_list * args)
 
   s = format (s, "%UJoined group address(es):\n", format_white_space, indent);
 
-  /* *INDENT-OFF* */
-  pool_foreach (m, imd->mldp_group_pool,
-  ({
+  pool_foreach (m, imd->mldp_group_pool)
+   {
     s = format (s, "%U%U\n",
                 format_white_space, indent+2,
                 format_ip6_address,
                 &m->mcast_address);
-  }));
-  /* *INDENT-ON* */
+  }
 
   return (s);
 }
@@ -526,12 +514,10 @@ ip6_mld_init (vlib_main_t * vm)
   return (NULL);
 }
 
-/* *INDENT-OFF* */
 VLIB_INIT_FUNCTION (ip6_mld_init) =
 {
   .runs_after = VLIB_INITS("icmp6_init"),
 };
-/* *INDENT-ON* */
 
 /*
  * fd.io coding-style-patch-verification: ON