- unsigned int session_size =
- RTE_MAX(rte_cryptodev_asym_get_private_session_size(dev_id),
- rte_cryptodev_asym_get_header_session_size());
-
- if (session_pool_socket[socket_id].priv_mp == NULL) {
- snprintf(mp_name, RTE_MEMPOOL_NAMESIZE, "perf_asym_priv_pool%u",
- socket_id);
-
- mpool = rte_mempool_create(mp_name, nb_sessions, session_size,
- 0, 0, NULL, NULL, NULL, NULL,
- socket_id, 0);
- if (mpool == NULL) {
- printf("Cannot create pool \"%s\" on socket %d\n",
- mp_name, socket_id);
- return -ENOMEM;
- }
- printf("Allocated pool \"%s\" on socket %d\n", mp_name,
- socket_id);
- session_pool_socket[socket_id].priv_mp = mpool;
- }