summaryrefslogtreecommitdiffstats
path: root/src/plugins/ixge
diff options
context:
space:
mode:
authorDamjan Marion <damarion@cisco.com>2017-10-12 13:09:26 +0200
committerDave Barach <openvpp@barachs.net>2017-10-25 19:04:06 +0000
commit149ba779cff4ffc48d87ca67a2a8d4afd49b05f5 (patch)
treebc0467669b33b745fe4f44d4d0c787cf53900536 /src/plugins/ixge
parenta19d7b822ae9584cde522aefba36915e2af58846 (diff)
vlib: add support for multiple buffer pools
Change-Id: Icaf7d7ad47284aea7a56e8006b69f45874d64202 Signed-off-by: Damjan Marion <damarion@cisco.com>
Diffstat (limited to 'src/plugins/ixge')
-rw-r--r--src/plugins/ixge/ixge.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/src/plugins/ixge/ixge.c b/src/plugins/ixge/ixge.c
index 5fd6a901e35..f9d01d55ffd 100644
--- a/src/plugins/ixge/ixge.c
+++ b/src/plugins/ixge/ixge.c
@@ -2528,8 +2528,9 @@ ixge_dma_init (ixge_device_t * xd, vlib_rx_or_tx_t rt, u32 queue_index)
u32 i;
dq->tx.head_index_write_back =
- vlib_physmem_alloc (vm, vm->buffer_main->physmem_region, &error,
- CLIB_CACHE_LINE_BYTES);
+ vlib_physmem_alloc (vm,
+ vm->buffer_main->buffer_pools[0].physmem_region,
+ &error, CLIB_CACHE_LINE_BYTES);
for (i = 0; i < dq->n_descriptors; i++)
dq->descriptors[i].tx = xm->tx_descriptor_template;
@@ -2542,7 +2543,9 @@ ixge_dma_init (ixge_device_t * xd, vlib_rx_or_tx_t rt, u32 queue_index)
u64 a;
a =
- vlib_physmem_virtual_to_physical (vm, vm->buffer_main->physmem_region,
+ vlib_physmem_virtual_to_physical (vm,
+ vm->buffer_main->
+ buffer_pools[0].physmem_region,
dq->descriptors);
dr->descriptor_address[0] = a & 0xFFFFFFFF;
dr->descriptor_address[1] = a >> (u64) 32;
@@ -2570,7 +2573,8 @@ ixge_dma_init (ixge_device_t * xd, vlib_rx_or_tx_t rt, u32 queue_index)
a =
vlib_physmem_virtual_to_physical (vm,
- vm->buffer_main->physmem_region,
+ vm->buffer_main->
+ buffer_pools[0].physmem_region,
dq->tx.head_index_write_back);
dr->tx.head_index_write_back_address[0] = /* enable bit */ 1 | a;
dr->tx.head_index_write_back_address[1] = (u64) a >> (u64) 32;