[Previous] [Contents] [Next]

Caution: This version of this document is no longer maintained. For the latest documentation, see http://www.qnx.com/developers/docs.

create() callback

Called to get a list of all properties associated with a node

Synopsis:

#include <sys/pmm.h>

void * create(pmm_node_t *node, void *parent, 
           const char *name, unsigned flags);

Library:

libc

Description:

This function is called when a new node is created:

node
Pointer to the newly created node.
parent
Policy specific data associated with parent of this node in the name space.
name
Name of the node within the parent directory.
flags
Currently contains either 0 or PMM_NODE_CLIENT:

The create() function is called from the following operations:

The return value from this function is the policy specific data to be associated with the node. This value is passed to all other policy functions in order to allow the policy to operate on its policy specific data.

The policy would typically use this function to allocate a policy specific data structure.


Note: It should store the node value in this structure as it needs to be supplied to the API functions.

The default action (if the policy does not override this function) is to use node itself as the policy data. This ensures that whenever any of the other policy functions are called, they will be provided with the node pointer to allow them to perform operations on the node.

Returns:

Classification:

QNX Neutrino

Safety:
Cancellation point Unknown
Interrupt handler Unknown
Signal handler Unknown
Thread Unknown

See also:


[Previous] [Contents] [Next]