From 1c1cdb89c3242461047d5b63430fa28090a9a65f Mon Sep 17 00:00:00 2001 From: Gregory Nutt Date: Fri, 10 Oct 2014 08:35:58 -0600 Subject: Decoupling work queue data structures. This is part of the preparation to support multiple low-priority worker threads --- nuttx/sched/init/os_bringup.c | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) (limited to 'nuttx/sched/init') diff --git a/nuttx/sched/init/os_bringup.c b/nuttx/sched/init/os_bringup.c index 751a15449..b4a5537d5 100644 --- a/nuttx/sched/init/os_bringup.c +++ b/nuttx/sched/init/os_bringup.c @@ -222,11 +222,11 @@ static inline void os_workqueues(void) svdbg("Starting kernel worker thread\n"); #endif - g_work[HPWORK].pid = kernel_thread(HPWORKNAME, CONFIG_SCHED_WORKPRIORITY, - CONFIG_SCHED_WORKSTACKSIZE, - (main_t)work_hpthread, - (FAR char * const *)NULL); - DEBUGASSERT(g_work[HPWORK].pid > 0); + g_hpwork.pid = kernel_thread(HPWORKNAME, CONFIG_SCHED_WORKPRIORITY, + CONFIG_SCHED_WORKSTACKSIZE, + (main_t)work_hpthread, + (FAR char * const *)NULL); + DEBUGASSERT(g_hpwork.pid > 0); /* Start a lower priority worker thread for other, non-critical continuation * tasks @@ -236,11 +236,11 @@ static inline void os_workqueues(void) svdbg("Starting low-priority kernel worker thread\n"); - g_work[LPWORK].pid = kernel_thread(LPWORKNAME, CONFIG_SCHED_LPWORKPRIORITY, - CONFIG_SCHED_LPWORKSTACKSIZE, - (main_t)work_lpthread, - (FAR char * const *)NULL); - DEBUGASSERT(g_work[LPWORK].pid > 0); + g_lpwork.pid = kernel_thread(LPWORKNAME, CONFIG_SCHED_LPWORKPRIORITY, + CONFIG_SCHED_LPWORKSTACKSIZE, + (main_t)work_lpthread, + (FAR char * const *)NULL); + DEBUGASSERT(g_lpwork.pid > 0); #endif /* CONFIG_SCHED_LPWORK */ #endif /* CONFIG_SCHED_HPWORK */ -- cgit v1.2.3