summaryrefslogtreecommitdiffstats
path: root/src/vnet/ipsec/ipsec.h
diff options
context:
space:
mode:
authorNeale Ranns <nranns@cisco.com>2020-05-24 16:17:50 +0000
committerNeale Ranns <nranns@cisco.com>2020-10-05 09:06:36 +0000
commit7b4e52f88fdfd7b785a2741d3b61050040d8561d (patch)
treef80271d2f297c99b15fb1a25141cd4be4357e07f /src/vnet/ipsec/ipsec.h
parent149fd3fbd069a5f7be86e68472578ee7af229cb6 (diff)
ipsec: Use bihash for tunnel lookup
Type: improvement Change-Id: I0c82722dfce990345fe6eeecdb335678543367e0 Signed-off-by: Neale Ranns <nranns@cisco.com>
Diffstat (limited to 'src/vnet/ipsec/ipsec.h')
-rw-r--r--src/vnet/ipsec/ipsec.h9
1 files changed, 7 insertions, 2 deletions
diff --git a/src/vnet/ipsec/ipsec.h b/src/vnet/ipsec/ipsec.h
index 3d84ad3f6ad..fe44b80b321 100644
--- a/src/vnet/ipsec/ipsec.h
+++ b/src/vnet/ipsec/ipsec.h
@@ -26,6 +26,10 @@
#include <vnet/ipsec/ipsec_spd_policy.h>
#include <vnet/ipsec/ipsec_sa.h>
+#include <vppinfra/bihash_8_8.h>
+
+#include <vppinfra/bihash_24_8.h>
+
typedef clib_error_t *(*add_del_sa_sess_cb_t) (u32 sa_index, u8 is_add);
typedef clib_error_t *(*check_support_cb_t) (ipsec_sa_t * sa);
typedef clib_error_t *(*enable_disable_cb_t) (int is_enable);
@@ -125,8 +129,9 @@ typedef struct
uword *ipsec6_if_pool_index_by_key;
uword *ipsec_if_real_dev_by_show_dev;
uword *ipsec_if_by_sw_if_index;
- uword *tun4_protect_by_key;
- uword *tun6_protect_by_key;
+
+ clib_bihash_8_8_t tun4_protect_by_key;
+ clib_bihash_24_8_t tun6_protect_by_key;
/* node indices */
u32 error_drop_node_index;