diff options
author | Damjan Marion <damarion@cisco.com> | 2022-01-04 20:15:59 +0100 |
---|---|---|
committer | Ole Tr�an <otroan@employees.org> | 2022-01-05 10:42:58 +0000 |
commit | 70e808b1bfc25d1664ddb917457040b419e123c8 (patch) | |
tree | b5d34b718052c905a91ac77656de8287d5c69f0a /src/plugins/dpdk/device/flow.c | |
parent | 7dc6f7fb497e9c9eac96057b2528fb072225a809 (diff) |
dpdk: remove "convenience" vars
It is actually longer and slower...
Type: refactor
Change-Id: I0f126d4cdb13ecc60a2d370409f23820d7f7eb72
Signed-off-by: Damjan Marion <damarion@cisco.com>
Diffstat (limited to 'src/plugins/dpdk/device/flow.c')
-rw-r--r-- | src/plugins/dpdk/device/flow.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/plugins/dpdk/device/flow.c b/src/plugins/dpdk/device/flow.c index 850476b87c1..19d504e5514 100644 --- a/src/plugins/dpdk/device/flow.c +++ b/src/plugins/dpdk/device/flow.c @@ -555,6 +555,7 @@ int dpdk_flow_ops_fn (vnet_main_t * vnm, vnet_flow_dev_op_t op, u32 dev_instance, u32 flow_index, uword * private_data) { + vlib_main_t *vm = vlib_get_main (); dpdk_main_t *dm = &dpdk_main; vnet_flow_t *flow = vnet_get_flow (flow_index); dpdk_device_t *xd = vec_elt_at_index (dm->devices, dev_instance); @@ -565,7 +566,7 @@ dpdk_flow_ops_fn (vnet_main_t * vnm, vnet_flow_dev_op_t op, u32 dev_instance, /* recycle old flow lookup entries only after the main loop counter increases - i.e. previously DMA'ed packets were handled */ if (vec_len (xd->parked_lookup_indexes) > 0 && - xd->parked_loop_count != dm->vlib_main->main_loop_count) + xd->parked_loop_count != vm->main_loop_count) { u32 *fl_index; @@ -588,7 +589,7 @@ dpdk_flow_ops_fn (vnet_main_t * vnm, vnet_flow_dev_op_t op, u32 dev_instance, fle = pool_elt_at_index (xd->flow_lookup_entries, fe->mark); clib_memset (fle, -1, sizeof (*fle)); vec_add1 (xd->parked_lookup_indexes, fe->mark); - xd->parked_loop_count = dm->vlib_main->main_loop_count; + xd->parked_loop_count = vm->main_loop_count; } clib_memset (fe, 0, sizeof (*fe)); |