summaryrefslogtreecommitdiff
path: root/lib/workqueue.c
diff options
context:
space:
mode:
authorDonald Sharp <sharpd@nvidia.com>2022-12-11 10:51:58 -0500
committerDonald Sharp <sharpd@nvidia.com>2023-03-24 08:32:17 -0400
commit5f6eaa9b9668f3f09fbf6b1dc4e0645e07f641c9 (patch)
treed8639a3f042a0de1e66bad71d330205619052b6e /lib/workqueue.c
parent70c35c11f2af5f169db446ef02ac0dda7b2822fc (diff)
*: Convert a bunch of thread_XX to event_XX
Convert these functions: thread_getrusage thread_cmd_init thread_consumed_time thread_timer_to_hhmmss thread_is_scheduled thread_ignore_late_timer Signed-off-by: Donald Sharp <sharpd@nvidia.com>
Diffstat (limited to 'lib/workqueue.c')
-rw-r--r--lib/workqueue.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/workqueue.c b/lib/workqueue.c
index 7660663449..cba611cd15 100644
--- a/lib/workqueue.c
+++ b/lib/workqueue.c
@@ -106,27 +106,27 @@ void work_queue_free_and_null(struct work_queue **wqp)
bool work_queue_is_scheduled(struct work_queue *wq)
{
- return thread_is_scheduled(wq->thread);
+ return event_is_scheduled(wq->thread);
}
static int work_queue_schedule(struct work_queue *wq, unsigned int delay)
{
/* if appropriate, schedule work queue thread */
if (CHECK_FLAG(wq->flags, WQ_UNPLUGGED) &&
- !thread_is_scheduled(wq->thread) && !work_queue_empty(wq)) {
+ !event_is_scheduled(wq->thread) && !work_queue_empty(wq)) {
/* Schedule timer if there's a delay, otherwise just schedule
* as an 'event'
*/
if (delay > 0) {
event_add_timer_msec(wq->master, work_queue_run, wq,
delay, &wq->thread);
- thread_ignore_late_timer(wq->thread);
+ event_ignore_late_timer(wq->thread);
} else
event_add_event(wq->master, work_queue_run, wq, 0,
&wq->thread);
/* set thread yield time, if needed */
- if (thread_is_scheduled(wq->thread) &&
+ if (event_is_scheduled(wq->thread) &&
wq->spec.yield != EVENT_YIELD_TIME_SLOT)
event_set_yield_time(wq->thread, wq->spec.yield);
return 1;