The file-descriptor file system, or
provides access to the per-process file descriptor
namespace in the global file system namespace.
The conventional mount point is
The file systems contents
appear as a list of numbered files
which correspond to the open files of the process reading the
refer to file descriptors which can be accessed through the file
If the file descriptor is open and the mode the file is being opened
with is a subset of the mode of the existing descriptor, the call:
fd = open("/dev/fd/0", mode);
and the call:
fd = fcntl(0, F_DUPFD, 0);
Flags to the
call other than
files are created by default when devfs alone is mounted.
creates entries for all file descriptors opened by the process.