1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
| | /* SPDX-License-Identifier: GPL-2.0-or-later
* Copyright (c) 2025 Red Hat
* Author: Laurent Vivier <lvivier@redhat.com>
*/
#ifndef THREADING_H
#define THREADING_H
#define MAX_NUM_THREADS 32
#define THREADING_ID_DEFAULT 0
void threading_init(void);
int threading_worker_set(unsigned int threadid,
void (*worker)(void *, int, struct epoll_event *),
void *opaque);
int threading_epollfd(unsigned int threadid);
void threading_start_thread(unsigned int threadid);
void threading_stop_thread(unsigned int threadid);
bool threading_is_active(unsigned int threadid);
#endif /* THREADING_H */
|