From 2c8d4cb2c7ed986f084e393259a0fec89072ef3d Mon Sep 17 00:00:00 2001 From: Szymon Sliwa Date: Wed, 7 Feb 2018 13:06:25 +0100 Subject: plugins: odp: Cosmetic changes in the IPsec implementation 1) renamed ipsec_api to enable_odp_ipsec, for consistency 2) added crude ASSERTs to make sure the configuration is sane 3) removed passing ipsec_api as argument, as this is a global flag now 4) reorder code - put ipsec initialization before putting workers in polling mode 5) remove not used recycle vector from esp_encrypt.c/esp_decrypt.c 6) change clib_error_return to clib_error in ipsec.c, as clib_error_return silently passes when 0 is the first argument Change-Id: Id2c6da985e872f12c8409918fb9cc6113b486d10 Signed-off-by: Szymon Sliwa --- src/plugins/odp/odp_packet.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/plugins/odp/odp_packet.c') diff --git a/src/plugins/odp/odp_packet.c b/src/plugins/odp/odp_packet.c index 29b2ef01..45f2f272 100755 --- a/src/plugins/odp/odp_packet.c +++ b/src/plugins/odp/odp_packet.c @@ -24,7 +24,7 @@ odp_if_mode_t def_if_mode; odp_if_config_t *if_config; odp_crypto_main_t odp_crypto_main; u8 enable_odp_crypto; -u8 ipsec_api; +u8 enable_odp_ipsec; u8 is_async; u8 is_inline; @@ -435,7 +435,7 @@ odp_config (vlib_main_t * vm, unformat_input_t * input) } else if (unformat (input, "enable-odp-ipsec")) { - ipsec_api = 1; + enable_odp_ipsec = 1; } else if (unformat (input, "async")) { @@ -487,7 +487,7 @@ odp_process (vlib_main_t * vm, vlib_node_runtime_t * rt, vlib_frame_t * f) /* Initialization complete and worker threads can start */ tm->worker_thread_release = 1; - ipsec_init (vlib_get_main (), ipsec_api); + ipsec_init (vlib_get_main ()); return 0; } -- cgit 1.2.3-korg