summaryrefslogtreecommitdiffstats
path: root/src/plugins/dpdk/ipsec/crypto_node.c
diff options
context:
space:
mode:
authorKingwel Xie <kingwel.xie@ericsson.com>2018-11-28 02:10:35 -0500
committerDamjan Marion <dmarion@me.com>2018-11-29 08:20:40 +0000
commit040950a59d53e8802ad31430d67df105939cce4c (patch)
tree528713a552c39bbf2d31e1d139f11e47c904ad32 /src/plugins/dpdk/ipsec/crypto_node.c
parent14033aaebd8f82460bc2051c10cde190cd243994 (diff)
dpdk-ipsec-nodes multiarch: nodes are formatted in VLIB_NODE_FN style
crypto-input,esp encrypt/decrypt are indicated in CMakefiles Change-Id: I18ba851c1d4e5633d07c5de61cdaeae938e94982 Signed-off-by: Kingwel Xie <kingwel.xie@ericsson.com>
Diffstat (limited to 'src/plugins/dpdk/ipsec/crypto_node.c')
-rw-r--r--src/plugins/dpdk/ipsec/crypto_node.c17
1 files changed, 11 insertions, 6 deletions
diff --git a/src/plugins/dpdk/ipsec/crypto_node.c b/src/plugins/dpdk/ipsec/crypto_node.c
index 6c92e8fc5ba..5fbaaf3316a 100644
--- a/src/plugins/dpdk/ipsec/crypto_node.c
+++ b/src/plugins/dpdk/ipsec/crypto_node.c
@@ -44,7 +44,7 @@ static char *dpdk_crypto_input_error_strings[] = {
#undef _
};
-vlib_node_registration_t dpdk_crypto_input_node;
+extern vlib_node_registration_t dpdk_crypto_input_node;
typedef struct
{
@@ -174,9 +174,9 @@ dpdk_crypto_dequeue (vlib_main_t * vm, vlib_node_runtime_t * node,
return total_n_deq;
}
-static uword
-dpdk_crypto_input_fn (vlib_main_t * vm, vlib_node_runtime_t * node,
- vlib_frame_t * frame)
+static_always_inline uword
+dpdk_crypto_input_inline (vlib_main_t * vm, vlib_node_runtime_t * node,
+ vlib_frame_t * frame)
{
u32 thread_index = vlib_get_thread_index ();
dpdk_crypto_main_t *dcm = &dpdk_crypto_main;
@@ -228,10 +228,16 @@ dpdk_crypto_input_fn (vlib_main_t * vm, vlib_node_runtime_t * node,
return n_deq;
}
+VLIB_NODE_FN (dpdk_crypto_input_node) (vlib_main_t * vm,
+ vlib_node_runtime_t * node,
+ vlib_frame_t * from_frame)
+{
+ return dpdk_crypto_input_inline (vm, node, from_frame);
+}
+
/* *INDENT-OFF* */
VLIB_REGISTER_NODE (dpdk_crypto_input_node) =
{
- .function = dpdk_crypto_input_fn,
.name = "dpdk-crypto-input",
.format_trace = format_dpdk_crypto_input_trace,
.type = VLIB_NODE_TYPE_INPUT,
@@ -248,7 +254,6 @@ VLIB_REGISTER_NODE (dpdk_crypto_input_node) =
};
/* *INDENT-ON* */
-VLIB_NODE_FUNCTION_MULTIARCH (dpdk_crypto_input_node, dpdk_crypto_input_fn)
/*
* fd.io coding-style-patch-verification: ON
*