This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "".
The branch, master has been updated via fa9550ca8f4f0a77baf6d156b441fa2d703bbdf8 (commit) via 063d713d0c167c56b4497be566b2310a5a2daf42 (commit) from 3eeb249a4774f12d2d16ca349a591654eae620ae (commit)
Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below.
- Log ----------------------------------------------------------------- commit fa9550ca8f4f0a77baf6d156b441fa2d703bbdf8 Author: Maxim Uvarov maxim.uvarov@linaro.org Date: Wed Jul 19 16:15:23 2017 +0000
helper: add missing pool param inits
Signed-off-by: Maxim Uvarov maxim.uvarov@linaro.org Reviewed-by: Bill Fischofer bill.fischofer@linaro.org
diff --git a/helper/cuckootable.c b/helper/cuckootable.c index 0d46300e..32800911 100644 --- a/helper/cuckootable.c +++ b/helper/cuckootable.c @@ -240,6 +240,7 @@ odph_cuckoo_table_create( if (pool != ODP_POOL_INVALID) odp_pool_destroy(pool);
+ odp_pool_param_init(¶m); param.type = ODP_POOL_BUFFER; param.buf.size = kv_entry_size; param.buf.align = ODP_CACHE_LINE_SIZE; diff --git a/helper/iplookuptable.c b/helper/iplookuptable.c index 37d31e36..ac7d0587 100644 --- a/helper/iplookuptable.c +++ b/helper/iplookuptable.c @@ -192,6 +192,7 @@ cache_alloc_new_pool( uint32_t size = 0, num = 0;
/* Create new pool (new free buffers). */ + odp_pool_param_init(¶m); param.type = ODP_POOL_BUFFER; param.buf.align = ODP_CACHE_LINE_SIZE; if (type == CACHE_TYPE_SUBTREE) {
commit 063d713d0c167c56b4497be566b2310a5a2daf42 Author: Maxim Uvarov maxim.uvarov@linaro.org Date: Wed Jul 19 15:51:55 2017 +0000
linux-gen: ishm fix defining directory for shm files
Code missed getenv() return code check and did not use value of env variable to change default derection.
Signed-off-by: Maxim Uvarov maxim.uvarov@linaro.org Reviewed-by: Bill Fischofer bill.fischofer@linaro.org
diff --git a/platform/linux-generic/_ishm.c b/platform/linux-generic/_ishm.c index cde2dbc3..892e889b 100644 --- a/platform/linux-generic/_ishm.c +++ b/platform/linux-generic/_ishm.c @@ -1442,9 +1442,15 @@ int _odp_ishm_init_global(void)
odp_global_data.main_pid = getpid(); odp_global_data.shm_dir = getenv("ODP_SHM_DIR"); - odp_global_data.shm_dir = - calloc(1, sizeof(ISHM_FILENAME_NORMAL_PAGE_DIR)); - sprintf(odp_global_data.shm_dir, "%s", ISHM_FILENAME_NORMAL_PAGE_DIR); + if (odp_global_data.shm_dir) { + odp_global_data.shm_dir_from_env = 1; + } else { + odp_global_data.shm_dir = + calloc(1, sizeof(ISHM_FILENAME_NORMAL_PAGE_DIR)); + sprintf(odp_global_data.shm_dir, "%s", + ISHM_FILENAME_NORMAL_PAGE_DIR); + odp_global_data.shm_dir_from_env = 0; + }
ODP_DBG("ishm: using dir %s\n", odp_global_data.shm_dir);
@@ -1661,7 +1667,8 @@ int _odp_ishm_term_global(void) if (_odp_ishmphy_unbook_va()) ret |= -1;
- free(odp_global_data.shm_dir); + if (!odp_global_data.shm_dir_from_env) + free(odp_global_data.shm_dir);
return ret; } diff --git a/platform/linux-generic/include/odp_internal.h b/platform/linux-generic/include/odp_internal.h index dd3374b7..ec17b199 100644 --- a/platform/linux-generic/include/odp_internal.h +++ b/platform/linux-generic/include/odp_internal.h @@ -43,6 +43,7 @@ typedef struct {
struct odp_global_data_s { char *shm_dir; /*< directory for odp mmaped files */ + int shm_dir_from_env; /*< overload default with env */ pid_t main_pid; char uid[UID_MAXLEN]; odp_log_func_t log_fn;
-----------------------------------------------------------------------
Summary of changes: helper/cuckootable.c | 1 + helper/iplookuptable.c | 1 + platform/linux-generic/_ishm.c | 15 +++++++++++---- platform/linux-generic/include/odp_internal.h | 1 + 4 files changed, 14 insertions(+), 4 deletions(-)
hooks/post-receive