summaryrefslogtreecommitdiffstats
path: root/src/vlib/threads.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/vlib/threads.c')
-rw-r--r--src/vlib/threads.c12
1 files changed, 2 insertions, 10 deletions
diff --git a/src/vlib/threads.c b/src/vlib/threads.c
index 9ccfd3a2901..b7bc9e26c0c 100644
--- a/src/vlib/threads.c
+++ b/src/vlib/threads.c
@@ -35,16 +35,8 @@ vl (void *p)
vlib_worker_thread_t *vlib_worker_threads;
vlib_thread_main_t vlib_thread_main;
-__thread uword vlib_thread_index = 0;
-
-uword
-os_get_cpu_number (void)
-{
- return vlib_thread_index;
-}
-
uword
-os_get_ncpus (void)
+os_get_nthreads (void)
{
u32 len;
@@ -467,7 +459,7 @@ vlib_worker_thread_bootstrap_fn (void *arg)
w->lwp = syscall (SYS_gettid);
w->thread_id = pthread_self ();
- vlib_thread_index = w - vlib_worker_threads;
+ __os_thread_index = w - vlib_worker_threads;
rv = (void *) clib_calljmp
((uword (*)(uword)) w->thread_function,