xref: /linux/drivers/md/dm-vdo/thread-utils.h (revision e6a901a00822659181c93c86d8bbc2a17779fddc)
1 /* SPDX-License-Identifier: GPL-2.0-only */
2 /*
3  * Copyright 2023 Red Hat
4  */
5 
6 #ifndef THREAD_UTILS_H
7 #define THREAD_UTILS_H
8 
9 #include <linux/atomic.h>
10 
11 /* Thread and synchronization utilities */
12 
13 struct thread;
14 
15 void vdo_initialize_threads_mutex(void);
16 int __must_check vdo_create_thread(void (*thread_function)(void *), void *thread_data,
17 				   const char *name, struct thread **new_thread);
18 void vdo_join_threads(struct thread *thread);
19 
20 #endif /* UDS_THREADS_H */
21