aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/crypto_ipsecmb
diff options
context:
space:
mode:
authorFilip Tehlar <ftehlar@cisco.com>2020-03-05 16:41:27 +0000
committerDave Barach <openvpp@barachs.net>2020-03-06 13:35:09 +0000
commitfb8ed8b95529db095b7305938db17a545ca9eeef (patch)
tree190ba1018c062769d71415b5e5624b0d4f8a629f /src/plugins/crypto_ipsecmb
parent1322375357fb7596fc976b5613181a3587163099 (diff)
crypto: align per thread data to cache line
Type: improvement Change-Id: I6bad46403c07b211dfda7229aed1b5e19342865f Signed-off-by: Filip Tehlar <ftehlar@cisco.com>
Diffstat (limited to 'src/plugins/crypto_ipsecmb')
-rw-r--r--src/plugins/crypto_ipsecmb/ipsecmb.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/plugins/crypto_ipsecmb/ipsecmb.c b/src/plugins/crypto_ipsecmb/ipsecmb.c
index 11e52322775..14d618c8b7e 100644
--- a/src/plugins/crypto_ipsecmb/ipsecmb.c
+++ b/src/plugins/crypto_ipsecmb/ipsecmb.c
@@ -30,6 +30,7 @@
typedef struct
{
+ CLIB_CACHE_LINE_ALIGN_MARK (cacheline0);
MB_MGR *mgr;
__m128i cbc_iv;
} ipsecmb_per_thread_data_t;
@@ -522,7 +523,8 @@ crypto_ipsecmb_init (vlib_main_t * vm)
IMB_VERSION_STR, 0);
eidx = vnet_crypto_register_engine (vm, "ipsecmb", 80, (char *) name);
- vec_validate (imbm->per_thread_data, tm->n_vlib_mains - 1);
+ vec_validate_aligned (imbm->per_thread_data, tm->n_vlib_mains - 1,
+ CLIB_CACHE_LINE_BYTES);
/* *INDENT-OFF* */
vec_foreach (ptd, imbm->per_thread_data)