1 /**************************************************************************/
2 /*                                                                        */
3 /*       Copyright (c) Microsoft Corporation. All rights reserved.        */
4 /*                                                                        */
5 /*       This software is licensed under the Microsoft Software License   */
6 /*       Terms for Microsoft Azure RTOS. Full text of the license can be  */
7 /*       found in the LICENSE file at https://aka.ms/AzureRTOS_EULA       */
8 /*       and in the root directory of this software.                      */
9 /*                                                                        */
10 /**************************************************************************/
11 
12 /**************************************************************************/
13 /**************************************************************************/
14 /**                                                                       */
15 /**   ThreadX Component                                                   */
16 /**                                                                       */
17 /**   POSIX Compliancy Wrapper (POSIX)                                    */
18 /**                                                                       */
19 /**************************************************************************/
20 /**************************************************************************/
21 
22 /**************************************************************************/
23 /*                                                                        */
24 /*  EKP DEFINITIONS                                        RELEASE        */
25 /*                                                                        */
26 /*    errno.h                                             PORTABLE C      */
27 /*                                                           6.1.7        */
28 /*  AUTHOR                                                                */
29 /*                                                                        */
30 /*    William E. Lamie, Microsoft Corporation                             */
31 /*                                                                        */
32 /*  DESCRIPTION                                                           */
33 /*                                                                        */
34 /*    This file defines the constants, structures, etc.needed to          */
35 /*    implement the Evacuation Kit for POSIX Users (POSIX)                */
36 /*                                                                        */
37 /*                                                                        */
38 /*  RELEASE HISTORY                                                       */
39 /*                                                                        */
40 /*    DATE              NAME                      DESCRIPTION             */
41 /*                                                                        */
42 /*  06-02-2021     William E. Lamie         Initial Version 6.1.7         */
43 /*                                                                        */
44 /**************************************************************************/
45 
46 #ifndef _ERRNO_H
47 #define _ERRNO_H
48 
49 
50 
51 #ifndef TX_POSIX_SOURCE
52 #define errno posix_errno
53 #endif
54 
55 /* the POSIX standard does not impose particular values for errno.h        */
56 /* error codes between 200 and 1000 are not used by the Threadx wrapper    */
57 /* but supplied for completeness.                                          */
58 
59 
60 
61 
62 #define E2BIG           200
63 
64 #define EACCES          13
65 
66 #define EADDRINUSE      201
67 
68 #define EADDRNOTAVAIL   202
69 
70 #define EAFNOSUPPORT    203
71 
72 #define EAGAIN          11
73 
74 #define EALREADY        204
75 
76 #define EBADF           9
77 
78 #define EBADMSG         205
79 
80 #define EBUSY           9999
81 
82 #define ECANCELED       206
83 
84 #define ECHILD          207
85 
86 #define ECONNABORTED    208
87 
88 #define ECONNREFUSED    209
89 
90 #define ECONNRESET      210
91 
92 #define EDEADLK         3333
93 
94 #define EDESTADDRREQ    211
95 
96 #define EDOM            212
97 
98 #define EDQUOT          213
99 
100 #define EEXIST          17
101 
102 #define EFAULT          214
103 
104 #define EFBIG           215
105 
106 #define EHOSTUNREACH    216
107 
108 #define EIDRM           217
109 
110 #define EILSEQ          218
111 
112 #define EINPROGRESS     219
113 
114 #define EINTR           4
115 
116 #define EINVAL          22
117 
118 #define EIO             220
119 
120 #define EISCONN         221
121 
122 #define EISDIR          222
123 
124 #define ELOOP           223
125 
126 #define EMFILE          224
127 
128 #define EMLINK          225
129 
130 #define EMSGSIZE        36
131 
132 #define EMULTIHOP       226
133 
134 #define ENAMETOOLONG    26
135 
136 #define ENETDOWN        227
137 
138 #define ENETRESET       228
139 
140 #define ENETUNREACH     229
141 
142 #define ENFILE          230
143 
144 #define ENOBUFS         231
145 
146 #define ENODATA         232
147 
148 #define ENODEV          233
149 
150 #define ENOENT          2
151 
152 #define ENOEXEC         234
153 
154 #define ENOLCK          235
155 
156 #define ENOLINK         236
157 
158 #define ENOMEM          4444
159 
160 #define ENOMSG          237
161 
162 #define ENOPROTOOPT     238
163 
164 #define ENOSPC          28
165 
166 #define ENOSR           239
167 
168 #define ENOSTR          240
169 
170 #define ENOSYS          71
171 
172 #define ENOTCONN        241
173 
174 #define ENOTDIR         242
175 
176 #define ENOTEMPTY       243
177 
178 #define ENOTSOCK        244
179 
180 #define ENOTSUP         126
181 
182 #define ENOTTY          245
183 
184 #define ENXIO           246
185 
186 #define EOPNOTSUPP      247
187 
188 #define EOVERFLOW       248
189 
190 #define EPERM           2222
191 
192 #define EPIPE           249
193 
194 #define EPROTO          250
195 
196 #define EPROTONOSUPPORT 251
197 
198 #define EPROTOTYPE      252
199 
200 #define ERANGE          253
201 
202 #define EROFS           254
203 
204 #define ESPIPE          255
205 
206 #define ESRCH           3
207 
208 #define ESTALE          256
209 
210 #define ETIME           257
211 
212 #define ETIMEDOUT       5555
213 
214 #define ETXTBSY         258
215 
216 #define EWOULDBLOCK     259
217 
218 #define EXDEV           260
219 
220 #endif
221