1 | .. comment SPDX-License-Identifier: CC-BY-SA-4.0 |
---|
2 | |
---|
3 | .. COMMENT: COPYRIGHT (c) 1988-2002. |
---|
4 | .. COMMENT: On-Line Applications Research Corporation (OAR). |
---|
5 | .. COMMENT: All rights reserved. |
---|
6 | |
---|
7 | Thread Cancellation Manager |
---|
8 | ########################### |
---|
9 | |
---|
10 | Introduction |
---|
11 | ============ |
---|
12 | |
---|
13 | The |
---|
14 | thread cancellation manager is ... |
---|
15 | |
---|
16 | The directives provided by the thread cancellation manager are: |
---|
17 | |
---|
18 | - pthread_cancel_ - Cancel Execution of a Thread |
---|
19 | |
---|
20 | - pthread_setcancelstate_ - Set Cancelability State |
---|
21 | |
---|
22 | - pthread_setcanceltype_ - Set Cancelability Type |
---|
23 | |
---|
24 | - pthread_testcancel_ - Create Cancellation Point |
---|
25 | |
---|
26 | - pthread_cleanup_push_ - Establish Cancellation Handler |
---|
27 | |
---|
28 | - pthread_cleanup_pop_ - Remove Cancellation Handler |
---|
29 | |
---|
30 | Background |
---|
31 | ========== |
---|
32 | |
---|
33 | There is currently no text in this section. |
---|
34 | |
---|
35 | Operations |
---|
36 | ========== |
---|
37 | |
---|
38 | There is currently no text in this section. |
---|
39 | |
---|
40 | Directives |
---|
41 | ========== |
---|
42 | |
---|
43 | This section details the thread cancellation manager's directives. A |
---|
44 | subsection is dedicated to each of this manager's directives and describes the |
---|
45 | calling sequence, related constants, usage, and status codes. |
---|
46 | |
---|
47 | .. _pthread_cancel: |
---|
48 | |
---|
49 | pthread_cancel - Cancel Execution of a Thread |
---|
50 | --------------------------------------------- |
---|
51 | .. index:: pthread_cancel |
---|
52 | .. index:: cancel execution of a thread |
---|
53 | |
---|
54 | **CALLING SEQUENCE:** |
---|
55 | |
---|
56 | .. code-block:: c |
---|
57 | |
---|
58 | #include <pthread.h> |
---|
59 | int pthread_cancel( |
---|
60 | pthread_t thread |
---|
61 | ); |
---|
62 | |
---|
63 | **STATUS CODES:** |
---|
64 | |
---|
65 | .. list-table:: |
---|
66 | :class: rtems-table |
---|
67 | |
---|
68 | * - ``E`` |
---|
69 | - The |
---|
70 | |
---|
71 | **DESCRIPTION:** |
---|
72 | |
---|
73 | **NOTES:** |
---|
74 | |
---|
75 | .. _pthread_setcancelstate: |
---|
76 | |
---|
77 | pthread_setcancelstate - Set Cancelability State |
---|
78 | ------------------------------------------------ |
---|
79 | .. index:: pthread_setcancelstate |
---|
80 | .. index:: set cancelability state |
---|
81 | |
---|
82 | **CALLING SEQUENCE:** |
---|
83 | |
---|
84 | .. code-block:: c |
---|
85 | |
---|
86 | #include <pthread.h> |
---|
87 | int pthread_setcancelstate( |
---|
88 | int state, |
---|
89 | int *oldstate |
---|
90 | ); |
---|
91 | |
---|
92 | **STATUS CODES:** |
---|
93 | |
---|
94 | .. list-table:: |
---|
95 | :class: rtems-table |
---|
96 | |
---|
97 | * - ``E`` |
---|
98 | - The |
---|
99 | |
---|
100 | **DESCRIPTION:** |
---|
101 | |
---|
102 | **NOTES:** |
---|
103 | |
---|
104 | .. _pthread_setcanceltype: |
---|
105 | |
---|
106 | pthread_setcanceltype - Set Cancelability Type |
---|
107 | ---------------------------------------------- |
---|
108 | .. index:: pthread_setcanceltype |
---|
109 | .. index:: set cancelability type |
---|
110 | |
---|
111 | **CALLING SEQUENCE:** |
---|
112 | |
---|
113 | .. code-block:: c |
---|
114 | |
---|
115 | #include <pthread.h> |
---|
116 | int pthread_setcanceltype( |
---|
117 | int type, |
---|
118 | int *oldtype |
---|
119 | ); |
---|
120 | |
---|
121 | **STATUS CODES:** |
---|
122 | |
---|
123 | .. list-table:: |
---|
124 | :class: rtems-table |
---|
125 | |
---|
126 | * - ``E`` |
---|
127 | - The |
---|
128 | |
---|
129 | **DESCRIPTION:** |
---|
130 | |
---|
131 | **NOTES:** |
---|
132 | |
---|
133 | .. _pthread_testcancel: |
---|
134 | |
---|
135 | pthread_testcancel - Create Cancellation Point |
---|
136 | ---------------------------------------------- |
---|
137 | .. index:: pthread_testcancel |
---|
138 | .. index:: create cancellation point |
---|
139 | |
---|
140 | **CALLING SEQUENCE:** |
---|
141 | |
---|
142 | .. code-block:: c |
---|
143 | |
---|
144 | #include <pthread.h> |
---|
145 | void pthread_testcancel( |
---|
146 | void |
---|
147 | ); |
---|
148 | |
---|
149 | **STATUS CODES:** |
---|
150 | |
---|
151 | .. list-table:: |
---|
152 | :class: rtems-table |
---|
153 | |
---|
154 | * - ``E`` |
---|
155 | - The |
---|
156 | |
---|
157 | **DESCRIPTION:** |
---|
158 | |
---|
159 | **NOTES:** |
---|
160 | |
---|
161 | .. _pthread_cleanup_push: |
---|
162 | |
---|
163 | pthread_cleanup_push - Establish Cancellation Handler |
---|
164 | ----------------------------------------------------- |
---|
165 | .. index:: pthread_cleanup_push |
---|
166 | .. index:: establish cancellation handler |
---|
167 | |
---|
168 | **CALLING SEQUENCE:** |
---|
169 | |
---|
170 | .. code-block:: c |
---|
171 | |
---|
172 | #include <pthread.h> |
---|
173 | void pthread_cleanup_push( |
---|
174 | void (*routine)(void*), |
---|
175 | void *arg |
---|
176 | ); |
---|
177 | |
---|
178 | **STATUS CODES:** |
---|
179 | |
---|
180 | .. list-table:: |
---|
181 | :class: rtems-table |
---|
182 | |
---|
183 | * - ``E`` |
---|
184 | - The |
---|
185 | |
---|
186 | **DESCRIPTION:** |
---|
187 | |
---|
188 | **NOTES:** |
---|
189 | |
---|
190 | .. _pthread_cleanup_pop: |
---|
191 | |
---|
192 | pthread_cleanup_pop - Remove Cancellation Handler |
---|
193 | ------------------------------------------------- |
---|
194 | .. index:: pthread_cleanup_pop |
---|
195 | .. index:: remove cancellation handler |
---|
196 | |
---|
197 | **CALLING SEQUENCE:** |
---|
198 | |
---|
199 | .. code-block:: c |
---|
200 | |
---|
201 | #include <pthread.h> |
---|
202 | void pthread_cleanup_pop( |
---|
203 | int execute |
---|
204 | ); |
---|
205 | |
---|
206 | **STATUS CODES:** |
---|
207 | |
---|
208 | .. list-table:: |
---|
209 | :class: rtems-table |
---|
210 | |
---|
211 | * - ``E`` |
---|
212 | - The |
---|
213 | |
---|
214 | **DESCRIPTION:** |
---|
215 | |
---|
216 | **NOTES:** |
---|