Expand PMF_FN_* macros.
[netbsd-mini2440.git] / sys / compat / svr4 / svr4_errno.c
blob95292c3bb43e920bf8921bfa3b29a903c3e35970
1 /* $NetBSD: svr4_errno.c,v 1.9 2001/11/13 02:09:21 lukem Exp $ */
3 /*-
4 * Copyright (c) 1994 The NetBSD Foundation, Inc.
5 * All rights reserved.
7 * This code is derived from software contributed to The NetBSD Foundation
8 * by Christos Zoulas.
10 * Redistribution and use in source and binary forms, with or without
11 * modification, are permitted provided that the following conditions
12 * are met:
13 * 1. Redistributions of source code must retain the above copyright
14 * notice, this list of conditions and the following disclaimer.
15 * 2. Redistributions in binary form must reproduce the above copyright
16 * notice, this list of conditions and the following disclaimer in the
17 * documentation and/or other materials provided with the distribution.
19 * THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
20 * ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
21 * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
22 * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
23 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
24 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
25 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
26 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
27 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
28 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
29 * POSSIBILITY OF SUCH DAMAGE.
33 * Translate error codes.
36 #include <sys/cdefs.h>
37 __KERNEL_RCSID(0, "$NetBSD: svr4_errno.c,v 1.9 2001/11/13 02:09:21 lukem Exp $");
39 #include <compat/svr4/svr4_errno.h>
42 const int native_to_svr4_errno[] = {
44 SVR4_EPERM,
45 SVR4_ENOENT,
46 SVR4_ESRCH,
47 SVR4_EINTR,
48 SVR4_EIO,
49 SVR4_ENXIO,
50 SVR4_E2BIG,
51 SVR4_ENOEXEC,
52 SVR4_EBADF,
53 SVR4_ECHILD,
54 SVR4_EDEADLK,
55 SVR4_ENOMEM,
56 SVR4_EACCES,
57 SVR4_EFAULT,
58 SVR4_ENOTBLK,
59 SVR4_EBUSY,
60 SVR4_EEXIST,
61 SVR4_EXDEV,
62 SVR4_ENODEV,
63 SVR4_ENOTDIR,
64 SVR4_EISDIR,
65 SVR4_EINVAL,
66 SVR4_ENFILE,
67 SVR4_EMFILE,
68 SVR4_ENOTTY,
69 SVR4_ETXTBSY,
70 SVR4_EFBIG,
71 SVR4_ENOSPC,
72 SVR4_ESPIPE,
73 SVR4_EROFS,
74 SVR4_EMLINK,
75 SVR4_EPIPE,
76 SVR4_EDOM,
77 SVR4_ERANGE,
78 SVR4_EAGAIN,
79 SVR4_EINPROGRESS,
80 SVR4_EALREADY,
81 SVR4_ENOTSOCK,
82 SVR4_EDESTADDRREQ,
83 SVR4_EMSGSIZE,
84 SVR4_EPROTOTYPE,
85 SVR4_ENOPROTOOPT,
86 SVR4_EPROTONOSUPPORT,
87 SVR4_ESOCKTNOSUPPORT,
88 SVR4_EOPNOTSUPP,
89 SVR4_EPFNOSUPPORT,
90 SVR4_EAFNOSUPPORT,
91 SVR4_EADDRINUSE,
92 SVR4_EADDRNOTAVAIL,
93 SVR4_ENETDOWN,
94 SVR4_ENETUNREACH,
95 SVR4_ENETRESET,
96 SVR4_ECONNABORTED,
97 SVR4_ECONNRESET,
98 SVR4_ENOBUFS,
99 SVR4_EISCONN,
100 SVR4_ENOTCONN,
101 SVR4_ESHUTDOWN,
102 SVR4_ETOOMANYREFS,
103 SVR4_ETIMEDOUT,
104 SVR4_ECONNREFUSED,
105 SVR4_ELOOP,
106 SVR4_ENAMETOOLONG,
107 SVR4_EHOSTDOWN,
108 SVR4_EHOSTUNREACH,
109 SVR4_ENOTEMPTY,
110 SVR4_EPROCLIM,
111 SVR4_EUSERS,
112 SVR4_EDQUOT,
113 SVR4_ESTALE,
114 SVR4_EREMOTE,
115 SVR4_EBADRPC,
116 SVR4_ERPCMISMATCH,
117 SVR4_EPROGUNAVAIL,
118 SVR4_EPROGMISMATCH,
119 SVR4_EPROCUNAVAIL,
120 SVR4_ENOLCK,
121 SVR4_ENOSYS,
122 SVR4_EFTYPE,
123 SVR4_EAUTH,
124 SVR4_ENEEDAUTH,
125 SVR4_EIDRM,
126 SVR4_ENOMSG,