diff options
author | Petri Savolainen <petri.savolainen@linaro.org> | 2015-02-13 05:32:47 +0200 |
---|---|---|
committer | Maxim Uvarov <maxim.uvarov@linaro.org> | 2015-02-16 15:08:31 +0300 |
commit | dece68d4c710aa7fedc40e24fff6254a1502170b (patch) | |
tree | d1e35f4da03309f39d3bd3c3d37f4815605bb449 /example/packet/odp_pktio.c | |
parent | 0b0ed4323cf6b827010257cc18cb55552d39f5ae (diff) |
api: pool: Move from buffer to packet pool parameters
Change implementation, examples and test to use the new
packet pool parameters with ODP_POOL_PACKET type pools
(instead of using buffer pool parameters).
Signed-off-by: Petri Savolainen <petri.savolainen@linaro.org>
Reviewed-and-tested-by: Bill Fischofer <bill.fischofer@linaro.org>
Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
Diffstat (limited to 'example/packet/odp_pktio.c')
-rw-r--r-- | example/packet/odp_pktio.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/example/packet/odp_pktio.c b/example/packet/odp_pktio.c index 194173c..5eec796 100644 --- a/example/packet/odp_pktio.c +++ b/example/packet/odp_pktio.c @@ -337,10 +337,11 @@ int main(int argc, char *argv[]) printf("cpu mask: %s\n", cpumaskstr); /* Create packet pool */ - params.buf.size = SHM_PKT_POOL_BUF_SIZE; - params.buf.align = 0; - params.buf.num = SHM_PKT_POOL_SIZE/SHM_PKT_POOL_BUF_SIZE; - params.type = ODP_POOL_PACKET; + memset(¶ms, 0, sizeof(params)); + params.pkt.seg_len = SHM_PKT_POOL_BUF_SIZE; + params.pkt.len = SHM_PKT_POOL_BUF_SIZE; + params.pkt.num = SHM_PKT_POOL_SIZE/SHM_PKT_POOL_BUF_SIZE; + params.type = ODP_POOL_PACKET; pool = odp_pool_create("packet_pool", ODP_SHM_NULL, ¶ms); |