cleanup types stuff in headers, fix missing u_int*_t in sys/types.h
[musl] / include / sched.h
1 #ifndef _SCHED_H
2 #define _SCHED_H
3 #ifdef __cplusplus
4 extern "C" {
5 #endif
6
7 #define __NEED_struct_timespec
8 #define __NEED_pid_t
9 #define __NEED_time_t
10
11 #include <bits/alltypes.h>
12
13 struct sched_param {
14         int sched_priority;
15         int sched_ss_low_priority;
16         struct timespec sched_ss_repl_period;
17         struct timespec sched_ss_init_budget;
18         int sched_ss_max_repl;
19 };
20
21 int    sched_get_priority_max(int);
22 int    sched_get_priority_min(int);
23 int    sched_getparam(pid_t, struct sched_param *);
24 int    sched_getscheduler(pid_t);
25 int    sched_rr_get_interval(pid_t, struct timespec *);
26 int    sched_setparam(pid_t, const struct sched_param *);
27 int    sched_setscheduler(pid_t, int, const struct sched_param *);
28 int     sched_yield(void);
29
30 #define SCHED_OTHER 0
31 #define SCHED_FIFO 1
32 #define SCHED_RR 2
33
34 #ifdef __cplusplus
35 }
36 #endif
37 #endif