Skip to content

Commit

Permalink
linux-gen: thread: implement max control/worker thread count functions
Browse files Browse the repository at this point in the history
Implement new functions odp_thread_control_count_max() and
odp_thread_worker_count_max() for reading the maximum number of control and
worker threads.

Signed-off-by: Matias Elo <matias.elo@nokia.com>
Reviewed-by: Tuomas Taipale <tuomas.taipale@nokia.com>
  • Loading branch information
MatiasElo committed Dec 19, 2023
1 parent 4be38ff commit 04e78b4
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions platform/linux-generic/odp_thread.c
Original file line number Diff line number Diff line change
Expand Up @@ -272,6 +272,16 @@ int odp_thread_count_max(void)
return thread_globals->num_max;
}

int odp_thread_control_count_max(void)
{
return thread_globals->num_max;
}

int odp_thread_worker_count_max(void)
{
return thread_globals->num_max;
}

int odp_thrmask_worker(odp_thrmask_t *mask)
{
odp_thrmask_copy(mask, &thread_globals->worker);
Expand Down

0 comments on commit 04e78b4

Please sign in to comment.