diff options
author | Matus Fabian <matfabia@cisco.com> | 2017-09-19 05:42:38 -0700 |
---|---|---|
committer | Ole Trøan <otroan@employees.org> | 2017-09-20 06:47:20 +0000 |
commit | 092b3cd59f17d5c3ebe167d8729273838afbe2cb (patch) | |
tree | 3a082495ac32f2665a0032726c00868b19de9262 /src/plugins/nat/nat_api.c | |
parent | f22f07dec90b7250f908d0085c1cf328f7d27138 (diff) |
NAT: move session and user lookup tables to per thread data (VPP-986)
Change-Id: I41a51bb36e31e05c76fef0b34fe006afbee27729
Signed-off-by: Matus Fabian <matfabia@cisco.com>
Diffstat (limited to 'src/plugins/nat/nat_api.c')
-rw-r--r-- | src/plugins/nat/nat_api.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/plugins/nat/nat_api.c b/src/plugins/nat/nat_api.c index fa20f2cc6b2..50b4a9ae8e1 100644 --- a/src/plugins/nat/nat_api.c +++ b/src/plugins/nat/nat_api.c @@ -870,7 +870,7 @@ static void tsm = vec_elt_at_index (sm->per_thread_data, value.value); else tsm = vec_elt_at_index (sm->per_thread_data, sm->num_workers); - if (clib_bihash_search_8_8 (&sm->user_hash, &key, &value)) + if (clib_bihash_search_8_8 (&tsm->user_hash, &key, &value)) return; u = pool_elt_at_index (tsm->users, value.value); if (!u->nsessions && !u->nstaticsessions) @@ -2105,7 +2105,7 @@ vl_api_nat44_user_session_dump_t_handler (vl_api_nat44_user_session_dump_t * tsm = vec_elt_at_index (sm->per_thread_data, value.value); else tsm = vec_elt_at_index (sm->per_thread_data, sm->num_workers); - if (clib_bihash_search_8_8 (&sm->user_hash, &key, &value)) + if (clib_bihash_search_8_8 (&tsm->user_hash, &key, &value)) return; u = pool_elt_at_index (tsm->users, value.value); if (!u->nsessions && !u->nstaticsessions) |