libc: add sched.h and signal.h headers
This commit is contained in:
@@ -0,0 +1,14 @@
|
||||
#ifndef SCHED_H_
|
||||
#define SCHED_H_
|
||||
|
||||
#include <time.h>
|
||||
|
||||
struct sched_param {
|
||||
int sched_priority;
|
||||
int sched_ss_low_priority;
|
||||
struct timespec sched_ss_repl_period;
|
||||
struct timespec sched_ss_init_budget;
|
||||
int sched_ss_max_repl;
|
||||
};
|
||||
|
||||
#endif
|
||||
@@ -0,0 +1,57 @@
|
||||
#ifndef SIGNAL_H_
|
||||
#define SIGNAL_H_
|
||||
|
||||
#define SIG_IGN 0
|
||||
#define SIG_HOLD 1
|
||||
#define SIG_ERR 2
|
||||
#define SIG_DFL 3
|
||||
|
||||
#define SIGEV_NONE 0
|
||||
#define SIGEV_SIGNAL 1
|
||||
#define SIGEV_THREAD 2
|
||||
|
||||
#define SIGABRT 1
|
||||
#define SIGALRM 2
|
||||
#define SIGBUS 3
|
||||
#define SIGCHLD 4
|
||||
#define SIGCONT 5
|
||||
#define SIGFPE 6
|
||||
#define SIGHUP 7
|
||||
#define SIGILL 8
|
||||
#define SIGINT 9
|
||||
#define SIGKILL 10
|
||||
#define SIGPIPE 11
|
||||
#define SIGQUIT 12
|
||||
#define SIGSEGV 13
|
||||
#define SIGSTOP 14
|
||||
#define SIGTERM 15
|
||||
#define SIGTSTP 16
|
||||
#define SIGTTIN 17
|
||||
#define SIGTTOU 18
|
||||
#define SIGUSR1 19
|
||||
#define SIGUSR2 20
|
||||
#define SIGPOLL 21
|
||||
#define SIGPROF 22
|
||||
#define SIGSYS 23
|
||||
#define SIGTRAP 24
|
||||
#define SIGURG 25
|
||||
#define SIGVTALRM 26
|
||||
#define SIGXCPU 27
|
||||
#define SIGXFSZ 28
|
||||
|
||||
typedef long long sigset_t;
|
||||
|
||||
union sigval {
|
||||
int sival_int;
|
||||
void *sival_ptr;
|
||||
};
|
||||
|
||||
struct sigevent {
|
||||
int sigev_notify;
|
||||
int sigev_signo;
|
||||
union sigval sigev_value;
|
||||
void (*sigev_notify_function)(union sigval);
|
||||
/* TODO pthread_attr_t sigev_notify_attributes */
|
||||
};
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user