diff options
author | Jere Leppänen <jere.leppanen@nokia.com> | 2021-09-29 14:22:35 +0300 |
---|---|---|
committer | Matias Elo <matias.elo@nokia.com> | 2021-11-12 09:48:41 +0200 |
commit | 7ecdf0cf813a391cd2e4e1847675ecca1b5e474b (patch) | |
tree | 7cbca4a0502e64d8669674516c09c5db7c338393 /helper/include | |
parent | 7bef61ebe885c6a089d1cd7b3f7f3b6bdf7b8cf7 (diff) |
helper: threads: deprecate old functions and parameters
Deprecate odph_thread_param_t::instance, odph_odpthread_t,
odph_odpthread_params_t, odph_odpthreads_create() and
odph_odpthreads_join().
Signed-off-by: Jere Leppänen <jere.leppanen@nokia.com>
Reviewed-by: Matias Elo <matias.elo@nokia.com>
Diffstat (limited to 'helper/include')
-rw-r--r-- | helper/include/odp/helper/threads.h | 18 |
1 files changed, 11 insertions, 7 deletions
diff --git a/helper/include/odp/helper/threads.h b/helper/include/odp/helper/threads.h index d7cb0ac2a..f16626abf 100644 --- a/helper/include/odp/helper/threads.h +++ b/helper/include/odp/helper/threads.h @@ -23,6 +23,8 @@ extern "C" { #endif +#include <odp/helper/deprecated.h> + #include <pthread.h> #include <getopt.h> #include <sys/types.h> @@ -67,7 +69,7 @@ typedef struct { odp_thread_type_t thr_type; /** @deprecated ODP instance handle for odph_odpthreads_create(). */ - odp_instance_t instance; + odp_instance_t ODPH_DEPRECATE(instance); /** * Minimum stack size in bytes. 0 = use default. Ignored by @@ -128,10 +130,10 @@ typedef struct { } odph_helper_options_t; /** @deprecated Legacy thread table entry */ -typedef odph_thread_t odph_odpthread_t; +typedef odph_thread_t ODPH_DEPRECATE(odph_odpthread_t); /** @deprecated Legacy thread parameters */ -typedef odph_thread_param_t odph_odpthread_params_t; +typedef odph_thread_param_t ODPH_DEPRECATE(odph_odpthread_params_t); /** Common parameters for odph_thread_create() call */ typedef struct { @@ -292,9 +294,10 @@ int odph_thread_join(odph_thread_t thread[], int num); * * @deprecated Use odph_thread_create() instead. */ -int odph_odpthreads_create(odph_odpthread_t *thread_tbl, - const odp_cpumask_t *mask, - const odph_odpthread_params_t *thr_params); +int ODPH_DEPRECATE(odph_odpthreads_create)( + ODPH_DEPRECATE(odph_odpthread_t) *thread_tbl, + const odp_cpumask_t *mask, + const ODPH_DEPRECATE(odph_odpthread_params_t) *thr_params); /** * Waits odpthreads (as linux threads or processes) to exit. @@ -308,7 +311,8 @@ int odph_odpthreads_create(odph_odpthread_t *thread_tbl, * * @deprecated Use odph_thread_join() instead. */ -int odph_odpthreads_join(odph_odpthread_t *thread_tbl); +int ODPH_DEPRECATE(odph_odpthreads_join)( + ODPH_DEPRECATE(odph_odpthread_t) *thread_tbl); /** * Set CPU affinity of the current odp thread |