]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/blob - sys/xen/interface/errno.h
xen: clean up empty lines in .c and .h files
[FreeBSD/FreeBSD.git] / sys / xen / interface / errno.h
1 #ifndef __XEN_PUBLIC_ERRNO_H__
2
3 #ifndef __ASSEMBLY__
4
5 #define XEN_ERRNO(name, value) XEN_##name = value,
6 enum xen_errno {
7 #else /* !__ASSEMBLY__ */
8
9 #define XEN_ERRNO(name, value) .equ XEN_##name, value
10
11 #endif /* __ASSEMBLY__ */
12
13 /* ` enum neg_errnoval {  [ -Efoo for each Efoo in the list below ]  } */
14 /* ` enum errnoval { */
15
16 #endif /* __XEN_PUBLIC_ERRNO_H__ */
17
18 #ifdef XEN_ERRNO
19
20 /*
21  * Values originating from x86 Linux. Please consider using respective
22  * values when adding new definitions here.
23  *
24  * The set of identifiers to be added here shouldn't extend beyond what
25  * POSIX mandates (see e.g.
26  * http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/errno.h.html)
27  * with the exception that we support some optional (XSR) values
28  * specified there (but no new ones should be added).
29  */
30
31 XEN_ERRNO(EPERM,         1)     /* Operation not permitted */
32 XEN_ERRNO(ENOENT,        2)     /* No such file or directory */
33 XEN_ERRNO(ESRCH,         3)     /* No such process */
34 #ifdef __XEN__ /* Internal only, should never be exposed to the guest. */
35 XEN_ERRNO(EINTR,         4)     /* Interrupted system call */
36 #endif
37 XEN_ERRNO(EIO,           5)     /* I/O error */
38 XEN_ERRNO(ENXIO,         6)     /* No such device or address */
39 XEN_ERRNO(E2BIG,         7)     /* Arg list too long */
40 XEN_ERRNO(ENOEXEC,       8)     /* Exec format error */
41 XEN_ERRNO(EBADF,         9)     /* Bad file number */
42 XEN_ERRNO(ECHILD,       10)     /* No child processes */
43 XEN_ERRNO(EAGAIN,       11)     /* Try again */
44 XEN_ERRNO(ENOMEM,       12)     /* Out of memory */
45 XEN_ERRNO(EACCES,       13)     /* Permission denied */
46 XEN_ERRNO(EFAULT,       14)     /* Bad address */
47 XEN_ERRNO(EBUSY,        16)     /* Device or resource busy */
48 XEN_ERRNO(EEXIST,       17)     /* File exists */
49 XEN_ERRNO(EXDEV,        18)     /* Cross-device link */
50 XEN_ERRNO(ENODEV,       19)     /* No such device */
51 XEN_ERRNO(EINVAL,       22)     /* Invalid argument */
52 XEN_ERRNO(ENFILE,       23)     /* File table overflow */
53 XEN_ERRNO(EMFILE,       24)     /* Too many open files */
54 XEN_ERRNO(ENOSPC,       28)     /* No space left on device */
55 XEN_ERRNO(EMLINK,       31)     /* Too many links */
56 XEN_ERRNO(EDOM,         33)     /* Math argument out of domain of func */
57 XEN_ERRNO(ERANGE,       34)     /* Math result not representable */
58 XEN_ERRNO(EDEADLK,      35)     /* Resource deadlock would occur */
59 XEN_ERRNO(ENAMETOOLONG, 36)     /* File name too long */
60 XEN_ERRNO(ENOLCK,       37)     /* No record locks available */
61 XEN_ERRNO(ENOSYS,       38)     /* Function not implemented */
62 XEN_ERRNO(ENODATA,      61)     /* No data available */
63 XEN_ERRNO(ETIME,        62)     /* Timer expired */
64 XEN_ERRNO(EBADMSG,      74)     /* Not a data message */
65 XEN_ERRNO(EOVERFLOW,    75)     /* Value too large for defined data type */
66 XEN_ERRNO(EILSEQ,       84)     /* Illegal byte sequence */
67 #ifdef __XEN__ /* Internal only, should never be exposed to the guest. */
68 XEN_ERRNO(ERESTART,     85)     /* Interrupted system call should be restarted */
69 #endif
70 XEN_ERRNO(ENOTSOCK,     88)     /* Socket operation on non-socket */
71 XEN_ERRNO(EOPNOTSUPP,   95)     /* Operation not supported on transport endpoint */
72 XEN_ERRNO(EADDRINUSE,   98)     /* Address already in use */
73 XEN_ERRNO(EADDRNOTAVAIL, 99)    /* Cannot assign requested address */
74 XEN_ERRNO(ENOBUFS,      105)    /* No buffer space available */
75 XEN_ERRNO(EISCONN,      106)    /* Transport endpoint is already connected */
76 XEN_ERRNO(ENOTCONN,     107)    /* Transport endpoint is not connected */
77 XEN_ERRNO(ETIMEDOUT,    110)    /* Connection timed out */
78
79 #undef XEN_ERRNO
80 #endif /* XEN_ERRNO */
81
82 #ifndef __XEN_PUBLIC_ERRNO_H__
83 #define __XEN_PUBLIC_ERRNO_H__
84
85 /* ` } */
86
87 #ifndef __ASSEMBLY__
88 };
89 #endif
90
91 #define XEN_EWOULDBLOCK XEN_EAGAIN      /* Operation would block */
92 #define XEN_EDEADLOCK   XEN_EDEADLK     /* Resource deadlock would occur */
93
94 #endif /*  __XEN_PUBLIC_ERRNO_H__ */