Lines Matching refs:thread
21 struct thread { struct
37 struct thread *thread = arg; in thread_starter() local
39 thread->thread_task = current; in thread_starter()
41 hlist_add_head(&thread->thread_links, &thread_list); in thread_starter()
44 thread->thread_function(thread->thread_data); in thread_starter()
46 complete(&thread->thread_done); in thread_starter()
51 const char *name, struct thread **new_thread) in vdo_create_thread()
56 struct thread *thread; in vdo_create_thread() local
59 result = vdo_allocate(1, struct thread, __func__, &thread); in vdo_create_thread()
65 thread->thread_function = thread_function; in vdo_create_thread()
66 thread->thread_data = thread_data; in vdo_create_thread()
67 init_completion(&thread->thread_done); in vdo_create_thread()
83 task = kthread_run(thread_starter, thread, "%.*s:%s", in vdo_create_thread()
87 task = kthread_run(thread_starter, thread, "%s", name); in vdo_create_thread()
91 vdo_free(thread); in vdo_create_thread()
95 *new_thread = thread; in vdo_create_thread()
99 void vdo_join_threads(struct thread *thread) in vdo_join_threads() argument
101 while (wait_for_completion_interruptible(&thread->thread_done)) in vdo_join_threads()
105 hlist_del(&thread->thread_links); in vdo_join_threads()
107 vdo_free(thread); in vdo_join_threads()