Chameleon

Chameleon Svn Source Tree

Root/branches/cparm/i386/modules/include/errno.h

  • Property svn:executable set to *
1/*
2 * Copyright (c) 2000-2012 Apple, Inc. All rights reserved.
3 *
4 * @APPLE_OSREFERENCE_LICENSE_HEADER_START@
5 *
6 * This file contains Original Code and/or Modifications of Original Code
7 * as defined in and that are subject to the Apple Public Source License
8 * Version 2.0 (the 'License'). You may not use this file except in
9 * compliance with the License. The rights granted to you under the License
10 * may not be used to create, or enable the creation or redistribution of,
11 * unlawful or unlicensed copies of an Apple operating system, or to
12 * circumvent, violate, or enable the circumvention or violation of, any
13 * terms of an Apple operating system software license agreement.
14 *
15 * Please obtain a copy of the License at
16 * http://www.opensource.apple.com/apsl/ and read it before using this file.
17 *
18 * The Original Code and all software distributed under the License are
19 * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
20 * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
21 * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
22 * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
23 * Please see the License for the specific language governing rights and
24 * limitations under the License.
25 *
26 * @APPLE_OSREFERENCE_LICENSE_HEADER_END@
27 */
28/* Copyright (c) 1995 NeXT Computer, Inc. All Rights Reserved */
29/*
30 * Copyright (c) 1982, 1986, 1989, 1993
31 *The Regents of the University of California. All rights reserved.
32 * (c) UNIX System Laboratories, Inc.
33 * All or some portions of this file are derived from material licensed
34 * to the University of California by American Telephone and Telegraph
35 * Co. or Unix System Laboratories, Inc. and are reproduced herein with
36 * the permission of UNIX System Laboratories, Inc.
37 *
38 * Redistribution and use in source and binary forms, with or without
39 * modification, are permitted provided that the following conditions
40 * are met:
41 * 1. Redistributions of source code must retain the above copyright
42 * notice, this list of conditions and the following disclaimer.
43 * 2. Redistributions in binary form must reproduce the above copyright
44 * notice, this list of conditions and the following disclaimer in the
45 * documentation and/or other materials provided with the distribution.
46 * 3. All advertising materials mentioning features or use of this software
47 * must display the following acknowledgement:
48 *This product includes software developed by the University of
49 *California, Berkeley and its contributors.
50 * 4. Neither the name of the University nor the names of its contributors
51 * may be used to endorse or promote products derived from this software
52 * without specific prior written permission.
53 *
54 * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND
55 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
56 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
57 * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE
58 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
59 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
60 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
61 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
62 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
63 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
64 * SUCH DAMAGE.
65 *
66 *@(#)errno.h8.5 (Berkeley) 1/21/94
67 */
68
69#ifndef_SYS_ERRNO_H_
70#define_SYS_ERRNO_H_
71
72#include <sys/cdefs.h>
73
74
75/*
76 * Error codes
77 */
78
79#defineEPERM1/* Operation not permitted */
80#defineENOENT2/* No such file or directory */
81#defineESRCH3/* No such process */
82#defineEINTR4/* Interrupted system call */
83#defineEIO5/* Input/output error */
84#defineENXIO6/* Device not configured */
85#defineE2BIG7/* Argument list too long */
86#defineENOEXEC8/* Exec format error */
87#defineEBADF9/* Bad file descriptor */
88#defineECHILD10/* No child processes */
89#defineEDEADLK11/* Resource deadlock avoided */
90/* 11 was EAGAIN */
91#defineENOMEM12/* Cannot allocate memory */
92#defineEACCES13/* Permission denied */
93#defineEFAULT14/* Bad address */
94#if __DARWIN_C_LEVEL >= __DARWIN_C_FULL
95#defineENOTBLK15/* Block device required */
96#endif
97#defineEBUSY16/* Device / Resource busy */
98#defineEEXIST17/* File exists */
99#defineEXDEV18/* Cross-device link */
100#defineENODEV19/* Operation not supported by device */
101#defineENOTDIR20/* Not a directory */
102#defineEISDIR21/* Is a directory */
103#defineEINVAL22/* Invalid argument */
104#defineENFILE23/* Too many open files in system */
105#defineEMFILE24/* Too many open files */
106#defineENOTTY25/* Inappropriate ioctl for device */
107#defineETXTBSY26/* Text file busy */
108#defineEFBIG27/* File too large */
109#defineENOSPC28/* No space left on device */
110#defineESPIPE29/* Illegal seek */
111#defineEROFS30/* Read-only file system */
112#defineEMLINK31/* Too many links */
113#defineEPIPE32/* Broken pipe */
114
115/* math software */
116#defineEDOM33/* Numerical argument out of domain */
117#defineERANGE34/* Result too large */
118
119/* non-blocking and interrupt i/o */
120#defineEAGAIN35/* Resource temporarily unavailable */
121#defineEWOULDBLOCKEAGAIN/* Operation would block */
122#defineEINPROGRESS36/* Operation now in progress */
123#defineEALREADY37/* Operation already in progress */
124
125/* ipc/network software -- argument errors */
126#defineENOTSOCK38/* Socket operation on non-socket */
127#defineEDESTADDRREQ39/* Destination address required */
128#defineEMSGSIZE40/* Message too long */
129#defineEPROTOTYPE41/* Protocol wrong type for socket */
130#defineENOPROTOOPT42/* Protocol not available */
131#defineEPROTONOSUPPORT43/* Protocol not supported */
132#if __DARWIN_C_LEVEL >= __DARWIN_C_FULL
133#defineESOCKTNOSUPPORT44/* Socket type not supported */
134#endif
135#define ENOTSUP45/* Operation not supported */
136#if !__DARWIN_UNIX03 && !defined(KERNEL)
137/*
138 * This is the same for binary and source copmpatability, unless compiling
139 * the kernel itself, or compiling __DARWIN_UNIX03; if compiling for the
140 * kernel, the correct value will be returned. If compiling non-POSIX
141 * source, the kernel return value will be converted by a stub in libc, and
142 * if compiling source with __DARWIN_UNIX03, the conversion in libc is not
143 * done, and the caller gets the expected (discrete) value.
144 */
145#defineEOPNOTSUPP ENOTSUP/* Operation not supported on socket */
146#endif /* !__DARWIN_UNIX03 && !KERNEL */
147
148#if __DARWIN_C_LEVEL >= __DARWIN_C_FULL
149#defineEPFNOSUPPORT46/* Protocol family not supported */
150#endif
151#defineEAFNOSUPPORT47/* Address family not supported by protocol family */
152#defineEADDRINUSE48/* Address already in use */
153#defineEADDRNOTAVAIL49/* Can't assign requested address */
154
155/* ipc/network software -- operational errors */
156#defineENETDOWN50/* Network is down */
157#defineENETUNREACH51/* Network is unreachable */
158#defineENETRESET52/* Network dropped connection on reset */
159#defineECONNABORTED53/* Software caused connection abort */
160#defineECONNRESET54/* Connection reset by peer */
161#defineENOBUFS55/* No buffer space available */
162#defineEISCONN56/* Socket is already connected */
163#defineENOTCONN57/* Socket is not connected */
164#if __DARWIN_C_LEVEL >= __DARWIN_C_FULL
165#defineESHUTDOWN58/* Can't send after socket shutdown */
166#defineETOOMANYREFS59/* Too many references: can't splice */
167#endif
168#defineETIMEDOUT60/* Operation timed out */
169#defineECONNREFUSED61/* Connection refused */
170
171#defineELOOP62/* Too many levels of symbolic links */
172#defineENAMETOOLONG63/* File name too long */
173
174/* should be rearranged */
175#if __DARWIN_C_LEVEL >= __DARWIN_C_FULL
176#defineEHOSTDOWN64/* Host is down */
177#endif
178#defineEHOSTUNREACH65/* No route to host */
179#defineENOTEMPTY66/* Directory not empty */
180
181/* quotas & mush */
182#if __DARWIN_C_LEVEL >= __DARWIN_C_FULL
183#defineEPROCLIM67/* Too many processes */
184#defineEUSERS68/* Too many users */
185#endif
186#defineEDQUOT69/* Disc quota exceeded */
187
188/* Network File System */
189#defineESTALE70/* Stale NFS file handle */
190#if __DARWIN_C_LEVEL >= __DARWIN_C_FULL
191#defineEREMOTE71/* Too many levels of remote in path */
192#defineEBADRPC72/* RPC struct is bad */
193#defineERPCMISMATCH73/* RPC version wrong */
194#defineEPROGUNAVAIL74/* RPC prog. not avail */
195#defineEPROGMISMATCH75/* Program version wrong */
196#defineEPROCUNAVAIL76/* Bad procedure for program */
197#endif
198
199#defineENOLCK77/* No locks available */
200#defineENOSYS78/* Function not implemented */
201
202#if __DARWIN_C_LEVEL >= __DARWIN_C_FULL
203#defineEFTYPE79/* Inappropriate file type or format */
204#defineEAUTH80/* Authentication error */
205#defineENEEDAUTH81/* Need authenticator */
206
207/* Intelligent device errors */
208#defineEPWROFF82/* Device power is off */
209#defineEDEVERR83/* Device error, e.g. paper out */
210#endif
211
212#defineEOVERFLOW84/* Value too large to be stored in data type */
213
214/* Program loading errors */
215#if __DARWIN_C_LEVEL >= __DARWIN_C_FULL
216#define EBADEXEC85/* Bad executable */
217#define EBADARCH86/* Bad CPU type in executable */
218#define ESHLIBVERS87/* Shared library version mismatch */
219#define EBADMACHO88/* Malformed Macho file */
220#endif
221
222#defineECANCELED89/* Operation canceled */
223
224#define EIDRM90/* Identifier removed */
225#define ENOMSG91/* No message of desired type */
226#define EILSEQ92/* Illegal byte sequence */
227#if __DARWIN_C_LEVEL >= __DARWIN_C_FULL
228#define ENOATTR93/* Attribute not found */
229#endif
230
231#define EBADMSG94/* Bad message */
232#define EMULTIHOP95/* Reserved */
233#defineENODATA96/* No message available on STREAM */
234#define ENOLINK97/* Reserved */
235#define ENOSR98/* No STREAM resources */
236#define ENOSTR99/* Not a STREAM */
237#defineEPROTO100/* Protocol error */
238#define ETIME101/* STREAM ioctl timeout */
239
240#if __DARWIN_UNIX03 || defined(KERNEL)
241/* This value is only discrete when compiling __DARWIN_UNIX03, or KERNEL */
242#defineEOPNOTSUPP102/* Operation not supported on socket */
243#endif /* __DARWIN_UNIX03 || KERNEL */
244
245#define ENOPOLICY103/* No such policy registered */
246
247#if __DARWIN_C_LEVEL >= 200809L
248#define ENOTRECOVERABLE 104/* State not recoverable */
249#define EOWNERDEAD 105/* Previous owner died */
250#endif
251
252#if __DARWIN_C_LEVEL >= __DARWIN_C_FULL
253#defineEQFULL106/* Interface output queue is full */
254#defineELAST106/* Must be equal largest errno */
255#endif
256
257#endif /* _SYS_ERRNO_H_ */
258

Archive Download this file

Revision: 2154