summaryrefslogtreecommitdiffstats
path: root/src/plugins/gbp
diff options
context:
space:
mode:
authorDamjan Marion <damarion@cisco.com>2020-12-13 21:47:40 +0100
committerDave Barach <openvpp@barachs.net>2020-12-14 12:14:21 +0000
commitb2c31b685fd2cf28436ca32bc93e23eb24c74878 (patch)
treedc0a1b1ff784445b2cbb0f9b2c07b5bcb4f5a5d0 /src/plugins/gbp
parent62c25abaa3e93be5815172d391295a6ab0390122 (diff)
misc: move to new pool_foreach macros
Type: refactor Change-Id: Ie67dc579e88132ddb1ee4a34cb69f96920101772 Signed-off-by: Damjan Marion <damarion@cisco.com>
Diffstat (limited to 'src/plugins/gbp')
-rw-r--r--src/plugins/gbp/gbp_bridge_domain.c4
-rw-r--r--src/plugins/gbp/gbp_contract.c12
-rw-r--r--src/plugins/gbp/gbp_endpoint.c4
-rw-r--r--src/plugins/gbp/gbp_endpoint_group.c4
-rw-r--r--src/plugins/gbp/gbp_ext_itf.c4
-rw-r--r--src/plugins/gbp/gbp_itf.c6
-rw-r--r--src/plugins/gbp/gbp_recirc.c4
-rw-r--r--src/plugins/gbp/gbp_route_domain.c4
-rw-r--r--src/plugins/gbp/gbp_subnet.c12
-rw-r--r--src/plugins/gbp/gbp_vxlan.c6
10 files changed, 30 insertions, 30 deletions
diff --git a/src/plugins/gbp/gbp_bridge_domain.c b/src/plugins/gbp/gbp_bridge_domain.c
index f2a56d770b9..279169abb1d 100644
--- a/src/plugins/gbp/gbp_bridge_domain.c
+++ b/src/plugins/gbp/gbp_bridge_domain.c
@@ -364,11 +364,11 @@ gbp_bridge_domain_walk (gbp_bridge_domain_cb_t cb, void *ctx)
gbp_bridge_domain_t *gbpe;
/* *INDENT-OFF* */
- pool_foreach(gbpe, gbp_bridge_domain_pool,
+ pool_foreach (gbpe, gbp_bridge_domain_pool)
{
if (!cb(gbpe, ctx))
break;
- });
+ }
/* *INDENT-ON* */
}
diff --git a/src/plugins/gbp/gbp_contract.c b/src/plugins/gbp/gbp_contract.c
index e12b33145ce..dd433f28a84 100644
--- a/src/plugins/gbp/gbp_contract.c
+++ b/src/plugins/gbp/gbp_contract.c
@@ -567,11 +567,11 @@ gbp_contract_walk (gbp_contract_cb_t cb, void *ctx)
gbp_contract_t *gc;
/* *INDENT-OFF* */
- pool_foreach(gc, gbp_contract_pool,
- ({
+ pool_foreach (gc, gbp_contract_pool)
+ {
if (!cb(gc, ctx))
break;
- }));
+ }
/* *INDENT-ON* */
}
@@ -710,8 +710,8 @@ gbp_contract_show (vlib_main_t * vm,
vlib_cli_output (vm, "Contracts:");
/* *INDENT-OFF* */
- pool_foreach (gc, gbp_contract_pool,
- ({
+ pool_foreach (gc, gbp_contract_pool)
+ {
gci = gc - gbp_contract_pool;
if (SCLASS_INVALID != src && SCLASS_INVALID != dst)
@@ -732,7 +732,7 @@ gbp_contract_show (vlib_main_t * vm,
}
else
vlib_cli_output (vm, " %U", format_gbp_contract, gci);
- }));
+ }
/* *INDENT-ON* */
return (NULL);
diff --git a/src/plugins/gbp/gbp_endpoint.c b/src/plugins/gbp/gbp_endpoint.c
index 9cc69d01277..b0cf64ced2d 100644
--- a/src/plugins/gbp/gbp_endpoint.c
+++ b/src/plugins/gbp/gbp_endpoint.c
@@ -1063,11 +1063,11 @@ gbp_endpoint_walk (gbp_endpoint_cb_t cb, void *ctx)
u32 index;
/* *INDENT-OFF* */
- pool_foreach_index(index, gbp_endpoint_pool,
+ pool_foreach_index (index, gbp_endpoint_pool)
{
if (!cb(index, ctx))
break;
- });
+ }
/* *INDENT-ON* */
}
diff --git a/src/plugins/gbp/gbp_endpoint_group.c b/src/plugins/gbp/gbp_endpoint_group.c
index 92bad373c32..b9044378e3b 100644
--- a/src/plugins/gbp/gbp_endpoint_group.c
+++ b/src/plugins/gbp/gbp_endpoint_group.c
@@ -241,11 +241,11 @@ gbp_endpoint_group_walk (gbp_endpoint_group_cb_t cb, void *ctx)
gbp_endpoint_group_t *gbpe;
/* *INDENT-OFF* */
- pool_foreach(gbpe, gbp_endpoint_group_pool,
+ pool_foreach (gbpe, gbp_endpoint_group_pool)
{
if (!cb(gbpe, ctx))
break;
- });
+ }
/* *INDENT-ON* */
}
diff --git a/src/plugins/gbp/gbp_ext_itf.c b/src/plugins/gbp/gbp_ext_itf.c
index e18bbe9c39a..c5506661c2d 100644
--- a/src/plugins/gbp/gbp_ext_itf.c
+++ b/src/plugins/gbp/gbp_ext_itf.c
@@ -233,11 +233,11 @@ gbp_ext_itf_walk (gbp_ext_itf_cb_t cb, void *ctx)
gbp_ext_itf_t *ge;
/* *INDENT-OFF* */
- pool_foreach(ge, gbp_ext_itf_pool,
+ pool_foreach (ge, gbp_ext_itf_pool)
{
if (!cb(ge, ctx))
break;
- });
+ }
/* *INDENT-ON* */
}
diff --git a/src/plugins/gbp/gbp_itf.c b/src/plugins/gbp/gbp_itf.c
index 6a4a19733df..0c8f6a45a87 100644
--- a/src/plugins/gbp/gbp_itf.c
+++ b/src/plugins/gbp/gbp_itf.c
@@ -541,10 +541,10 @@ gbp_itf_show (vlib_main_t * vm,
vlib_cli_output (vm, "Interfaces:");
/* *INDENT-OFF* */
- pool_foreach_index (gii, gbp_itf_pool,
- ({
+ pool_foreach_index (gii, gbp_itf_pool)
+ {
vlib_cli_output (vm, " [%d] %U", gii, format_gbp_itf, gii);
- }));
+ }
/* *INDENT-ON* */
return (NULL);
diff --git a/src/plugins/gbp/gbp_recirc.c b/src/plugins/gbp/gbp_recirc.c
index 2b45d484289..8d56f11b4e3 100644
--- a/src/plugins/gbp/gbp_recirc.c
+++ b/src/plugins/gbp/gbp_recirc.c
@@ -227,11 +227,11 @@ gbp_recirc_walk (gbp_recirc_cb_t cb, void *ctx)
gbp_recirc_t *ge;
/* *INDENT-OFF* */
- pool_foreach(ge, gbp_recirc_pool,
+ pool_foreach (ge, gbp_recirc_pool)
{
if (!cb(ge, ctx))
break;
- });
+ }
/* *INDENT-ON* */
}
diff --git a/src/plugins/gbp/gbp_route_domain.c b/src/plugins/gbp/gbp_route_domain.c
index 99c6e168a53..6cc595d0fa9 100644
--- a/src/plugins/gbp/gbp_route_domain.c
+++ b/src/plugins/gbp/gbp_route_domain.c
@@ -290,11 +290,11 @@ gbp_route_domain_walk (gbp_route_domain_cb_t cb, void *ctx)
gbp_route_domain_t *gbpe;
/* *INDENT-OFF* */
- pool_foreach(gbpe, gbp_route_domain_pool,
+ pool_foreach (gbpe, gbp_route_domain_pool)
{
if (!cb(gbpe, ctx))
break;
- });
+ }
/* *INDENT-ON* */
}
diff --git a/src/plugins/gbp/gbp_subnet.c b/src/plugins/gbp/gbp_subnet.c
index 2ef3fcfd534..8d3b571657c 100644
--- a/src/plugins/gbp/gbp_subnet.c
+++ b/src/plugins/gbp/gbp_subnet.c
@@ -424,8 +424,8 @@ gbp_subnet_walk (gbp_subnet_cb_t cb, void *ctx)
sw_if_index = ~0;
/* *INDENT-OFF* */
- pool_foreach (gs, gbp_subnet_pool,
- ({
+ pool_foreach (gs, gbp_subnet_pool)
+ {
grd = gbp_route_domain_get(gs->gs_rd);
switch (gs->gs_type)
@@ -447,7 +447,7 @@ gbp_subnet_walk (gbp_subnet_cb_t cb, void *ctx)
if (WALK_STOP == cb (grd->grd_id, &gs->gs_key->gsk_pfx,
gs->gs_type, sw_if_index, sclass, ctx))
break;
- }));
+ }
/* *INDENT-ON* */
}
@@ -549,11 +549,11 @@ gbp_subnet_show (vlib_main_t * vm,
else
{
/* *INDENT-OFF* */
- pool_foreach_index(gsi, gbp_subnet_pool,
- ({
+ pool_foreach_index (gsi, gbp_subnet_pool)
+ {
vlib_cli_output (vm, "%U", format_gbp_subnet, gsi,
GBP_SUBNET_SHOW_BRIEF);
- }));
+ }
/* *INDENT-ON* */
}
diff --git a/src/plugins/gbp/gbp_vxlan.c b/src/plugins/gbp/gbp_vxlan.c
index 643089eeb1b..d3da2b53949 100644
--- a/src/plugins/gbp/gbp_vxlan.c
+++ b/src/plugins/gbp/gbp_vxlan.c
@@ -306,11 +306,11 @@ gbp_vxlan_walk (gbp_vxlan_cb_t cb, void *ctx)
gbp_vxlan_tunnel_t *gt;
/* *INDENT-OFF* */
- pool_foreach (gt, gbp_vxlan_tunnel_pool,
- ({
+ pool_foreach (gt, gbp_vxlan_tunnel_pool)
+ {
if (WALK_CONTINUE != cb(gt, ctx))
break;
- }));
+ }
/* *INDENT-ON* */
}