summaryrefslogtreecommitdiffstats
path: root/src/vnet/ip/ip_in_out_acl.c
diff options
context:
space:
mode:
authorBenoît Ganne <bganne@cisco.com>2022-11-18 17:05:10 +0100
committerDave Barach <vpp@barachs.net>2023-02-02 16:27:28 +0000
commit051d3a3f60d4a0bbbffd099f21d2fd914957b9a3 (patch)
treec3a05b4827df3bd0c874bc4d5f41960e8aa3796f /src/vnet/ip/ip_in_out_acl.c
parenta3f1b4c719b25595fc8f0214a29210abbfc34683 (diff)
ip: fix ip ACL traces
If we match a next table, we must save its index in the trace instead of the index of the 1st table. Type: fix Change-Id: Idd862242e7fc200eb3ab29b17a26131b844af2c0 Signed-off-by: Benoît Ganne <bganne@cisco.com>
Diffstat (limited to 'src/vnet/ip/ip_in_out_acl.c')
-rw-r--r--src/vnet/ip/ip_in_out_acl.c15
1 files changed, 9 insertions, 6 deletions
diff --git a/src/vnet/ip/ip_in_out_acl.c b/src/vnet/ip/ip_in_out_acl.c
index d8d6d768e93..11e3873b008 100644
--- a/src/vnet/ip/ip_in_out_acl.c
+++ b/src/vnet/ip/ip_in_out_acl.c
@@ -327,8 +327,9 @@ ip_in_out_acl_inline_trace (
{
while (1)
{
- if (PREDICT_TRUE (t[0]->next_table_index != ~0))
- t[0] = pool_elt_at_index (tables, t[0]->next_table_index);
+ table_index[0] = t[0]->next_table_index;
+ if (PREDICT_TRUE (table_index[0] != ~0))
+ t[0] = pool_elt_at_index (tables, table_index[0]);
else
{
_next[0] = (t[0]->miss_next_index < n_next_nodes) ?
@@ -434,8 +435,9 @@ ip_in_out_acl_inline_trace (
{
while (1)
{
- if (PREDICT_TRUE (t[1]->next_table_index != ~0))
- t[1] = pool_elt_at_index (tables, t[1]->next_table_index);
+ table_index[1] = t[1]->next_table_index;
+ if (PREDICT_TRUE (table_index[1] != ~0))
+ t[1] = pool_elt_at_index (tables, table_index[1]);
else
{
_next[1] = (t[1]->miss_next_index < n_next_nodes) ?
@@ -636,8 +638,9 @@ ip_in_out_acl_inline_trace (
{
while (1)
{
- if (PREDICT_TRUE (t0->next_table_index != ~0))
- t0 = pool_elt_at_index (tables, t0->next_table_index);
+ table_index0 = t0->next_table_index;
+ if (PREDICT_TRUE (table_index0 != ~0))
+ t0 = pool_elt_at_index (tables, table_index0);
else
{
next0 = (t0->miss_next_index < n_next_nodes) ?