aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/acl
diff options
context:
space:
mode:
authorDamjan Marion <damarion@cisco.com>2018-08-10 22:39:11 +0200
committerDamjan Marion <dmarion@me.com>2018-08-13 14:33:54 +0000
commit6e36351faf5b69a0bfb8235b3b06f8b2c24e5547 (patch)
tree512c92bda1a48604fbfbc7bbbb1e4b613cdba614 /src/plugins/acl
parent3bf6c2bfe59be62169a1245340722481b0b53870 (diff)
Multiarch handling in different constructor macros
This significantly reduces need for ... in multiarch code. Simply constructor macros will jost create static unused entry if CLIB_MARCH_VARIANT is defined and that will be optimized out by compiler. Change-Id: I17d1c4ac0c903adcfadaa4a07de1b854c7ab14ac Signed-off-by: Damjan Marion <damarion@cisco.com>
Diffstat (limited to 'src/plugins/acl')
-rw-r--r--src/plugins/acl/dataplane_node.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/plugins/acl/dataplane_node.c b/src/plugins/acl/dataplane_node.c
index 00cad47fb23..79ee5010c26 100644
--- a/src/plugins/acl/dataplane_node.c
+++ b/src/plugins/acl/dataplane_node.c
@@ -415,7 +415,6 @@ VLIB_NODE_FN (acl_out_fa_ip4_node) (vlib_main_t * vm,
return acl_fa_node_fn (vm, node, frame, 0, 0, 0, 0, &acl_out_fa_ip4_node);
}
-#ifndef CLIB_MARCH_VARIANT
static u8 *
format_fa_5tuple (u8 * s, va_list * args)
{
@@ -447,14 +446,16 @@ format_fa_5tuple (u8 * s, va_list * args)
p5t->pkt.tcp_flags, p5t->pkt.flags_reserved);
}
+#ifndef CLIB_MARCH_VARIANT
u8 *
format_acl_plugin_5tuple (u8 * s, va_list * args)
{
return format_fa_5tuple (s, args);
}
+#endif
/* packet trace format function */
-u8 *
+static u8 *
format_acl_plugin_trace (u8 * s, va_list * args)
{
CLIB_UNUSED (vlib_main_t * vm) = va_arg (*args, vlib_main_t *);
@@ -475,7 +476,6 @@ format_acl_plugin_trace (u8 * s, va_list * args)
return s;
}
-
/* *INDENT-OFF* */
static char *acl_fa_error_strings[] = {
@@ -634,7 +634,6 @@ VNET_FEATURE_INIT (acl_out_ip4_fa_feature, static) =
.node_name = "acl-plugin-out-ip4-fa",
.runs_before = VNET_FEATURES ("interface-output"),
};
-#endif
/* *INDENT-ON* */