diff mbox

[API-NEXT,PATCHv3,8/9] validation: common: return number of threads created

Message ID 1437485540-4862-9-git-send-email-stuart.haslam@linaro.org
State Superseded
Headers show

Commit Message

Stuart Haslam July 21, 2015, 1:32 p.m. UTC
odph_linux_pthread_create() now returns the number of threads created,
so modify odp_cunit_thread_create() to do the same.

Signed-off-by: Stuart Haslam <stuart.haslam@linaro.org>
---
 test/validation/common/odp_cunit_common.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

Comments

Christophe Milard July 22, 2015, 11:12 a.m. UTC | #1
On 2015-07-21 14:32, Stuart Haslam wrote:
> odph_linux_pthread_create() now returns the number of threads created,
> so modify odp_cunit_thread_create() to do the same.
> 
> Signed-off-by: Stuart Haslam <stuart.haslam@linaro.org>

Reviewed-by: Christophe Milard <christophe.milard@linaro.org>

> ---
>  test/validation/common/odp_cunit_common.c | 5 ++---
>  1 file changed, 2 insertions(+), 3 deletions(-)
> 
> diff --git a/test/validation/common/odp_cunit_common.c b/test/validation/common/odp_cunit_common.c
> index 807325b..d995ad3 100644
> --- a/test/validation/common/odp_cunit_common.c
> +++ b/test/validation/common/odp_cunit_common.c
> @@ -29,10 +29,9 @@ int odp_cunit_thread_create(void *func_ptr(void *), pthrd_arg *arg)
>  
>  	/* Create and init additional threads */
>  	odp_cpumask_def_worker(&cpumask, arg->numthrds);
> -	odph_linux_pthread_create(thread_tbl, &cpumask, func_ptr,
> -				  (void *)arg);
>  
> -	return 0;
> +	return odph_linux_pthread_create(thread_tbl, &cpumask, func_ptr,
> +					 (void *)arg);
>  }
>  
>  /** exit from test thread */
> -- 
> 2.1.1
> 
> _______________________________________________
> lng-odp mailing list
> lng-odp@lists.linaro.org
> https://lists.linaro.org/mailman/listinfo/lng-odp
diff mbox

Patch

diff --git a/test/validation/common/odp_cunit_common.c b/test/validation/common/odp_cunit_common.c
index 807325b..d995ad3 100644
--- a/test/validation/common/odp_cunit_common.c
+++ b/test/validation/common/odp_cunit_common.c
@@ -29,10 +29,9 @@  int odp_cunit_thread_create(void *func_ptr(void *), pthrd_arg *arg)
 
 	/* Create and init additional threads */
 	odp_cpumask_def_worker(&cpumask, arg->numthrds);
-	odph_linux_pthread_create(thread_tbl, &cpumask, func_ptr,
-				  (void *)arg);
 
-	return 0;
+	return odph_linux_pthread_create(thread_tbl, &cpumask, func_ptr,
+					 (void *)arg);
 }
 
 /** exit from test thread */