OpenCores
URL https://opencores.org/ocsvn/or1k_old/or1k_old/trunk

Subversion Repositories or1k_old

[/] [or1k_old/] [trunk/] [newlib/] [newlib/] [libc/] [sys/] [rtems/] [include/] [signal.h] - Blame information for rev 1782

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 39 lampret
/*
2 56 joel
 *  $Id: signal.h,v 1.1.1.2 2000-08-30 19:04:14 joel Exp $
3 39 lampret
 */
4
 
5
#ifndef __POSIX_SIGNALS_h
6
#define __POSIX_SIGNALS_h
7
 
8 56 joel
#ifdef __cplusplus
9
extern "C" {
10
#endif
11
 
12 39 lampret
#include <sys/features.h>
13
#include "_ansi.h"
14
 
15
#include <sys/time.h>
16
#include <sys/siginfo.h>
17
#include <reent.h>        /* only for reentrant signal() and raise() */
18
 
19
/*
20
 *  7.7 Signal handling <signal.h>, ANSI C Standard.
21
 */
22
 
23
typedef int sig_atomic_t;
24
 
25
/*
26
 *  ANSI C Signal Handling Functions
27
 */
28
 
29
typedef void (*_sig_func_ptr) ();
30
 
31
_sig_func_ptr _EXFUN(_signal_r, (struct _reent *, int, _sig_func_ptr));
32
int _EXFUN(_raise_r, (struct _reent *, int));
33
 
34
#ifndef _REENT_ONLY
35
_sig_func_ptr _EXFUN(signal, (int, _sig_func_ptr));
36
int _EXFUN(raise, (int));
37
#endif
38
 
39
/*
40
 *  3.3.2 Send a Signal to a Process, P1003.1b-1993, p. 68
41
 *
42
 *  NOTE: Behavior of kill() depends on _POSIX_SAVED_IDS.
43
 */
44
 
45
int _EXFUN(kill, (pid_t pid, int sig));
46
 
47
/*
48
 *  3.3.3 Manipulate Signal Sets, P1003.1b-1993, p. 69
49
 */
50
 
51
int _EXFUN(sigemptyset, (sigset_t *set));
52
int _EXFUN(sigfillset,  (sigset_t *set));
53
int _EXFUN(sigaddset,   (sigset_t *set, int signo));
54
int _EXFUN(sigdelset,   (sigset_t *set, int signo));
55
int _EXFUN(sigismember, (const sigset_t *set, int signo));
56
 
57
/*
58
 *  3.3.4 Examine and Change Signal Action, P1003.1b-1993, p. 70
59
 */
60
 
61
int _EXFUN(sigaction,
62
           (int sig, const struct sigaction *act, struct sigaction *oact)
63
);
64
 
65
/*
66
 *  3.3.5 Examine and Change Blocked Signals, P1003.1b-1993, p. 73
67
 *
68
 *  NOTE: P1003.1c/D10, p. 37 adds pthread_sigmask().
69
 */
70
 
71
/* values for how */
72
 
73
#define SIG_BLOCK   1 /* resulting_set = (current_set | set)  */
74
#define SIG_UNBLOCK 2 /* resulting_set = (current_set & ~set)  */ 
75
#define SIG_SETMASK 3 /* resulting_set = set */
76
 
77
int _EXFUN(sigprocmask, (int how, const sigset_t *set, sigset_t *oset));
78
 
79
#if defined(_POSIX_THREADS)
80
int _EXFUN(pthread_sigmask, (int how, const sigset_t *set, sigset_t *oset));
81
#endif
82
 
83
/*
84
 *  3.3.6 Examine Pending Signals, P1003.1b-1993, p. 75
85
 */
86
 
87
int _EXFUN(sigpending, (sigset_t *set));
88
 
89
/*
90
 *  3.3.7 Wait for a Signal, P1003.1b-1993, p. 75
91
 */
92
 
93
int _EXFUN(sigsuspend, (const sigset_t *sigmask));
94
 
95
#if defined(_POSIX_REALTIME_SIGNALS)
96
 
97
/*
98
 *  3.3.8 Synchronously Accept a Signal, P1003.1b-1993, p. 76
99
 *
100
 *  NOTE: P1003.1c/D10, p. 39 adds sigwait().
101
 */
102
 
103
int _EXFUN(sigwaitinfo,  (const sigset_t *set, siginfo_t *info));
104
int _EXFUN(sigtimedwait,
105
  (const sigset_t *set, siginfo_t *info, const struct timespec  *timeout)
106
);
107
int _EXFUN(sigwait, (const sigset_t *set, int *sig));
108
 
109
/*
110
 *  3.3.9 Queue a Signal to a Process, P1003.1b-1993, p. 78
111
 */
112
 
113
int _EXFUN(sigqueue, (pid_t pid, int signo, const union sigval value));
114
 
115
#endif
116
 
117
/*
118
 *  3.3.10 Send a Signal to a Thread, P1003.1c/D10, p. 43
119
 */
120
 
121
#if defined(_POSIX_THREADS)
122
int _EXFUN(pthread_kill, (pthread_t thread, int sig));
123
#endif
124
 
125
/*
126
 *  3.4.1 Schedule Alarm, P1003.1b-1993, p. 79
127
 */
128
 
129
unsigned int _EXFUN(alarm, (unsigned int seconds));
130
 
131
/*
132
 *  3.4.2 Suspend Process Execution, P1003.1b-1993, p. 80
133
 */
134
 
135
int _EXFUN(pause, (void));
136
 
137 56 joel
#ifdef __cplusplus
138
}
139 39 lampret
#endif
140 56 joel
 
141
#endif
142 39 lampret
/* end of include file */

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.