summaryrefslogtreecommitdiffstats
path: root/src/plugins/rdma
diff options
context:
space:
mode:
authorAndreas Schultz <andreas.schultz@travelping.com>2019-07-15 15:40:56 +0200
committerDave Barach <openvpp@barachs.net>2019-07-18 15:07:26 +0000
commit58b2eb1af562c292feb6d3cdce4656746e61da75 (patch)
treeba2d239dd4a2d4673ef1352143d1133a9f88ccd4 /src/plugins/rdma
parenta0cb32cb9fba93ec4b91e7d227c07d1b2099091b (diff)
vlib: convert frame_index into real pointers
The fast path almost always has to deal with the real pointers. Deriving the frame pointer from a frame_index requires a load of the 32bit frame_index from memory, another 64bit load of the heap base pointer and some calculations. Lets store the full pointer instead and do a single 64bit load only. This helps avoiding problems when the heap is grown and frames are allocated below vm->heap_aligned_base. Type: refactor Change-Id: Ifa6e6e984aafe1e2755bff80f0a4dfcddee3623c Signed-off-by: Andreas Schultz <andreas.schultz@travelping.com> Signed-off-by: Dave Barach <dave@barachs.net>
Diffstat (limited to 'src/plugins/rdma')
-rw-r--r--src/plugins/rdma/input.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/plugins/rdma/input.c b/src/plugins/rdma/input.c
index 02ac9bf27c6..7ced1ec66d4 100644
--- a/src/plugins/rdma/input.c
+++ b/src/plugins/rdma/input.c
@@ -182,7 +182,7 @@ rdma_device_input_ethernet (vlib_main_t * vm, vlib_node_runtime_t * node,
nf =
vlib_node_runtime_get_next_frame (vm, node, rd->per_interface_next_index);
- f = vlib_get_frame (vm, nf->frame_index);
+ f = vlib_get_frame (vm, nf->frame);
f->flags = ETH_INPUT_FRAME_F_SINGLE_SW_IF_IDX;
/* FIXME: f->flags |= ETH_INPUT_FRAME_F_IP4_CKSUM_OK; */