diff mbox

[1/4] linux-generic: zero params for pool create

Message ID 1431079069-9702-2-git-send-email-maxim.uvarov@linaro.org
State New
Headers show

Commit Message

Maxim Uvarov May 8, 2015, 9:57 a.m. UTC
Adding more params to pool create breaks original work.
Make sure that not set params are zero.

Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
---
 platform/linux-generic/odp_schedule.c | 1 +
 test/validation/odp_queue.c           | 1 +
 2 files changed, 2 insertions(+)
diff mbox

Patch

diff --git a/platform/linux-generic/odp_schedule.c b/platform/linux-generic/odp_schedule.c
index 7fe42d7..a63f97a 100644
--- a/platform/linux-generic/odp_schedule.c
+++ b/platform/linux-generic/odp_schedule.c
@@ -123,6 +123,7 @@  int odp_schedule_init_global(void)
 
 	memset(sched, 0, sizeof(sched_t));
 
+	memset(&params, 0, sizeof(params));
 	params.buf.size  = sizeof(sched_cmd_t);
 	params.buf.align = 0;
 	params.buf.num   = NUM_SCHED_CMD;
diff --git a/test/validation/odp_queue.c b/test/validation/odp_queue.c
index 5d47399..4354ce1 100644
--- a/test/validation/odp_queue.c
+++ b/test/validation/odp_queue.c
@@ -18,6 +18,7 @@  static int init_queue_suite(void)
 {
 	odp_pool_param_t params;
 
+	memset(&params, 0, sizeof(params));
 	params.buf.size  = 0;
 	params.buf.align = ODP_CACHE_LINE_SIZE;
 	params.buf.num   = 1024 * 10;