| ERRNO(9) | Kernel Developer's Manual | ERRNO(9) |
errno — kernel
internal error numbers
#include
<sys/errno.h>
This section provides an overview of the error numbers used internally by the kernel and indicate neither success nor failure. These error numbers are not returned to userland code.
Kernel functions that indicate success or failure by means of either 0 or an errno(2) value sometimes have a need to indicate that “special” handling is required at an upper layer or, in the case of ioctl(2) processing, that “nothing was wrong but the request was not handled”. To handle these cases, some negative errno(2) values are defined which are handled by the kernel before returning a different errno(2) value to userland or simply zero.
The following is a list of the defined names and their
meanings as given in
<errno.h>. It is important
to note that the value -1 is
not used, since it is
commonly used to indicate generic failure and leaves it up to the caller to
determine the action to take.
-2 EJUSTRETURN
Modify regs, just
return.-3 ERESTART
Restart
syscall.-4 EPASSTHROUGH
Operation not handled
by this layer.-5 EDUPFD
Duplicate file
descriptor.EDUPFD.
vn_open(9) takes the file
descriptor pointed to by l_dupfd and arranges for it
to be copied to the file descriptor that the open call will return.-6 EMOVEFD
Move file
descriptor.EDUPFD except that the
file descriptor in l_dupfd is closed after it has
been copied.An errno manual page appeared in
Version 6 AT&T UNIX. This
errno manual page appeared in
NetBSD 3.0.
| December 3, 2004 | NetBSD 11.0 |