Go to the previous, next section.

mknod

SYNOPSIS

int mknod(const char *path, mode_t mode, dev_t dev);

PARAMETERS

path: [in] points to the path of the new file.

mode: [in] specifies the kind of special file to create. (Do not use it to specify the access bits of the file.)

dev: [in] the major and minor numbers of the new device.

DESCRIPTION

Creates a special device file node. Only tasks with superuser privileges may use this call. The access bits of the new file are the same as those of the umask of the current task. If mode does not specify a special device file, then dev is ignored.

RETURN VALUE

On success zero is returned. On error, -1 is returned and errno is set to one of the following values:

Go to the previous, next section.