@@ -497,14 +497,17 @@ static int check_params(odp_pool_param_t *params)
odp_pool_t odp_pool_create(const char *name, odp_pool_param_t *params)
{
+ uint32_t shm_flags = 0;
+
+ if (check_params(params))
+ return ODP_POOL_INVALID;
+
#ifdef _ODP_PKTIO_IPC
if (params && (params->type == ODP_POOL_PACKET))
- return pool_create(name, params, ODP_SHM_PROC);
+ shm_flags = ODP_SHM_PROC;
#endif
- if (check_params(params))
- return ODP_POOL_INVALID;
- return pool_create(name, params, 0);
+ return pool_create(name, params, shm_flags);
}
int odp_pool_destroy(odp_pool_t pool_hdl)
Make code more accurate and nice view, no functional changes. Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org> --- platform/linux-generic/odp_pool.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) -- 2.7.1.250.gff4ea60