RTEMS Logo

RTEMS 4.6.2 On-Line Library


Configuration Space Manager cfg_mark - Set Configuration Space Options

PREV UP NEXT Bookshelf New Chapters

3.4.11: cfg_mark - Set Configuration Space Options

CALLING SEQUENCE:

#include <cfg.h>

int cfg_mark(
  CFG           *cfgp,
  CFGENT        *f,
  int            options
);

STATUS CODES:

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

EINVAL
The specified combination of the cfgp and f arguments is not supported by the implementation.
EINVAL
The specified value of the options argument is invalid.

DESCRIPTION:

The cfg_mark() function modifies the subsequent behavior of the cfg functions with regard to the node referenced by the structure pointed to by the argument f or the configuration space referenced by the structure pointed to by the argument cfgp.

Exactly one of the f argument and the cfgp argument is NULL.

The value of the options argument is exactly one of the flags specified in the following list:

CFG_AGAIN
If the cfgp argument is non-NULL, or the f argument is NULL, or the structure referenced by f is not the one most recently returned by cfg_read(), cfg_mark() returns an error. Otherwise, the next call to the cfg_read() function returns the structure referenced by f with the cfg_info field reinitialized. Subsequent behavior of the cfg functions are based on the reinitialized value of cfg_info.
CFG_SKIP
If the cfgp argument is non-NULL, or the f argument is NULL, or the structure referenced by f is not one of those specified as accessible, or the structure referenced by f is not for a node of type pre-order node, cfg_mark() returns an error. Otherwise, no more structures for the node referenced by f or its descendants are returned by the cfg_read() function.
CFG_FOLLOW
If the cfgp argument is non-NULL, or the f argument is NULL, or the structure referenced by f is not one of those specified as accessible, or the structure referenced by f is not for a node of type symbolic link, cfg_mark() returns an error. Otherwise, the next call to the cfg_read() function returns the structure referenced by f with the cfg_info field reset to reflect the target of the symbolic link instead of the symbolic link itself. If the target of the link is node with children, the pre-order return, followed by the return of structures referencing all of its descendants, followed by a post-order return, shall be done.

If the target of the symbolic link does not exist, the fields of the structure by cfg_read() shall be unmodified, except that the cfg_info field shall be reset to CFG_SLNONE.

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