RTEMS Logo

RTEMS 4.6.2 On-Line Library


Configuration Space Manager cfg_unlink - Remove a Configuration Link

PREV UP NEXT Bookshelf New Chapters

3.4.7: cfg_unlink - Remove a Configuration Link

CALLING SEQUENCE:

#include <cfg.h>

int cfg_unlink(
  const char    *cfgpath
);

STATUS CODES:

A successful call to cfg_unlink() returns a value of zero and an unsuccessful call returns the errno.

ENAMETOOLONG
A component of a pathname exceeded NAME_MAX characters, or an entire path name exceed PATH_MAX characters.
EACCES
Search permission is denied on the node containing the link to be removed.
EACCES
Write permission is denied on the node containing the link to be removed.
ENOENT
A component of cfgpath does not exist.
EPERM
The calling process does not have the appropriate privilege to modify the node indicated by the path prefix of the cfgpath argument.
EBUSY
The node to be unlinked is the distinguished node of a mounted configuration space.
EIO
An I/O error occurred while deleting the link entry or deallocating the node.
EROFS
The named node resides in a read-only configuration space.
ELOOP
A node appears more than once in the path specified by the cfgpath argument.
ELOOP
More than SYMLOOP_MAX symbolic links were encountered during resolution of the cfgpath argument.

DESCRIPTION:

The cfg_unlink() function removes the link between the node specified by the cfgpath path prefix and the parent node specified by cfgpath, and decrements the link count of the cfgpath node.

When the link count of the node becomes zero, the space occupied by the node is freed and the node is no longer be accessible.

NOTES:

The _POSIX_CFG feature flag is defined to indicate this service is available.


PREV UP NEXT Bookshelf New Chapters

Copyright © 1988-2004 OAR Corporation